The Virtualization Cookbook for SLES 10 SP2 - z/VM - IBM
The Virtualization Cookbook for SLES 10 SP2 - z/VM - IBM
The Virtualization Cookbook for SLES 10 SP2 - z/VM - IBM
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
► View your order with the swapon -s command:<br />
# swapon -s<br />
Filename Type Size Used Priority<br />
/dev/dasda2 partition 524296 0 -1<br />
/dev/dasdb1 partition 262132 0 -2<br />
/dev/dasdc1 partition 524276 0 -3<br />
This shows that the minidisk swap space will be used be<strong>for</strong>e the VDISK. As VDISKs are<br />
in-memory, they should be first in the priority, from smallest to largest.<br />
► Make a backup of the /etc/fstab file:<br />
# cd /etc<br />
# cp fstab fstab.orig<br />
► Modify the order by moving the line in /etc/fstab. with the minidisk swap space below<br />
the lines with VDISK swap spaces:<br />
# vi fstab<br />
...<br />
/dev/disk/by-path/ccw-0.0.0300-part1 swap swap defaults 0 0<br />
/dev/disk/by-path/ccw-0.0.0301-part1 swap swap defaults 0 0<br />
/dev/disk/by-path/ccw-0.0.0<strong>10</strong>0-part2 swap swap defaults 0 0<br />
...<br />
After a reboot, the minidisk swap space should come back with the lowest priority.<br />
7.2.11 Setting the system to logoff when Linux is shut down<br />
When Linux is shut down, the default is <strong>for</strong> the virtual machine to remain logged on even<br />
though it is not running an operating system. It is more convenient <strong>for</strong> the user ID to be<br />
logged off, both at z/<strong>VM</strong> SHUTDOWN time and <strong>for</strong> getting a refreshed 3270 emulator session. To<br />
do this, per<strong>for</strong>m the following steps:<br />
► Edit the file /etc/rc.d/rc.local and add two lines at the end as follows:<br />
# cd /etc/rc.d<br />
# vi rc.local<br />
#!/bin/sh<br />
#<br />
# This script will be executed *after* all the other init scripts.<br />
# You can put your own initialization stuff in here if you don't<br />
# want to do the full Sys V style init stuff.<br />
touch /var/lock/subsys/local<br />
chshut halt vmcmd logoff<br />
chshut poff vmcmd logoff<br />
<strong>The</strong> z/<strong>VM</strong> user ID should now be logged off when you halt or power off Linux.<br />
7.2.12 Rebooting the system<br />
You should now reboot the system to test the changes:<br />
# reboot<br />
Broadcast message from root@gpok223.endicott.ibm.com<br />
(/dev/pts/0) at 7:27 ...<br />
<strong>The</strong> system is going down <strong>for</strong> reboot NOW!<br />
After your system comes back in a couple of minutes, start a new SSH session to the cloner.<br />
126 <strong>The</strong> <strong>Virtualization</strong> <strong>Cookbook</strong> <strong>for</strong> RHEL 6