I just updated to hardened sources 2.6.21-r1 (from 2.6.21) emerge hardened-sources cd /usr/src rm linux ln -sf linux-2.6.21-hardened-r1 linux cd linux zcat /proc/config.gz > .config make oldconfig make mount /boot make install modules_install umount /boot then i updated my modules, which are virtualbox and kqemu (which i havent loaded for a long time) and loop-aes. After that i wanted to reboot the machine. Entering "reboot" ends in a segfault, the logfiles say: May 19 15:35:44 chris shutdown[7667]: shutting down for system reboot May 19 15:35:47 chris BUG: unable to handle kernel paging request at virtual address 80000004 May 19 15:35:47 chris printing eip: May 19 15:35:47 chris 002f5408 May 19 15:35:47 chris *pgd = 15492001 May 19 15:35:47 chris *pmd = 0 May 19 15:35:47 chris Oops: 0000 [#4] May 19 15:35:47 chris Modules linked in: loop May 19 15:35:47 chris CPU: 0 May 19 15:35:47 chris EIP: 0060:[<002f5408>] Not tainted VLI May 19 15:35:47 chris EFLAGS: 00210086 (2.6.21-hardened #3) May 19 15:35:47 chris eax: 80000000 ebx: f7f4cb21 ecx: 00200282 edx: ec4eb7c0 May 19 15:35:47 chris esi: f7f4ca01 edi: f7f4ca01 ebp: ec4eb7c0 esp: c8445d10 May 19 15:35:47 chris ds: 0068 es: 0068 fs: 00d8 gs: 0033 ss: 0068 May 19 15:35:47 chris Process shutdown (pid: 7667, ti=c8444000 task=d561b540 task.ti=c8444000) May 19 15:35:47 chris Stack: 000000ff 00000002 000000ff 002f56c2 c8445d44 00000000 00000008 009c0300 May 19 15:35:47 chris c33e54dc f7e94e80 00000000 00000001 ec4eb840 00000000 00000002 000000ff May 19 15:35:47 chris ec4eb7c0 f799102c 000f27af 0000000e 00000000 00200002 0003559a 00000002 May 19 15:35:47 chris Call Trace: May 19 15:35:47 chris [<002f56c2>] <0> ======================= May 19 15:35:47 chris Code: 01 00 00 00 ba 01 00 00 00 c7 04 24 00 00 00 00 e8 ca e4 d1 ff 58 5b 5e c3 56 89 c6 53 89 cb 83 ec 04 9c 59 fa 8b 03 85 c0 74 0d <8b> 40 04 89 42 04 8b 03 89 50 04 eb 03 89 52 04 89 13 51 9d 8d May 19 15:35:47 chris EIP: [<002f5408>] SS:ESP 0068:c8445d10 I tried to unload the modules, therefore ran swapoff -a, losetup -r (or whatever remove is) /dev/loop7 and losetup -a, but they do not terminate. They use no cpu power (not visible in top), but the load is rising. It is at 4, at the moment (1 cpu core) but does not make the computer less responding. free shows no swap, so swapoff -a seems toi have succeded. strace -p <pid of one of the processes> shows nothing. Any idea, what this could be and how to fix it?
No clue actually, could you upload your config please ?
Created attachment 119729 [details] .config used for hardened-sources-2.6.21
Actually.... i would try to reset the computer and hope, that it will not happen again. The main purpose of this is to document it and to ask, if there is anything i should provide from the running system before rebooting.
can you post your System.map and a decoded oops please?
I have a System.map but i did only get error messages when trying to create the decoded oops. It seems, i did not have debug symbols or stuff like that in my kernel. I rebootet the machine today and everything seems to work, reboot does not segfault anymore. I hope this was only due to strange updating practices and that it is not reproducible. Therefore i will close the bug for now. Sorry for the bugspam, i should have tried to reproduce it before.
(In reply to comment #5) > I have a System.map but i did only get error messages when trying to create the > decoded oops. It seems, i did not have debug symbols or stuff like that in my > kernel. I rebootet the machine today and everything seems to work, reboot does > not segfault anymore. you could still post (or just mail me) the corresponding System.map as i can decode the oops by hand and maybe learn something about the cause.
Created attachment 119875 [details] System.map Sorry, i thought somehow the kernel binary was needed for the decoding and i missed some debuging stuff for it. Thanks for your effort. If you need anything else, just ask.
(In reply to comment #7) > Sorry, i thought somehow the kernel binary was needed for the decoding and i > missed some debuging stuff for it. Thanks for your effort. If you need anything > else, just ask. thanks, it was the loop module that caused the oops (that's why losetup et al. hung later as well), so i'd like to see your loop.ko if you still have it or can reproduce it. do you know if -hardened patches the loop code in any way?
Created attachment 119897 [details] loop.ko (loop-aes-3.1e) As i mentioned in the first comment, i use loop-aes as an external module for encrypted swap. Therefore the loop.ko is not the module hardened sources would have generated. Installed versions: 3.1e(16:05:38 05/19/07)(kernel_linux keyscrub padlock)
(In reply to comment #9) > Installed versions: 3.1e(16:05:38 05/19/07)(kernel_linux keyscrub > padlock) so, the code crashed in the loop_add_queue_last function on some invalid 'q' pointer. then i also noted that 3.1e doesn't even have a kernel patch for 2.6.21 whereas 3.2a does so i'm wondering if your setup is supported at all or you'd really have to update to 3.2a first...
This check should be a feature of the package manager, i would say. I ran a ~x86 kernel with a x86 kernel module, but there should be a check for that, i think. At the moment i am running the combination 2.6.21 with 3.1e again, no problems so far. Swapoff -a works. Reboot works. But i'll upgrade to 3.2a, thanks a lot for your help. Should i change the bug that the title asks for this version check in the kernel module and then reopen it?
(In reply to comment #11) > Should i change the bug that the title asks for this version check in the > kernel module and then reopen it? no idea, it's not my call really, better ask the gentoo package maintainer of loop-aes, or even Jari Ruusu about what is and isn't supported.