[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Segmentation Fault when using Kernel 2.6
From: |
_cooper_ |
Subject: |
Segmentation Fault when using Kernel 2.6 |
Date: |
Tue, 27 Dec 2005 06:02:01 +0100 (CET) |
Hello,
I have encountered a problem when running Bash 2.05b under various Linux
kernel 2.6. With Kernel 2.4, the problem does not occour.
Due the system was running within VMware, I had to write down the following
informations "bashbug.dynamic" reported by hand:
--- snip ---
Configuration Information [Automatically generated, do not change]:
Machine: i386
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='i386'
-DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='i386-pc-linux-gnu'
-DCONV_VENDOR='pc' -DSHELL -DHAVE_CONFIG_H -I. -I. -I./include -I./lib -g -O2
uname output: Linux (none) 2.6.14.2 #4 PREEMPT Mon Dec 26 06:24:54 CET 2005
i686 unknown
Machine Type: i386-pc-linux-gnu
Bash Version: 2.05b
Patch Level: 0
Release Status: release
--- snap ---
Description:
When running a dynamically linked bash binary under various versions Linux
kernel 2.6 (all plain vanilla), every call to any external programm will
cause a segmentation fault of bash when the external programm ends.
There is no problem doing the same things with the exactly same binary and
Linux kernel 2.4.26, or using a statically linked bash binary with kernel
2.6.
Repeat-By:
This description refers to the bootable CD iso image I built for debugging
purposes for this problem. You can download the 10 MB file at:
http://www.mirko-doelle.de/linux/bash-debug.iso
This file could used as booting ISO for VMware (that's what I did) or,
burned to a normal CD-R/RW using cdrecord, as bootable CD in any computer.
It will do no harm to your harddisks, not even accessing them.
When booting the CD, you can select either the kernel 2.6.14.2 by entering
"26", or the kernel 2.4.26 by entering "24". Under kernel 2.6, you only have
an US keyboard layout, there is no different keymap available. The kernel
2.4 have a built-in German keyboard layout table -- please see
http://www.mirko-doelle.de/linux/keyb_de-us.png
for a comparison between DE and US keyboard layout if you have difficulties
to find the right keys. I apologize to use the German layout, but currently
I'm unable to rebuild the kernel 2.4.26 on my development system with the
US layout.
After booting, you have four virtual consoles for login. The only available
user is "root", his password "linvdr". The login shell is busybox' "sh".
There are three compilations of bash 2.05b below /bin:
bash.static -- runns both with kernel 2.4 and 2.6 without any problems.
I built this bash myself using:
./configure --enable-static-link --enable-lagefile
--host=i386-pc-linux-gnu
bash.dynamic -- causes segfaults after every external programm call with
kernel 2.6, no problems with kernel 2.4. I built this
bash myself using:
./configure --enable-largefile --host=i386-pc-linux-gnu
bash.sarge -- copy from Debian Sarge, without any modifications. Same
problems as bash.dynamic.
For reproducing the problem, you start
/bin/bash.dynamic
after login and then do any external programm call you like. I used
ls ..
for example. Then "ls" (in this case, the busybox replacement) is called,
displays the upper directory and returns.
With kernel 2.4, you can go on using bash as usual -- no problems at all.
But with kernel 2.6, bash exits with a segmentation fault after the external
programm has ended. I tried various kernel versions, 2.6.14.2, 2.6.13.2,
2.6.12, 2.6.9 and 2.6.5. The problem is with all kernel 2.6 versions the
same, segfault after the first external call. Using internal functions like
"set" will cause no problems.
When using "bash.sarge" instead of my homebuild "bash.dynamic", the problem
under kernel 2.6 is the same -- segfault after external call. With kernel
2.4.26, bash.sarge works as intended.
When using "bash.static", which is built of the exactly same sources as
"bash.dynamic", there are no problems whatever kernel you use.
For debugging, there is a 16 MB ramdisk mounted at /mnt/ramdisk, and I have
copied strace to the minimal Linux system. The kernels are capable of using
normal IDE disk drives.
What did I do wrong? Is anything important missing in the mini Linux system?
The problem occoured when I tried to update my rescue system and the install
system of LinVDR to kernel 2.6 and Debian Sarge.
With best regards, and have nice holidays,
Mirko
______________________________________________________________________________
LinVDR - The Digital Linux Videorecorder http://linvdr.org
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Segmentation Fault when using Kernel 2.6,
_cooper_ <=