Bug#131709: [rjohnson@dogstar-interactive.com: Re: Bug#131709: chroot segfaults]
- Forwarded message from Rich Johnson [EMAIL PROTECTED] - X-Virus-Scanner: McAfee Virus Engine X-Spam-Status: Scanner Called X-Sent: 2 Feb 2002 15:14:43 GMT From: Rich Johnson [EMAIL PROTECTED] To: Ben Collins [EMAIL PROTECTED] Subject: Re: Bug#131709: chroot segfaults X-Spam-Status: No, hits=0.0 required=6.5 tests= version=2.1 Rich Johnson wrote: I poked around a bit more. I've distilled some of the results below/ The machine state is the result of: 1) booted from floppies (mac_hfs_boot, root.bin) 2) downloaded kernel drivers from ftp.us.debian.org 3) downloaded base .debs from ftp.us.debian.org 4) extracted base .debs from ftp.us.debian.org 5) installation of base .debs failed with Failure trying to run : chroot /target dpkg Ben-- I did still more digging--i.e. lots of reboots and manual invocations of debootstrap . Here's a report to pass on to the appropriate folks--perhaps it's a dpkg or debootstrap issue? a) chroot runs fine intslling the first few dpkg's b) chroot start's failing with repeat 5 dpkg $(debfor $required) c) the system would also hang--such that ctl-C does't work; sometimes even ctl-alt-del didn't work. d) fsck after a forced reboot invariably showed several cross-linked files--almost always in /usr/share/zoneinfo. This indicates that the 3000 or so files indicated by $(debfor required) overstresses dpkg. Hanging also indicates falling into an infinite loop somewhere; perhaps a corrupted linked list or hash table? I was able to install all the packages by rewriting install_subs() to unwind the installation such that dpkg was invoked on a _single_ packages at a time. Experience with cross-linked files also caused me to defensively put a sync after every dpkg. The modified script ran to completion. This supports the hypothesis of an overstressed dpkg. I replaced the two repeat 5 lines with loops. Running each loop once left nothing more to do. The repeat seemed superfluous, but I may be missing some subtleties . Here's the modified fragment (sorry, no diff's yet--I'm still configuring the system): ...snip... for rdeb in ${required}; do in_target dpkg --force-depends --unpack $(debfor $rdeb) sync sleep 3; #--throttle to give time to scan results. done ...snip... for bdeb in ${base}; do in_target dpkg --force-auto-select --force-overwrite --force-confold --skip-same-version --install $(debfor $bdeb) sync sleep 3#--throttle to give time to scan results. done in_target dpkg --configure --pending --force-config-any --force-depends #--walk through That's all for now...on to XBoot and finishing my configuration --rich - End forwarded message - -- .--===-=-==-=---==-=-. / Ben Collins--Debian GNU/Linux--WatchGuard.com \ ` [EMAIL PROTECTED] -- [EMAIL PROTECTED] ' `---=--===-=-=-=-===-==---=--=---' -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#131709: chroot segfaults
package: boot-floppies version: 3.0.18 architecture: powerpc model: Mac 8500 /132 (old world firmware) memory: 32M scsi: on-board cd-rom:apple, scsi interface Manually invoking root.bin's /usr/sbin/chroot /target cmd from the installer's shell always segfaults. Perhaps this explains the Failure trying to run : chroot /target dpkg encountered while installing the base system. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#131709: chroot segfaults
On Thu, Jan 31, 2002 at 10:09:13AM -0500, Rich Johnson wrote: package: boot-floppies version: 3.0.18 architecture: powerpc model: Mac 8500 /132 (old world firmware) memory: 32M scsi: on-board cd-rom:apple, scsi interface Manually invoking root.bin's /usr/sbin/chroot /target cmd from the installer's shell always segfaults. Perhaps this explains the Failure trying to run : chroot /target dpkg encountered while installing the base system. Does it segv before or after it chroots? It may be that cmd that it is trying to execute is segv'ing, and that would be an important bit of information. Ben -- .--===-=-==-=---==-=-. / Ben Collins--Debian GNU/Linux--WatchGuard.com \ ` [EMAIL PROTECTED] -- [EMAIL PROTECTED] ' `---=--===-=-=-=-===-==---=--=---' -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#131709: chroot segfaults
summary of thread: On Thu, Jan 31, 2002 at 10:09:13AM -0500, Rich Johnson wrote: package: boot-floppies version: 3.0.18 architecture: powerpc model: Mac 8500 /132 (old world firmware) memory: 32M scsi: on-board cd-rom:apple, scsi interface Manually invoking root.bin's /usr/sbin/chroot /target cmd from the installer's shell always segfaults. Perhaps this explains the Failure trying to run : chroot /target dpkg encountered while installing the base system. Does it segv before or after it chroots? It may be that cmd that it is trying to execute is segv'ing, and that would be an important bit of information. reply 1(rich): I poked around a bit more. I've distilled some of the results below/ The machine state is the result of: 1) booted from floppies (mac_hfs_boot, root.bin) 2) downloaded kernel drivers from ftp.us.debian.org 3) downloaded base .debs from ftp.us.debian.org 4) extracted base .debs from ftp.us.debian.org 5) installation of base .debs failed with Failure trying to run : chroot /target dpkg command result -+ /usr/sbin/chroot / sh works. /usr/sbin/chroot /target sh /usr/sbin/chroot /target /usr/bin/dpkg segfault /target/usr/bin/dpkgprints a usage message /usr/sbin/chroot /target /bin/bash segfault /target/bin/bash error loading shared libraries ...libncurses.so.5 note: /target/lib/libncurses.so.5 exists /lib/libncurses.so.5 does not #...but, if /target/lib/libncurses.so.5 is coped to /lib: /target/bin/bash segfault !! Hmmm, It's just a guess, but perhaps the problem lies somewhere in the truncated shared libraries? Maybe a version skew? reply 2(ben): Try copying /bin/sh to /target/bin/bf-sh and do: /usr/sbin/chroot /target /target/bin/bf-sh I don't think this is a truncated libc problem, because the libc in the chroot is not truncated. reply 3(rich): cp /bin/sh /target/bin/bf-sh /usr/sbin/chroot /target /bin/bf-sh # segfault Maybe truncated wasn't the right word. But, I get these results from ls -l: size date path --+--+-- 753604 Dec 20 /lib/libc2.2.4.so 753604 Dec 20 /lib/libc.so.6 1291932 Dec 5 /target/lib/libc2.2.4.so 1291932 Dec 5 /target/lib/libc2.2.4.so.dpkg-tmp 22 Jan 30 /target/lib/libc.so.6 - /target/lib/libc2.2.4.so.dpkg-tmp reply 4(ben): I have a feeling that ppc ld.so or libc is broken. Could be wrong, but try emailing the debian-ppc list to see what they say. Yes, the libc on the boot disks is stripped down. But I assume the segv is occuring in /target, not in chroot. Try doing this: /target/usr/sbin/chroot /target /bin/sh reply 5(rich) /target/usr/sbin/chroot /target /bin/sh Another segfault; alas. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]