Skip to contentSkip to conversation

Xen "restarting system" on Fedora FC4

DISCUSSION Tony Jones 4 participants 9 messages Mar 2, 2005

lore
Share & tools
lore

Tony Jones

author
#0 lore raw

I posted this to the Fedora-test list but I'll try here.

If I need to ditch fedora rpms and move to building directly from src before posting here, please let me know and I'll do so (apologies in advance if this is the case).

I have the following Fedora RPMS installed:

        kernel-xen0-2.6.10-1.1155_FC4
        kernel-xenU-2.6.10-1.1155_FC4
        xen-2-20050222

I can boot the main (domain-0) kernel (2.6.10-1.1155_FC4xen0). All seems well.

When I try to start domain-1 (which has it's own root and swap partitions) it starts up and then just reboots without any indication as to why.

A snippet of the beginning and end of the console output:

# /usr/sbin/xm  create -c dylan-xen1.conf vmid=1
Using config file "dylan-xen1.conf".
Started domain Dylan-dom1, console on port 9606
************ REMOTE CONSOLE: CTRL-] TO QUIT ********
Linux version 2.6.10-1.1155_FC4xenU ([email protected]) (gcc version 3.4.3 20050221 (Red Hat 3.4.3-20)) #1 SMP Sat Feb 26 20:32:34 EST 2005
BIOS-provided physical RAM map:                                          
 Xen: 0000000000000000 - 0000000004000000 (usable)
64MB LOWMEM available.                            
Using x86 segment limits to approximate NX protection
DMI not present.                                     
IRQ lockup detection disabled
Built 1 zonelists            
Kernel command line:  root=/dev/hda2 rw s
Initializing CPU#0                       
PID hash table entries: 1024 (order: 10, 16384 bytes)
Xen reported: 2399.968 MHz processor.                
Using tsc for high-res timesource    
Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)  
Memory: 61328k/65536k available (1319k kernel code, 4116k reserved, 477k data, 128k init, 0k highmem)
Checking if this processor honours the WP bit even in supervisor mode... Ok.
...
...
...
Initializing IPsec netlink socket
NET: Registered protocol family 1
NET: Registered protocol family 17
md: Autodetecting RAID arrays.
md: autorun ...
md: ... autorun DONE.
kjournald starting.  Commit interval 5 seconds
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem) readonly.
Freeing unused kernel memory: 128k freed
Warning: unable to open an initial console.
SELinux:  Disabled at runtime.
SELinux:  Unregistering netfilter hooks
Restarting system.

I get the following in dmesg:
device vif7.0 entered promiscuous mode
xen-br0: port 2(vif7.0) entering learning state
xen-br0: topology change detected, propagating
xen-br0: port 2(vif7.0) entering forwarding state
vif7.0: no IPv6 routers present

At this point the console is non-interruptable (I can leave it for hours) until on another window I run an 'xm list' which shows the domain to be shutting down. If I run 'xm list' again there is no entry for the domain and at this point I can interrupt the 'xm create' console.

# xm list
Name              Id  Mem(MB)  CPU  State  Time(s)  Console
Domain-0          0      121   0   r----    435.5 
dylan-dom1         4       64   0   ---s-      1.6    9604

The non default aspects of my config are:
kernel = "/boot/vmlinuz-2.6.10-1.1155_FC4xenU"
memory = 64
name = "dylan-dom1"

# hda2 is /   hda6 is swap
disk = [ 'phy:hda2,hda2,w' , 'phy:hda6,hda6,w' ]
root = "/dev/hda2 ro"
extra = "s"
restart = 'never'

Anyone have any clues?

Thanks

Tony

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

#1 lore raw
Quoted 3 lines

If I need to ditch fedora rpms and move to building directly from src before posting here, please let me know and I'll do so (apologies in advance if this is the case).

No probs with the RPMS. We occasionally ask people to rebuild stuff to try out specific things but that shouldn't be necessary this time.

Quoted 2 lines

I can boot the main (domain-0) kernel (2.6.10-1.1155_FC4xen0). All seems well.

Great!

