[CentOS-virt] xendomains not autostarting

Ben M. centos at rivint.com
Mon Nov 30 19:18:29 UTC 2009

Thanks, you gave me some solid points to check that I hadn't fully and I 
think I know a little more.

My chkconfig run level 2 was on, but runlevel was at "N 3". I toggled 
off, rebooted, no difference. Toggled on and off for the rest of the 

Everything checked out except for XENDOMAINS_RESTORE=true
which is default. I set it to false, toggled the runlevel 2 for a couple 
of reboot checks. No joy, but ...

Oddly I am getting Saves, even though DESTROY is explicitly set in the 
vm's conf to all circumstances:

name = 'v22c54'
uuid = 'a3199faf-edb4-42e5-bea1-01f2df77a47f'
maxmem = 512
memory = 512
vcpus = 1
bootloader = '/usr/bin/pygrub'
on_poweroff = 'destroy'
on_reboot = 'destroy'
on_crash = 'destroy'
vfb = [ 'type=vnc,vncunused=1,keymap=en-us' ]
# note selinux is off now, but the privileges are set correctly
disk = [ 'tap:aio:/var/lib/xen/images/vms/v22c54,xvda,w' ]
vif = [ 'mac=00:16:36:41:76:ae,bridge=xenbr1' ]

I then slapped it around a bit and another quirk appeared.

 From a fresh boot, I then manually started xendomains service. v22c54 
comes up. I did an xm shut and it reported it shut, nothing in the Save 
folder. However, check this out:

[root at river22 ~]# service xendomains start
Starting auto Xen domains: v22c54[done]                    [  OK  ]
[root at river22 ~]# xm list
Name                             ID Mem(MiB) VCPUs State   Time(s)
Domain-0                          0     1024     2 r-----     24.7
v22c54                            1      511     1 r-----      9.0

[root at river22 ~]# xm shutdown v22c54
(no echo)

(I then tried to bring it back up, it balks, its not there and I see a 
boot_kernel.random and a boot_ramdisk.random come up in /var/lib/xen)

[root at river22 ~]# xm create v22c54
Using config file "/etc/xen/v22c54".
Error: VM name 'v22c54' already in use by domain 1

(it isn't there)
[root at river22 ~]# xm list
Name                             ID Mem(MiB) VCPUs State   Time(s)
Domain-0                          0     1024     2 r-----     29.7
[root at river22 ~]# xm shutdown v22c54
Error: Domain 'v22c54' does not exist.
Usage: xm shutdown <Domain> [-waRH]

Shutdown a domain.
[root at river22 ~]# xm list
Name                                      ID Mem(MiB) VCPUs State   Time(s)
Domain-0                                   0     1024     2 r-----     29.9

I certainly like to know why things glitch and don't mind seeing this 
through a little further, but I am beginning to wonder if I should just 
backup the domU's and try a fresh installation.

Is it possible I am running into a naming convention on these domUs?

My first 3 chars help me determine on which host the virtual machine was 
originally created.

Eric Searcy wrote:
> On Nov 30, 2009, at 8:26 AM, Ben M. wrote:
>> I have been scratching my head on this for days. Xendomains services 
>> just doesn't want to start at boot it seems, so I don't get my 
>> auto-domU's up without "service xendomains start" and the all start.
>> chkconfig looks correct, I have checked xm dmesg, dmesg, turned off 
>> selinux and the only "clue" I have is that the xend.log startup looks 
>> different than a fairly similar machine and I don't quite understand 
>> what it might be saying. Is dom0 crashing and restarting at machine bootup?
>> I have only one domU in ../auto to keep this simpler, its name is 
>> "v22c54" and I have one other anomaly: smartd is also not starting on 
>> services boot up but apparently runs fine with a manual command.
> I'm guessing you covered this ("chkconfig looks correct") but you didn't change to a different runlevel like 2 did you?
> [root at xen1 ~]# chkconfig --list xendomains
> xendomains      0:off   1:off   2:off   3:on    4:on    5:on    6:off
> [root at xen1 ~]# grep :initdefault /etc/inittab 
> id:3:initdefault:
> [root at xen1 ~]# runlevel
> N 3
> Also, I'm not too familiar with it, but if you're not shutting your domains off before reboot there may be something awry with the save/restore functionality.  Personally I have this disabled so I can't speak to whether it would create the symptom you have, but it might be something to try.  I have:
> [root at xen1 ~]# grep "^[^#]" /etc/sysconfig/xendomains 
> XENDOMAINS_SHUTDOWN="--halt --wait"
> XENDOMAINS_SHUTDOWN_ALL="--all --halt --wait"
> XENDOMAINS_AUTO=/etc/xen/auto
> Eric
> _______________________________________________
> CentOS-virt mailing list
> CentOS-virt at centos.org
> http://lists.centos.org/mailman/listinfo/centos-virt

More information about the CentOS-virt mailing list