tmux

http://tmux.sourceforge.net/
http://www.linuxpedia.fr/doku.php/commande/tmux

Diverses commandes pour récupérer une session :

Liste les sessions :
tmux ls
Attacher une session détachée :
tmux attach
Attacher une session détachée spécifique:
tmux attach -t session
Détacher et attacher une session spécifique.
tmux attach -d -t session

Mon .tmux.conf

# alt+directions navigates through panes
bind-key -n C-left select-pane -L
bind-key -n C-right select-pane -R
bind-key -n C-up select-pane -U
bind-key -n C-down select-pane -D

Liste session

set pages 1000
set lines 1000

select USERNAME, OSUSER, MACHINE, PROGRAM from v$session;
ou

select distinct username from v$session;
select USERNAME, OSUSER, MACHINE, PROGRAM from v$session where username in ('xxx', 'yyy');

En rac oracle :
select USERNAME, OSUSER, MACHINE, PROGRAM from gv$session;

HugePages

http://docs.oracle.com/cd/E37670_01/E37355/html/ol_config_hugepages.html

#!/bin/bash
#
# hugepages_settings.sh
#
# Linux bash script to compute values for the
# recommended HugePages/HugeTLB configuration
#
# Note: This script does calculation for all shared memory
# segments available when the script is run, no matter it
# is an Oracle RDBMS shared memory segment or not.
# Check for the kernel version
KERN=`uname -r | awk -F. '{ printf("%d.%dn",$1,$2); }'`
# Find out the HugePage size
HPG_SZ=`grep Hugepagesize /proc/meminfo | awk {'print $2'}`
# Start from 1 pages to be on the safe side and guarantee 1 free HugePage
NUM_PG=1
# Cumulative number of pages required to handle the running shared memory segments
for SEG_BYTES in `ipcs -m | awk {'print $5'} | grep "[0-9][0-9]*"`
do
   MIN_PG=`echo "$SEG_BYTES/($HPG_SZ*1024)" | bc -q`
   if [ $MIN_PG -gt 0 ]; then
      NUM_PG=`echo "$NUM_PG+$MIN_PG+1" | bc -q`
   fi
done
# Finish with results
case $KERN in
   '2.4') HUGETLB_POOL=`echo "$NUM_PG*$HPG_SZ/1024" | bc -q`;
          echo "Recommended setting: vm.hugetlb_pool = $HUGETLB_POOL" ;;
   '2.6') echo "Recommended setting: vm.nr_hugepages = $NUM_PG" ;;
    *) echo "Unrecognized kernel version $KERN. Exiting." ;;
esac
# End