Quoted 5 lines

kjournald starting. Commit interval 5 seconds
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem) readonly. Freeing unused kernel memory: 128k freed
Warning: unable to open an initial console.

You'll be using udev, so you need an initrd to create the initial console.

Quoted 4 lines

The non default aspects of my config are:
kernel = "/boot/vmlinuz-2.6.10-1.1155_FC4xenU"
memory = 64
name = "dylan-dom1"

Quoted 8 lines
# hda2 is /   hda6 is swap
disk = [ 'phy:hda2,hda2,w' , 'phy:hda6,hda6,w' ]
root = "/dev/hda2 ro"
extra = "s"
restart = 'never'

Anyone have any clues?

You need to add an "initrd = /boot/whatever" (I forget the exact path but it'll probably be somethink like "/boot/initrd-2.6.10-blah-xen"). That should sort you out.

Cheers,
Mark

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

#2 lore raw
In reply to Tony Jones
Quoted 3 lines · Tony Jones

If I need to ditch fedora rpms and move to building directly from src before posting here, please let me know and I'll do so (apologies in advance if this is the case).

Using the Fedora RPMs is fine - they're very close to Xen upstream and I'll do my best to support them.

Quoted 2 lines

When I try to start domain-1 (which has it's own root and swap partitions) it starts up and then just reboots without any indication as to why.

I have not seen this happen on my systems. What hardware are you using? How much memory?

Quoted 9 lines

The non default aspects of my config are:
kernel = "/boot/vmlinuz-2.6.10-1.1155_FC4xenU"
memory = 64
name = "dylan-dom1"

# hda2 is /   hda6 is swap
disk = [ 'phy:hda2,hda2,w' , 'phy:hda6,hda6,w' ]
root = "/dev/hda2 ro"
extra = "s"
restart = 'never'

You're not sharing these with domain 0, are you ?

Signature · 10 lines
"Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are,
by definition, not smart enough to debug it." - Brian W. Kernighan


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
author
#3 lore raw
Quoted 6 lines · Rik van Riel
Quoted 3 lines

If I need to ditch fedora rpms and move to building directly from src before posting here, please let me know and I'll do so (apologies in advance if this is the case).

Using the Fedora RPMs is fine - they're very close to Xen upstream and I'll do my best to support them.

Thanks.

Quoted 2 lines

I have not seen this happen on my systems. What hardware are you using? How much memory?

It's a homegrown (of course :-) Intel mobo (forget what type). P4 2.4ghz. 128MB of ram.

Quoted 11 lines
Quoted 9 lines

The non default aspects of my config are:
kernel = "/boot/vmlinuz-2.6.10-1.1155_FC4xenU"
memory = 64
name = "dylan-dom1"

# hda2 is /   hda6 is swap
disk = [ 'phy:hda2,hda2,w' , 'phy:hda6,hda6,w' ]
root = "/dev/hda2 ro"
extra = "s"
restart = 'never'

You're not sharing these with domain 0, are you ?

No. Domain0 has root on /dev/hda1 and swap on /dev/hda5. I read the docs pretty carefully and I figured for initial tryout I was better off staying away from trying to share devices,

As for the initrd comment from Mark. The domU rpm from RH doesn't
provide one. There is one provided by the dom0 rpm. I'm sure I
can create one if necessary, I would have expected the RH rpm to do it. Do you specify the initrd in the "ramdisk=" config option?

Thanks for the speedy replies.

Tony

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

#4 lore raw
Quoted 4 lines · Tony Jones

As for the initrd comment from Mark. The domU rpm from RH doesn't
provide one. There is one provided by the dom0 rpm. I'm sure I
can create one if necessary, I would have expected the RH rpm to do it. Do you specify the initrd in the "ramdisk=" config option?

The domU kernel doesn't usually need an initrd, since ext3 is compiled in. Once we have a "boot loader" for the unprivileged domains, we can get rid of the xen0 and xenU kernels, and have just one kernel-xen ...

Signature · 10 lines
"Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are,
by definition, not smart enough to debug it." - Brian W. Kernighan


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
author
#5 lore raw
Quoted 11 lines · Rik van Riel
Quoted 4 lines · Tony Jones

As for the initrd comment from Mark. The domU rpm from RH doesn't
provide one. There is one provided by the dom0 rpm. I'm sure I
can create one if necessary, I would have expected the RH rpm to do it. Do you specify the initrd in the "ramdisk=" config option?

The domU kernel doesn't usually need an initrd, since ext3 is compiled in. Once we have a "boot loader" for the unprivileged domains, we can get rid of the xen0 and xenU kernels, and have just one kernel-xen ...

Correct. I wasn't expecting to need one for fs.

Mark was referring to needing one for the console (udev).

Whether the "Warning: unable to open an initial console." message has any bearing on the fact that the machine reboots a little later after SELinux starts I'm unsure of. I was assuming it wasn't related ~shrug~

Can I blame SELinux :)

Tony

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

#6 lore raw
In reply to Rik van Riel
Quoted 9 lines
Quoted 4 lines

As for the initrd comment from Mark. The domU rpm from RH doesn't
provide one. There is one provided by the dom0 rpm. I'm sure I
can create one if necessary, I would have expected the RH rpm to do it. Do you specify the initrd in the "ramdisk=" config option?

The domU kernel doesn't usually need an initrd, since ext3 is compiled in. Once we have a "boot loader" for the unprivileged domains, we can get rid of the xen0 and xenU kernels, and have just one kernel-xen ...

I thought the initrd was needed on Fedora so that udev would work? Is that not correct?

Cheers,
Mark

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

author
#7 lore raw
Quoted 5 lines · Mark Williamson
Quoted 5 lines
Quoted 4 lines

As for the initrd comment from Mark. The domU rpm from RH doesn't
provide one. There is one provided by the dom0 rpm. I'm sure I
can create one if necessary, I would have expected the RH rpm to do it. Do you specify the initrd in the "ramdisk=" config option?

Quoted 7 lines
Quoted 4 lines

The domU kernel doesn't usually need an initrd, since ext3 is compiled in. Once we have a "boot loader" for the unprivileged domains, we can get rid of the xen0 and xenU kernels, and have just one kernel-xen ...

I thought the initrd was needed on Fedora so that udev would work? Is that not correct?

Mark/Rik.

You are correct. I needed an initrd. Perhaps the warning about "unable to open console" should be more than a warning :)

