Skip to contentSkip to conversation

xen-3.0.3 occur kernel panic

Xen-users Wei Jiang 2 participants 6 messages Feb 25, 2008 – Feb 27, 2008 4 messages not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

Wei Jiang

author
#2 lore raw

Hi,

Maybe Xen 3.1 will work well on RHEL-5.1. But I want to see what happened on RHEL5.

From my tracing, I found, If commented apic option in guest OS config file, the Xen(3.0) can run a guest OS in a good status. Otherwise, the kernel will panic.

There is a guest OS config file that can run without error.
-----------------------------------------------------------
# Automatically generated xen config file
name = "fvguest"
builder = "hvm"
memory = "500"
disk = [ 'file:/mnt/fvguest,hda,w', ]
vif = [ 'type=ioemu, mac=00:16:3e:23:21:ec, bridge=xenbr0', ] uuid = "7301d7ec-e036-11d7-d14b-b21be1c783be" device_model = "/usr/lib64/xen/bin/qemu-dm"
kernel = "/usr/lib/xen/boot/hvmloader"
vnc=1
vncunused=1
*#apic=1*
acpi=1
pae=1

vcpus=1
serial = "pty" # enable serial console
on_reboot = 'restart'
on_crash = 'restart'

From the kernel panic messages, I found that happened at line 2245 of mm/memory.c

2244 pte_unmap(page_table);
* 2245 BUG_ON(vma->vm_flags & VM_PFNMAP);*
2246
2247 if (vma->vm_file) {

As we can see, the kernel panic because the vm_flags in a *VM_PFNMAP*

But why the vm_flags was set to VM_PFNMAP, If it is related to *APIC* ?

Anybody can show ideas?

Thanks advance

--Wj

Quoted 122 lines · Sadique Puthen

Hi,

Please upgrade your system to RHEL-5.1 which has xen rebased to 3.1 version. I think this panic would go away once you update to RHEL-5.1.

--Sadique

Quoted 111 lines · Wei Jiang

Hi everybody,

the xen-3.0.3 will occur a kernel panic when attempt to run a full virtualization guest OS.

the configure of guest OS as below:
---------------------------------------------------------------------------

# Automatically generated xen config file
name = "fvguest"
builder = "hvm"
memory = "500"
disk = [ 'file:/mnt/fvguest,hda,w', ]
vif = [ 'type=ioemu, mac=00:16:3e:23:21:ec, bridge=xenbr0', ] uuid = "7301d7ec-e036-11d7-d14b-b21be1c783be" device_model = "/usr/lib64/xen/bin/qemu-dm"
kernel = "/usr/lib/xen/boot/hvmloader"
vnc=1
vncunused=1
apic=1
acpi=1
pae=1

vcpus=1
serial = "pty" # enable serial console
on_reboot = 'restart'
on_crash = 'restart'

---------------------------------------------------------------------------

When I run such a guest OS, the kernel panic is occurred.

# xm create fvguest

----------- [cut here ] --------- [please bite here ] ---------

Kernel BUG at mm/memory.c:2245
invalid opcode: 0000 [1] SMP
last sysfs file: /block/loop6/range
CPU 0
Modules linked in: loop xt_physdev iptable_filter ip_tables x_tables tun bridge netloop netbk blktap blkbk autofs4 hidp rfcomm l2cap bluetooth sunrpc ipv6 video sbs i2c_ec i2c_core button battery asus_acpi ac parport_pc lp parport sr_mod cdrom sg shpchp serio_raw serial_core pcspkr ext3 jbd ehci_hcd ohci_hcd uhci_hcd
Pid: 4096, comm: qemu-dm Tainted: PF     2.6.18-8.el5xen #1
RIP: e030:[<ffffffff80208b33>]  [<ffffffff80208b33>] __handle_mm_fault+0x379/0xf46
RSP: e02b:ffff8807ac451de8  EFLAGS: 00010202
RAX: ffffffff805093c0 RBX: 0000000000000df8 RCX: 00003ffffffff000
RDX: 00000007abf6edf8 RSI: 0000000000000067 RDI: ffff8807db3db040
RBP: ffff8807db3db040 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000001 R11: 0000000000000246 R12: 0000000000000000
R13: ffff8807abf6edf8 R14: 00002aaacafbf000 R15: ffff8807d2dbf870
FS:  00002aaaaaabd010(0000) GS:ffffffff8058d000(0000) knlGS:0000000000000000
CS:  e033 DS: 0000 ES: 0000
Process qemu-dm (pid: 4096, threadinfo ffff8807ac450000, task ffff8807d42d1860)
Stack:  00000000fffffff2  0000000180274661  ffff8807db3db040  ffff8807ac73d2b8
 0000000000001000  00002aaacb7be000  ffff8807db3db040  ffffffff802606e9
 ffff8807db3db0a8  ffffffff80221dde
Call Trace:
 [<ffffffff802606e9>] _spin_lock_irqsave+0x9/0x14
 [<ffffffff80221dde>] __up_read+0x19/0x7f
 [<ffffffff80262fc6>] do_page_fault+0xe48/0x11dc
 [<ffffffff8025cb53>] error_exit+0x0/0x6e


Code: 0f 0b 68 21 bd 46 80 c2 c5 08 49 8b 87 90 00 00 00 48 c7 44
RIP  [<ffffffff80208b33>] __handle_mm_fault+0x379/0xf46
 RSP <ffff8807ac451de8>
 <0>Kernel panic - not syncing: Fatal exception

The system is redhat 5:

# cat /etc/redhat-release erver release 5 (Tikanga)
Red Hat Enterprise Linux Server release 5 (Tikanga)
# uname -a                                                       Linux wjiang 2.6.18-8.el5xen #1 SMP Fri Jan 26 14:29:35 EST 2007 x86_64 x86_64 x86_64 GNU/Linux

And the xen occurred the panic is 3.0.3,

# cat /usr/share/doc/xen-3.0.3/README
################################
 __  __            _____  ___
 \ \/ /___ _ __   |___ / / _ \
  \  // _ \ '_ \    |_ \| | | |
  /  \  __/ | | |  ___) | |_| |
 /_/\_\___|_| |_| |____(_)___/

