UnixPedia : HPUX / LINUX / SOLARIS: HPUX : How to create a Seconday swap on HPUX system.

Thursday, September 25, 2014

HPUX : How to create a Seconday swap on HPUX system.

System running hp-ux 11.31 with 98200Mb of physical memory and 8192Mb
 of swap space.Adding a secondary swap
 #swapinfo -tam
             Mb      Mb      Mb   PCT  START/      Mb
TYPE      AVAIL    USED    FREE  USED   LIMIT RESERVE  PRI  NAME
dev        8192       0    8192    0%       0       -    1  /dev/vg00/lvol2
reserve       -    8192   -8192
memory    93405   45505   47900   49%
total    101597   53697   47900   53%       -       0    -
mcel_VMhost2[161]/
 #bdf
Filesystem          kbytes    used   avail %used Mounted on
/dev/vg00/lvol3    1048576  231824  810408   22% /
/dev/vg00/lvol1    1835008  192520 1629744   11% /stand
/dev/vg00/lvol8    8912896 5323944 3571568   60% /var
/dev/vg00/lvol7    6553600 2991776 3534008   46% /usr
/dev/vg00/lvol4    10485760  218096 10188064    2% /tmp
/dev/vg00/lvol6    10485760 5879944 4569936   56% /opt
/dev/vg00/lvol5     131072    5784  124440    4% /home

 #lvcreate -C y -r n -L 24576 -n lvol10 /dev/vg00
Logical volume "/dev/vg00/lvol10" has been successfully created with
character device "/dev/vg00/rlvol10"
#lvextend -m 1  /dev/vg00/lvol10 <alternate disk>
#swapon -p 2 /dev/vg00/lvol10
#swapinfo -tam
             Mb      Mb      Mb   PCT  START/      Mb
TYPE      AVAIL    USED    FREE  USED   LIMIT RESERVE  PRI  NAME
dev        8192       0    8192    0%       0       -    1  /dev/vg00/lvol2
dev       24576       0   24576    0%       0       -    2  /dev/vg00/lvol10
reserve       -    8234   -8234
memory    93405   48272   45133   52%
total    126173   56506   69667   45%       -       0    -  
Adding the following to /etc/fstab will accomplish this:
cp -ip /etc/fstab /etc/fstab.date
/dev/vg00/lvol0 ... swap pri=2 0 0
 

No comments:

Post a Comment