It now boots to single user.

Also, it's "ramdisk = *.img" not "initrd = *.img".

I had to generate a modules.dep file first for the U kernel and had to run initrd with --omit-scsi-modules as otherwise it complained about there not being a module for sata_sil.

Thanks much.

Tony

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

#8 lore raw
Quoted 11 lines · Tony Jones
Quoted 10 lines · Mark Williamson
Quoted 9 lines
Quoted 4 lines

As for the initrd comment from Mark. The domU rpm from RH doesn't
provide one. There is one provided by the dom0 rpm. I'm sure I
can create one if necessary, I would have expected the RH rpm to do it. Do you specify the initrd in the "ramdisk=" config option?

The domU kernel doesn't usually need an initrd, since ext3 is compiled in. Once we have a "boot loader" for the unprivileged domains, we can get rid of the xen0 and xenU kernels, and have just one kernel-xen ...

Quoted 7 lines
Quoted 2 lines

I thought the initrd was needed on Fedora so that udev would work? Is that not correct?

Mark/Rik.

You are correct. I needed an initrd. Perhaps the warning about "unable to open console" should be more than a warning :)

There's another solution to provide the initial console devices, see

<http://fedora.redhat.com/docs/udev/>

Mount and chroot into the rootfs (or boot it somehow and move udev away: "mkdir /tmp/dev; mount --move /dev /tmp/dev") Create all devices you need before udev is started:

/sbin/MAKEDEV null console zero

(maybe "null tty0 zero" would be enough) (If you booted it, put udev back in its place: "mount --move /tmp/dev /dev") No initrds needed anymore.

/nils.

Signature · 8 lines
there is no sig.


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click