################################

Quoted 1 line

From the kernel panic message, I doubt this is qemu-dm bug, so I

download the xen 3.0.3
from official site. I recompiled the qemu-dm and used it instead of the system qemu-dm. But the panic was still occurred when running the 'xm create fvguest'. Look the /var/log/message and /var/log/xen/*, there are no any useful message .

could anybody show any helps or advices? Also, If I want to debug it, what I need to do? As I know, the kdump is not supported in xen kernel.

Thanks advances,

WJ

__________________________________________________________________________________________________________________

DISCLAIMER:"The information contained in this message and the attachments (if any) may be privileged and confidential and protected from disclosure. You are hereby notified that any unauthorized use, dissemination, distribution or copying of this communication, review, retransmission, or taking of any action based upon this information, by persons or entities other than the intended recipient, is strictly prohibited. If you are not the intended recipient or an employee or agent responsible for delivering this message, and have received this communication in error, please notify us immediately by replying to the message and kindly delete the original message, attachments, if any, and all its copies from your computer system. Thank you for your cooperation."
________________________________________________________________________________________________________________

------------------------------------------------------------------------

_______________________________________________
Xen-users mailing list
[email protected]
http://lists.xensource.com/xen-users

__________________________________________________________________________________________________________________
DISCLAIMER:"The information contained in this message and the attachments (if any) may be privileged and confidential and protected from disclosure. You are hereby notified that any unauthorized use, dissemination, distribution or copying of this communication, review, retransmission, or taking of any action based upon this information, by persons or entities other than the intended recipient, is strictly prohibited. If you are not the intended recipient or an employee or agent responsible for delivering this message, and have received this communication in error, please notify us immediately by replying to the message and kindly delete the original message, attachments, if any, and all its copies from your computer system. Thank you for your cooperation." ________________________________________________________________________________________________________________

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel

author
#3 lore raw
In reply to a message not in the archive

Hi,

Maybe Xen 3.1 will work well on RHEL-5.1. But I want to see what happened on RHEL5.

From my tracing, I found, If commented apic option in guest OS config file, the Xen(3.0) can run a guest OS in a good status. Otherwise, the kernel will panic.

There is a guest OS config file that can run without error.
-----------------------------------------------------------
# Automatically generated xen config file
name = "fvguest"
builder = "hvm"
memory = "500"
disk = [ 'file:/mnt/fvguest,hda,w', ]
vif = [ 'type=ioemu, mac=00:16:3e:23:21:ec, bridge=xenbr0', ] uuid = "7301d7ec-e036-11d7-d14b-b21be1c783be" device_model = "/usr/lib64/xen/bin/qemu-dm"
kernel = "/usr/lib/xen/boot/hvmloader"
vnc=1
vncunused=1
*#apic=1*
acpi=1
pae=1

vcpus=1
serial = "pty" # enable serial console
on_reboot = 'restart'
on_crash = 'restart'

From the kernel panic messages, I found that happened at line 2245 of mm/memory.c

2244 pte_unmap(page_table);
* 2245 BUG_ON(vma->vm_flags & VM_PFNMAP);*
2246
2247 if (vma->vm_file) {

As we can see, the kernel panic because the vm_flags in a *VM_PFNMAP*

But why the vm_flags was set to VM_PFNMAP, If it is related to *APIC* ?

Anybody can show ideas?

Thanks advance

--Wj

Quoted 122 lines · Sadique Puthen

Hi,

Please upgrade your system to RHEL-5.1 which has xen rebased to 3.1 version. I think this panic would go away once you update to RHEL-5.1.

--Sadique

Quoted 111 lines · Wei Jiang

Hi everybody,

the xen-3.0.3 will occur a kernel panic when attempt to run a full virtualization guest OS.

the configure of guest OS as below:
---------------------------------------------------------------------------

# Automatically generated xen config file
name = "fvguest"
builder = "hvm"
memory = "500"
disk = [ 'file:/mnt/fvguest,hda,w', ]
vif = [ 'type=ioemu, mac=00:16:3e:23:21:ec, bridge=xenbr0', ] uuid = "7301d7ec-e036-11d7-d14b-b21be1c783be" device_model = "/usr/lib64/xen/bin/qemu-dm"
kernel = "/usr/lib/xen/boot/hvmloader"
vnc=1
vncunused=1
apic=1
acpi=1
pae=1

vcpus=1
serial = "pty" # enable serial console
on_reboot = 'restart'
on_crash = 'restart'

---------------------------------------------------------------------------

When I run such a guest OS, the kernel panic is occurred.

# xm create fvguest

----------- [cut here ] --------- [please bite here ] ---------

Kernel BUG at mm/memory.c:2245
invalid opcode: 0000 [1] SMP
last sysfs file: /block/loop6/range
CPU 0
Modules linked in: loop xt_physdev iptable_filter ip_tables x_tables tun bridge netloop netbk blktap blkbk autofs4 hidp rfcomm l2cap bluetooth sunrpc ipv6 video sbs i2c_ec i2c_core button battery asus_acpi ac parport_pc lp parport sr_mod cdrom sg shpchp serio_raw serial_core pcspkr ext3 jbd ehci_hcd ohci_hcd uhci_hcd
Pid: 4096, comm: qemu-dm Tainted: PF     2.6.18-8.el5xen #1
RIP: e030:[<ffffffff80208b33>]  [<ffffffff80208b33>] __handle_mm_fault+0x379/0xf46
RSP: e02b:ffff8807ac451de8  EFLAGS: 00010202
RAX: ffffffff805093c0 RBX: 0000000000000df8 RCX: 00003ffffffff000
RDX: 00000007abf6edf8 RSI: 0000000000000067 RDI: ffff8807db3db040
RBP: ffff8807db3db040 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000001 R11: 0000000000000246 R12: 0000000000000000
R13: ffff8807abf6edf8 R14: 00002aaacafbf000 R15: ffff8807d2dbf870
FS:  00002aaaaaabd010(0000) GS:ffffffff8058d000(0000) knlGS:0000000000000000
CS:  e033 DS: 0000 ES: 0000
Process qemu-dm (pid: 4096, threadinfo ffff8807ac450000, task ffff8807d42d1860)
Stack:  00000000fffffff2  0000000180274661  ffff8807db3db040  ffff8807ac73d2b8
 0000000000001000  00002aaacb7be000  ffff8807db3db040  ffffffff802606e9
 ffff8807db3db0a8  ffffffff80221dde
Call Trace:
 [<ffffffff802606e9>] _spin_lock_irqsave+0x9/0x14
 [<ffffffff80221dde>] __up_read+0x19/0x7f
 [<ffffffff80262fc6>] do_page_fault+0xe48/0x11dc
 [<ffffffff8025cb53>] error_exit+0x0/0x6e


Code: 0f 0b 68 21 bd 46 80 c2 c5 08 49 8b 87 90 00 00 00 48 c7 44
RIP  [<ffffffff80208b33>] __handle_mm_fault+0x379/0xf46
 RSP <ffff8807ac451de8>
 <0>Kernel panic - not syncing: Fatal exception

The system is redhat 5:

# cat /etc/redhat-release erver release 5 (Tikanga)
Red Hat Enterprise Linux Server release 5 (Tikanga)
# uname -a                                                       Linux wjiang 2.6.18-8.el5xen #1 SMP Fri Jan 26 14:29:35 EST 2007 x86_64 x86_64 x86_64 GNU/Linux

And the xen occurred the panic is 3.0.3,

# cat /usr/share/doc/xen-3.0.3/README
################################
 __  __            _____  ___
 \ \/ /___ _ __   |___ / / _ \
  \  // _ \ '_ \    |_ \| | | |
  /  \  __/ | | |  ___) | |_| |
 /_/\_\___|_| |_| |____(_)___/

################################

Quoted 1 line

From the kernel panic message, I doubt this is qemu-dm bug, so I

download the xen 3.0.3
from official site. I recompiled the qemu-dm and used it instead of the system qemu-dm. But the panic was still occurred when running the 'xm create fvguest'. Look the /var/log/message and /var/log/xen/*, there are no any useful message .

could anybody show any helps or advices? Also, If I want to debug it, what I need to do? As I know, the kdump is not supported in xen kernel.

Thanks advances,

WJ

__________________________________________________________________________________________________________________

DISCLAIMER:"The information contained in this message and the attachments (if any) may be privileged and confidential and protected from disclosure. You are hereby notified that any unauthorized use, dissemination, distribution or copying of this communication, review, retransmission, or taking of any action based upon this information, by persons or entities other than the intended recipient, is strictly prohibited. If you are not the intended recipient or an employee or agent responsible for delivering this message, and have received this communication in error, please notify us immediately by replying to the message and kindly delete the original message, attachments, if any, and all its copies from your computer system. Thank you for your cooperation."
________________________________________________________________________________________________________________

------------------------------------------------------------------------

_______________________________________________
Xen-users mailing list
[email protected]
http://lists.xensource.com/xen-users

__________________________________________________________________________________________________________________
DISCLAIMER:"The information contained in this message and the attachments (if any) may be privileged and confidential and protected from disclosure. You are hereby notified that any unauthorized use, dissemination, distribution or copying of this communication, review, retransmission, or taking of any action based upon this information, by persons or entities other than the intended recipient, is strictly prohibited. If you are not the intended recipient or an employee or agent responsible for delivering this message, and have received this communication in error, please notify us immediately by replying to the message and kindly delete the original message, attachments, if any, and all its copies from your computer system. Thank you for your cooperation." ________________________________________________________________________________________________________________

_______________________________________________
Xen-users mailing list
[email protected]
http://lists.xensource.com/xen-users

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel

A message that is not in the archive (sent off-list or not yet received): [email protected]

#5 lore raw
Quoted 4 lines · Wei Jiang
Quoted 1 line

From the kernel panic messages, I found that happened

at line 2245 of mm/memory.c

   2244         pte_unmap(page_table);
Quoted 8 lines

* 2245 BUG_ON(vma->vm_flags & VM_PFNMAP);*
2246
2247 if (vma->vm_file) {

As we can see, the kernel panic because the vm_flags in a *VM_PFNMAP*

But why the vm_flags was set to VM_PFNMAP, If it is related to *APIC* ?

Yes, Sadique is right. This bug was fixed in 5.1, and will be further refined in 5.2.

Chris Lalancette

author
#6 lore raw

Hi

About such a issue, are there any code changes?

Thanks,

--Wj

Quoted 13 lines · Chris Lalancette
Quoted 11 lines · Wei Jiang
Quoted 1 line

From the kernel panic messages, I found that happened

at line 2245 of mm/memory.c

   2244         pte_unmap(page_table);

* 2245 BUG_ON(vma->vm_flags & VM_PFNMAP);*
2246
2247 if (vma->vm_file) {

As we can see, the kernel panic because the vm_flags in a *VM_PFNMAP*

Quoted 9 lines
Quoted 2 lines

But why the vm_flags was set to VM_PFNMAP, If it is related to *APIC* ?

Yes, Sadique is right. This bug was fixed in 5.1, and will be further refined in 5.2.

Chris Lalancette

__________________________________________________________________________________________________________________
DISCLAIMER:"The information contained in this message and the attachments (if any) may be privileged and confidential and protected from disclosure. You are hereby notified that any unauthorized use, dissemination, distribution or copying of this communication, review, retransmission, or taking of any action based upon this information, by persons or entities other than the intended recipient, is strictly prohibited. If you are not the intended recipient or an employee or agent responsible for delivering this message, and have received this communication in error, please notify us immediately by replying to the message and kindly delete the original message, attachments, if any, and all its copies from your computer system. Thank you for your cooperation." ________________________________________________________________________________________________________________

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel

author
#7 lore raw
In reply to Chris Lalancette

Hi

About such a issue, are there any code changes?

Thanks,

--Wj

Quoted 13 lines · Chris Lalancette
Quoted 11 lines · Wei Jiang
Quoted 1 line

From the kernel panic messages, I found that happened

at line 2245 of mm/memory.c

   2244         pte_unmap(page_table);

* 2245 BUG_ON(vma->vm_flags & VM_PFNMAP);*
2246
2247 if (vma->vm_file) {

As we can see, the kernel panic because the vm_flags in a *VM_PFNMAP*

Quoted 9 lines
Quoted 2 lines

But why the vm_flags was set to VM_PFNMAP, If it is related to *APIC* ?

Yes, Sadique is right. This bug was fixed in 5.1, and will be further refined in 5.2.

Chris Lalancette

__________________________________________________________________________________________________________________
DISCLAIMER:"The information contained in this message and the attachments (if any) may be privileged and confidential and protected from disclosure. You are hereby notified that any unauthorized use, dissemination, distribution or copying of this communication, review, retransmission, or taking of any action based upon this information, by persons or entities other than the intended recipient, is strictly prohibited. If you are not the intended recipient or an employee or agent responsible for delivering this message, and have received this communication in error, please notify us immediately by replying to the message and kindly delete the original message, attachments, if any, and all its copies from your computer system. Thank you for your cooperation." ________________________________________________________________________________________________________________

_______________________________________________
Xen-users mailing list
[email protected]
http://lists.xensource.com/xen-users

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel

A message that is not in the archive (sent off-list or not yet received): [email protected]

#9 lore raw
Quoted 4 lines · Wei Jiang

Hi

About such a issue, are there any code changes?

Yes. In 5.1 we "fixed" it by removing the nopage handler from privcmd; having VM_PFNMAP with a nopage handler just makes no sense. However, the problem with it is that if userland did something it wasn't supposed
to, it would actually get a page full of zeros instead of a SIGBUS. In
5.2 I believe we have added a nopfn handler which returns SIGBUS if the userland program does the wrong thing.

Chris Lalancette