Hello, I'm trying this tutorial, and I got it to work once, so I tried it again, with partial success. I successfully created the image (or so it said), but when I tried to start it, I get an error. I'm not sure what's different; below is copy/paste from my SSH terminal (but with my username@hostname changed, and the lines I typed the commands on have been put in bold). Code: [B]user@server:~$ sudo xm create /etc/xen/debian-lenny.cfg [/B] Using config file "/etc/xen/debian-lenny.cfg". Error: Device 51714 (vbd) could not be connected. File /home/xen/domains/debian-lenny/disk.img is loopback-mounted through /dev/loop0, which is mounted in the privileged domain, and so cannot be mounted by a guest. [B]user@server:~$ sudo xm list[/B] Name ID Mem VCPUs State Time(s) Domain-0 0 842 4 r----- 345.5 [B]user@server:~$ sudo -s[/B] [B]root@server:~# exit[/B] exit [B]user@server:~$ sudo whoami[/B] root [B]user@server:~$[/B] sudo xm create /etc/xen/debian-lenny.cfg Using config file "/etc/xen/debian-lenny.cfg". Error: Device 51714 (vbd) could not be connected. File /home/xen/domains/debian-lenny/disk.img is loopback-mounted through /dev/loop0, which is mounted in the privileged domain, and so cannot be mounted by a guest. [B]user@server:~$ sudo -s[/B] [B]root@server:~# xm create /etc/xen/debian-lenny.cfg[/B] Using config file "/etc/xen/debian-lenny.cfg". Error: Device 51714 (vbd) could not be connected. File /home/xen/domains/debian-lenny/disk.img is loopback-mounted through /dev/loop0, which is mounted in the privileged domain, and so cannot be mounted by a guest. [B]root@server:~# exit[/B] exit [B]user@server:~$ [/B]
Is it possible that /home/xen/domains/debian-lenny/disk.img is still mounted while you're trying to start the guest? What's the output of Code: mount ?
Edit: The short version is that I got it working now. Thanks! For the full explanation, keep reading... Bingo! The question now is, how to unmount it? Hmm... Code: [B]user@server:~$ sudo mount -l[/B] /dev/sda5 on / type ext3 (rw,errors=remount-ro) tmpfs on /lib/init/rw type tmpfs (rw,nosuid,mode=0755) proc on /proc type proc (rw,noexec,nosuid,nodev) sysfs on /sys type sysfs (rw,noexec,nosuid,nodev) procbususb on /proc/bus/usb type usbfs (rw) udev on /dev type tmpfs (rw,mode=0755) tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev) devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=620) nfsd on /proc/fs/nfsd type nfsd (rw) /home/xen/domains/debian-lenny/disk.img on /tmp/tekA5p8kWS type ext3 (rw,loop=/dev/loop0) /proc on /tmp/tekA5p8kWS/proc type none (rw,bind) [B]user@server:~$ sudo umount /home/xen/domains/debian-lenny/disk.img [/B] umount: /tmp/tekA5p8kWS: device is busy umount: /tmp/tekA5p8kWS: device is busy Well, this probably isn't the recommended way, but here's what I tried next: Code: [B]user@server:~$ ps -A | grep xen[/B] 31 ? 00:00:00 xenwatch 32 ? 00:00:00 xenbus 3208 ? 00:00:00 xenstored 3215 ? 00:00:00 xenconsoled [B]user@server:~$ sudo kill 3208[/B] [B]user@server:~$ ps -A | grep xen[/B] 31 ? 00:00:00 xenwatch 32 ? 00:00:00 xenbus 3215 ? 00:00:00 xenconsoled [B]user@server:~$ sudo umount /home/xen/domains/debian-lenny/disk.img [/B] umount: /tmp/tekA5p8kWS: device is busy umount: /tmp/tekA5p8kWS: device is busy [B]user@server:~$ sudo kill 3215[/B] [B]user@server:~$ ps -A | grep xen[/B] 31 ? 00:00:00 xenwatch 32 ? 00:00:00 xenbus [B]user@server:~$ sudo umount /home/xen/domains/debian-lenny/disk.img [/B] umount: /tmp/tekA5p8kWS: device is busy umount: /tmp/tekA5p8kWS: device is busy [B]user@server:~$ sudo /etc/init.d/xend force-reload[/B] Restarting XEN control daemon: xend This made it unresponsive. So, from another terminal: Code: [B]me@client:~$ ssh [email protected][/B] ssh: connect to host 192.168.5.9 port 22: No route to host [B]me@client:~$ ssh [email protected][/B] ssh: connect to host 192.168.5.9 port 22: No route to host At this point I rebooted the machine (the server). This made the first SSH terminal say: Code: Read from remote host 192.168.5.9: Connection reset by peer Connection to 192.168.5.9 closed. After it finished booting, I got it working: Code: [B]me@client:~$ ssh [email protected][/B] [B][email protected]'s password: [/B] Linux server 2.6.26-2-xen-amd64 #1 SMP Thu Aug 20 00:36:34 UTC 2009 x86_64 The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Thu Oct 29 17:02:40 2009 from machine.domain [B]user@server:~$ sudo xm list[/B] [sudo] password for user: Name ID Mem VCPUs State Time(s) Domain-0 0 1640 4 r----- 8.0 [B]user@server:~$ sudo xm create /etc/xen/debian-lenny.cfg [/B] Using config file "/etc/xen/debian-lenny.cfg". Started domain debian-lenny [B]user@server:~$ sudo xm list[/B] Name ID Mem VCPUs State Time(s) Domain-0 0 958 4 r----- 9.7 debian-lenny 1 786 1 -b---- 2.8 [B]user@server:~$ sudo xm console debian-lenny[/B] [I][ lots of boot output goes here ][/I] Starting periodic command scheduler: crond. Debian GNU/Linux 5.0 debian-lenny hvc0 [B]debian-lenny login: root Password: [/B] Linux debian-lenny 2.6.26-2-xen-amd64 #1 SMP Thu Aug 20 00:36:34 UTC 2009 x86_64 The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. [B]debian-lenny:~# echo -e "\n\n\nThank you, \n"'Falko!!!'"\n\n\n"[/B] Thank you, Falko!!! [B]debian-lenny:~# [/B]