-
Segmentation Fault on chroot source/KNOPPIX
I am trying to remaster knoppix following the Remastering HowTo. I keep hitting segmentation faults when it comes to the chroot. I have a dual P2-300 machine with a serial console on ttyS1 hooked up, .5Gb RAM, and 3ware IDE raid card with an 240Gb RAID5 array. I'm just trying to make a simple file-server based off knoppix, but I can't even get started. Here's what I do:
boot knoppix.
edit /etc/inittab and enable T1
edit /etc/securetty and change ttyS0 to ttyS1
give root a password
kill -HUP 1
login via serial console
mount -rw /dev/sda2 /mnt/sda2
mkdir /mnt/sda2/knx
Run the following script:
----------------------------------------------------------------------------
#!/bin/sh
MASTER=/mnt/sda2/knx/master
SOURCE=/mnt/sda2/knx/source
CDROM=/cdrom
ISO=/mnt/sda2/knx/knoppix.iso
echo "MASTER is $MASTER"
echo "SOURCE is $SOURCE"
echo "CDROM is $CDROM"
echo "ISO is $ISO"
echo "# rm -rf $MASTER"
rm -rf $MASTER
echo "# rm -rf $SOURCE"
rm -rf $SOURCE
echo "# mkdir $MASTER"
mkdir $MASTER
echo "# mkdir $SOURCE"
mkdir $SOURCE
echo "# mkdir $SOURCE/KNOPPIX"
mkdir $SOURCE/KNOPPIX
echo "# cp -Rp /KNOPPIX/* $SOURCE/KNOPPIX"
cp -Rp /KNOPPIX/* $SOURCE/KNOPPIX
echo "# mkdir $MASTER/KNOPPIX"
mkdir $MASTER/KNOPPIX
echo "# cp $CDROM/index.html $MASTER"
cp $CDROM/index.html $MASTER
echo "# cd $CDROM/KNOPPIX"
cd $CDROM/KNOPPIX
echo "find . -size -10000k -type f -exec cp -p --parents {} $MASTER/KNOPPIX/ \;"
find . -size -10000k -type f -exec cp -p --parents {} $MASTER/KNOPPIX/ \;
echo ""
echo "Done"
---------------------------------------------------------------------
After it completes I try to chroot to /mnt/sda2/knx/souce/KNOPPIX but I always get a segmentation fault. I did 'strace chroot ...' to see if I could figure out what the problem was, but I couldn't seem to make any headway. Here's the tail of the strace if someone can make heads or tails of it:
<snip>
open("/dev/tty", O_RDWR|O_NONBLOCK|O_LARGEFILE) = 3
close(3) = 0
brk(0) = 0x80e5a74
brk(0) = 0x80e5a74
brk(0x80e6000) = 0x80e6000
brk(0) = 0x80e6000
brk(0x80e7000) = 0x80e7000
getuid32() = 0
getgid32() = 0
geteuid32() = 0
getegid32() = 0
rt_sigprocmask(SIG_BLOCK, NULL, [], = 0
time(NULL) = 1080649153
brk(0) = 0x80e7000
brk(0x80e8000) = 0x80e8000
brk(0) = 0x80e8000
brk(0x80e9000) = 0x80e9000
open("/etc/mtab", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=237, ...}) = 0
old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40018000
read(3, "/dev/hda6 / ext2 rw,errors=remou"..., 4096) = 237
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV +++
root@ttyS1[knx]#
I am not sure where its getting /dev/hda6. /dev/hda is my cdrom. /dev/sda is the raid array. Here's how they come up in dmesg:
hda: MATSHITA CR-583, ATAPI CD/DVD-ROM drive
ide-cd: passing drive hda to ide-scsi emulation.
Attached scsi disk sda at scsi2, channel 0, id 0, lun 0
SCSI device sda: 468898176 512-byte hdwr sectors (240076 MB)
sda: sda1 sda2
I tried doing the chroot on tty0, but I still got the segmentation fault. I tried rebooting, reformating the raid-array, but every time I get the segmentation fault. HELP!!!!!!
thx,
britt
-
md5sum changes with each run.
I am thinking this may be hardware issue, b/c I am seeing something else very strange. I thought that maybe knoppix was having a hard time with the size of the parition, so blew that one away, and created a small 5Gb partition as part of the raid array. I was able to successfully chroot. So I did my customiziations, and created a new knoppix iso. I then ran an md5sum on the iso file. Funny thing I noticed, is that each time I run it on the .iso file, it changes!!! So I thought maybe I had bad CD-ROM or faulty ram. But I ran memtest86 and swapped out CD-ROMs, and I still see the same thing. I even went back to an older version of knoppix and I still see the problem.
So the only thing left to question is the raid array. Has anyone else seen this type issue where md5sum keeps changing?
-
Try doing that directly on the file server. Don't access it via the serial console.
- Ambrose
Similar Threads
-
By tr in forum Customising & Remastering
Replies: 1
Last Post: 07-23-2005, 09:29 AM
-
By bluestick in forum Customising & Remastering
Replies: 0
Last Post: 03-29-2005, 02:33 PM
-
By bluestick in forum General Support
Replies: 0
Last Post: 03-29-2005, 11:09 AM
-
By alexl in forum Customising & Remastering
Replies: 0
Last Post: 09-17-2004, 02:36 PM
-
By nob in forum General Support
Replies: 3
Last Post: 05-09-2004, 06:41 AM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
Vintage 5362 IBM System/36 Mini-Computer Mainframe 5291 2, CRT Terminal DM12N501
$249.99
IBM Type 4869 External 5 1/4in Floppy Disk Drive Mainframe Collection - UNTESTED
$65.00
6 Vintage Computer Tape Reels mainframe 3200 5000 data ibm magnetic processor
$99.00
IBM Type 4869 External 5 1/4in Floppy Disk Drive Mainframe Collection
$145.99
Cray Research Supercomputer Cray X-MP ECL Logic Board
$149.99
VINTAGE IBM Type 4869 External 5 1/4" ~ Floppy Disk Drive Mainframe ~
$159.99
2 - VINTAGE MAINFRAME Fortran Format Punch Cards - IBM 80 columns
$3.49
Digital DEC LK201BA Terminal Keyboard RJ11 Connection Mainframe
$44.95
Commodore Amiga 500 Computer w/Mouse and Amiga A520 RF Modulator As Is Untested
$299.99
Xargon 1 Beyond Reality RARE Game Floppy 3.5” Floppy Mainframe Collection
$349.99