Skip to contentSkip to conversation

2.6.26 Debian kernel panic

DISCUSSION Russell Coker 2 participants 5 messages Oct 28, 2008 – Nov 15, 2008 SELinux security module

lore
Share & tools
lore
#0 lore raw

Below are the syslog messages from a kernel panic when running 2.6.26. To trigger it I ran "semodule -i sendmail.pp" on a machine with the exim policy loaded (not something that you expect people to do - but not something you expect to cause a problem either) and load_policy went into an infinite loop (100% CPU use - strace reported no syscalls being made). At that stage "kill -9" seemed like the right solution, killing load_policy gave the following result.

I've tried to reproduce it but have been unsuccessful. The machine in question is a Xen DomU, I believe that the hardware has ECC RAM and is of generally good quality.

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ... redcape kernel: [399681.381737] Eeek! page_mapcount(page) went negative! (-1)

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381755] page pfn = 3

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381760] page->flags = 400

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381766] page->count = 1

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381770] page->mapping = 0000000000000000

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381780] vma->vm_ops = 0x0

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ... redcape kernel: [399681.381799] ------------[ cut here ]------------

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ... redcape kernel: [399681.381811] invalid opcode: 0000 [1] SMP

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ... redcape kernel: [399681.381828] Code: 80 e8 3c 0c fd ff 48 8b 85 90 00 00 00 48
85 c0 74 19 48 8b 40 20 48 85 c0 74 10 48 8b 70 58 48 c7 c7 66 52 4b 80 e8 17 0c
fd ff <0f> 0b eb fe 8b 77 18 41 58 5b 5d 83 e6 01 f7 de 83 c6 04 e9 6c

Signature · 9 lines
Russell Coker <[email protected]>
http://etbe.coker.com.au/          My Blog
http://etbe.coker.com.au/category/security/  My Security blog posts
http://www.coker.com.au/selinux/play.html  My Play Machine, root PW "SELINUX"

--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to [email protected] with
the words "unsubscribe selinux" without quotes as the message.
#1 lore raw
Quoted 7 lines · Russell Coker

Below are the syslog messages from a kernel panic when running 2.6.26. To trigger it I ran "semodule -i sendmail.pp" on a machine with the exim policy loaded (not something that you expect people to do - but not something you expect to cause a problem either) and load_policy went into an infinite loop (100% CPU use - strace reported no syscalls being made). At that stage "kill -9" seemed like the right solution, killing load_policy gave the following result.

Can you make a tarball of your /etc/selinux directory prior to inserting sendmail.pp available somewhere, and a copy of that sendmail.pp file?

Quoted 35 lines

I've tried to reproduce it but have been unsuccessful. The machine in question is a Xen DomU, I believe that the hardware has ECC RAM and is of generally good quality.

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ... redcape kernel: [399681.381737] Eeek! page_mapcount(page) went negative! (-1)

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381755] page pfn = 3

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381760] page->flags = 400

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381766] page->count = 1

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381770] page->mapping = 0000000000000000

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381780] vma->vm_ops = 0x0

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ... redcape kernel: [399681.381799] ------------[ cut here ]------------

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ... redcape kernel: [399681.381811] invalid opcode: 0000 [1] SMP

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ... redcape kernel: [399681.381828] Code: 80 e8 3c 0c fd ff 48 8b 85 90 00 00 00 48
85 c0 74 19 48 8b 40 20 48 85 c0 74 10 48 8b 70 58 48 c7 c7 66 52 4b 80 e8 17 0c
fd ff <0f> 0b eb fe 8b 77 18 41 58 5b 5d 83 e6 01 f7 de 83 c6 04 e9 6c

Signature · 8 lines
Stephen Smalley
National Security Agency


--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to [email protected] with
the words "unsubscribe selinux" without quotes as the message.
#2 lore raw
Quoted 11 lines · Stephen Smalley
Quoted 7 lines · Russell Coker

Below are the syslog messages from a kernel panic when running 2.6.26. To trigger it I ran "semodule -i sendmail.pp" on a machine with the exim policy loaded (not something that you expect people to do - but not something you expect to cause a problem either) and load_policy went into an infinite loop (100% CPU use - strace reported no syscalls being made). At that stage "kill -9" seemed like the right solution, killing load_policy gave the following result.

