AoE for Xen
Материал из Xgu.ru
Файл /etc/init.d/vbladed
#!/bin/sh # ### BEGIN INIT INFO # Provides: vbladed # Required-Start: $syslog # Required-Stop: $syslog # Should-Start: # Should-Stop: # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: vbladed # Description: # # ### END INIT INFO PATH=/bin:/usr/bin:/sbin:/usr/sbin DAEMON=/usr/sbin/vbladed OPTIONS="" . /etc/default/vbladed test -x $DAEMON || exit 0 case "$1" in start) echo -n "Starting vblades: vbladed" if start-stop-daemon --quiet --stop --signal 0 --exec $DAEMON then echo " [already running]" else /sbin/start-stop-daemon --start --quiet --exec $DAEMON -- $OPTIONS echo "." fi ;; stop) echo -n "Stopping vblades: vbladed" if start-stop-daemon --quiet --stop --signal 0 --exec $DAEMON then start-stop-daemon --quiet --stop --exec $DAEMON echo "." else echo " [not running]"; fi ;; force-reload|restart) $0 stop sleep 1 $0 start ;; *) echo "Usage: /etc/init.d/vbladed {start|stop|restart|force-reload}" exit 1 esac exit 0
[править] Превращение HVM в SXP
15:06:15 # fdisk -lu /dev/NAS1/suse0 Disk /dev/NAS1/suse0: 4294 MB, 4294967296 bytes 255 heads, 63 sectors/track, 522 cylinders, total 8388608 sectors Units = sectors of 1 * 512 = 512 bytes Device Boot Start End Blocks Id System /dev/NAS1/suse0p1 63 1028159 514048+ 82 Linux swap / Solaris /dev/NAS1/suse0p2 * 1028160 8385929 3678885 83 Linux 15:02:52 # echo 63*512 | bc 32256 15:03:07 # losetup -o 32256 /dev/loop0 /dev/NAS1/suse0 15:03:50 # file -s /dev/loop0 /dev/loop0: Linux/i386 swap file (new style) 1 (4K pages) size 128511 pages 15:06:28 # echo 1028160*512 | bc 526417920 15:06:54 # losetup -o 526417920 /dev/loop0 /dev/NAS1/suse0 15:07:20 # file -s /dev/loop0 /dev/loop0: ReiserFS V3.6 block size 4096 (mounted or unclean) num blocks 919712 r5 hash 15:07:25 # mount /dev/loop0 /mnt прошла 31 минута 15:38:48 # xm list Name ID Mem(MiB) VCPUs State Time(s) Domain-0 0 125 2 r----- 3433.3 15:38:56 # ls /mnt/ bin boot dev etc home lib media mnt opt proc root sbin srv subdomain sys tmp usr var 15:39:00 # ls /mnt/lib/modules/ 2.6.16.21-0.8-default 15:39:05 # cp -R /lib/modules/2.6.17-2- 2.6.17-2-686/ 2.6.17-2-xen-686/ 15:39:58 # umount /mnt/ 15:40:10 # losetup -d /dev/loop0
[править] Запуск OES1 в паравиртуальном режиме
Получить ядро, подготовленное для использования в паравиртуальном режиме:
http://forge.novell.com/modules/xfcontent/downloads.php/xenpreview/SUSE%20Linux%20Enterprise%20Server/9%20SP3/i586/ (если ссылка не работает, уточнить здесь: http://www.novell.com/coolsolutions/feature/17687.html)
|
---|