Can you make a tarball of your /etc/selinux directory prior to inserting sendmail.pp available somewhere, and a copy of that sendmail.pp file?

Also, if you have it, a copy of the final kernel policy that was triggering the problem when load_policy tried to load it.

Quoted 35 lines
Quoted 35 lines

I've tried to reproduce it but have been unsuccessful. The machine in question is a Xen DomU, I believe that the hardware has ECC RAM and is of generally good quality.

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ... redcape kernel: [399681.381737] Eeek! page_mapcount(page) went negative! (-1)

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381755] page pfn = 3

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381760] page->flags = 400

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381766] page->count = 1

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381770] page->mapping = 0000000000000000

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ...
redcape kernel: [399681.381780] vma->vm_ops = 0x0

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ... redcape kernel: [399681.381799] ------------[ cut here ]------------

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ... redcape kernel: [399681.381811] invalid opcode: 0000 [1] SMP

Message from syslogd@redcape at Tue Oct 28 03:04:31 2008 ... redcape kernel: [399681.381828] Code: 80 e8 3c 0c fd ff 48 8b 85 90 00 00 00 48
85 c0 74 19 48 8b 40 20 48 85 c0 74 10 48 8b 70 58 48 c7 c7 66 52 4b 80 e8 17 0c
fd ff <0f> 0b eb fe 8b 77 18 41 58 5b 5d 83 e6 01 f7 de 83 c6 04 e9 6c

Signature · 8 lines
Stephen Smalley
National Security Agency


--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to [email protected] with
the words "unsubscribe selinux" without quotes as the message.
#3 lore raw
In reply to Stephen Smalley
Quoted 2 lines · Stephen Smalley

Can you make a tarball of your /etc/selinux directory prior to inserting sendmail.pp available somewhere, and a copy of that sendmail.pp file?

Sorry, all I have is an archive after sendmail.pp was loaded. I'll send it to you off-list. Anyone else who wants a copy can request one.

Signature · 9 lines
[email protected]
http://etbe.coker.com.au/          My Blog

http://www.coker.com.au/sponsorship.html Sponsoring Free Software development

--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to [email protected] with
the words "unsubscribe selinux" without quotes as the message.
#4 lore raw
In reply to Russell Coker

I have reproduced the below problem with the DomU in question having SE Linux disabled. The symptom of a process taking maximum CPU time and then killing the system if it was stopped was occurring with Apache and ejabberd processes. I rebooted the DomU about 6 times and had the problem occur each time.

The evidence seems quite clear that it was not a SE Linux problem.

It was suggested that the problem could be related to dodgey RAM, a memtest86+ run for 6 hours did not find any errors. While this is not conclusive evidence of a lack of a problem, it's a strong indication that when a problem is reproducable quickly and easily when running a kernel but not over the course of 6 hours of memtest86+ then it's not faulty RAM.

The DomU in question is now running a CentOS (2.6.18) kernel with no problems.

http://etbe.coker.com.au/2008/10/22/upgrading-a-server-to-64bit-xen/

The machine in question is not entirely a standard configuration. I am running a CentOS 5 kernel with Debian user-space as described in the above blog post.

Quoted 8 lines · Russell Coker

Below are the syslog messages from a kernel panic when running 2.6.26.  To trigger it I ran "semodule -i sendmail.pp" on a machine with the exim policy loaded (not something that you expect people to do - but not something you expect to cause a problem either) and load_policy went into an infinite loop (100% CPU use - strace reported no syscalls being made). At that
stage "kill -9" seemed like the right solution, killing load_policy gave the following result.

Signature · 10 lines
Russell Coker <[email protected]>
http://etbe.coker.com.au/          My Blog
http://etbe.coker.com.au/category/security/  My Security blog posts
http://www.coker.com.au/selinux/play.html  My Play Machine, root PW "SELINUX"


--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to [email protected] with
the words "unsubscribe selinux" without quotes as the message.