Solved

Knoppix 6.2.1 remastering failed several times

Posted on 2010-08-20
18
1,269 Views
Last Modified: 2013-12-15
Hello to everybody,I tried to make the remastering of Knoppix 6.2.1 several times,but right now I've not been able to do it succesfully. Here are the steps I do,please can you check if there is something wrong ? Thanks.

knoppix 2 lang=it (I boot Knoppix 6.2.1 with these parameters)

fdisk -l (these are the partitions of my hard disks)

/dev/sda1 : NTFS (this is the hidden partition did by Windows 7)
/dev/sda2 : NTFS (this is the real partition where is installed win 7)
/dev/sda3 : Linux swap
/dev/sda4 : Linux (I use this partition to make the remastering)
/dev/sdb1 : this is the usb key

These are the commands I give :

mkdir /mnt/sda4/knx

mkdir -p /mnt/sda4/knx/master/KNOPPIX

mkdir -p /mnt/sda4/knx/source/KNOPPIX

cp -Rp /KNOPPIX/* /mnt/sda4/knx/source/KNOPPIX

cp -ar /mnt-system/boot /mnt/sda4/knx/master/boot

cp -ar /mnt-system/KNOPPIX/modules /mnt/sda4/knx/master/KNOPPIX/.

cp /mnt-system/index.html /mnt/sda4/knx/master/

cd /mnt-system && find . -size -10000k -type f -exec cp -p --parents '{}' /mnt/sda4/knx/master/ \;

mount --bind /dev /mnt/sda4/knx/source/KNOPPIX/dev

mount --bind /proc /mnt/sda4/knx/source/KNOPPIX/proc

mount --bind /sys /mnt/sda4/knx/source/KNOPPIX/sys

chroot /mnt/sda4/knx/source/KNOPPIX

mkdir /mnt/sdb1
mount -t auto /dev/sdb1 /mnt/sdb1
cd /mnt/sdb1

cp script /usr/sbin (I need to copy a script inside the squash image file of knoppix)

umount /mnt/sdb1
rm -r sdb1
umount /proc
exit

rm -rf /mnt/sda4/knx/source/KNOPPIX/.rr_moved

mkisofs -R -U -V "K" -publisher "K" -hide-rr-moved -cache-inodes -no-bak -pad /mnt/sda4/knx/source/KNOPPIX | nice -5 /usr/bin/create_compressed_fs - 65536 > /mnt/sda4/knx/master/KNOPPIX/KNOPPIX

cd /mnt/sda4/knx/master

find -type f -not -name sha1sums -not -name boot.cat -not -name isolinux.bin \-exec sha1sum '{}' \; > KNOPPIX/sha1sums

mkisofs -pad -l -r -J -v -V "KNOPPIX" -no-emul-boot -boot-load-size 4 -boot-info-table -b boot/isolinux/isolinux.bin -c boot/isolinux/boot.cat -hide-rr-moved -o /mnt/sda4/knx/knoppix.iso /mnt/sda4/knx/master

At that point I reboot the computer and then I restart the knoppix remastered image with these parameters : knoppix 2 toram lang=it. It tries to load itself inside the memory and then this error occurr :

/init: line 693: /bin/mount : not found
/init: exec: line 742: /sbin/init: not found

I don't understand why. Please help me thanks.
0
Comment
Question by:marietto2008
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 10
  • 8
18 Comments
 
LVL 35

Expert Comment

by:Duncan Roe
ID: 33491108
You will get "not found" from an ELF executable if the run-time loader that it was built to use does not exist. This could be what's happening. Check what is the loader used by /bin/mount on your Knoppix image. Examplke below - run-time (dynamic) loader is /lib/ld_linux.so.2
Verify the loader used by the Knoppix /bin/mount is on the Knoppix CD.
20:36:56$ cat -A /bin/mount|head -1
^?ELF^A^A^A^@^@^@^@^@^@^@^@^@^B^@^C^@^A^@^@^@M-pM-^]^D^H4^@^@^@lM-]^@^@^@^@^@^@4^@ ^@^G^@(^@^Z^@^Y^@^F^@^@^@4^@^@^@4M-^@^D^H4M-^@^D^HM-`^@^@^@M-`^@^@^@^E^@^@^@^D^@^@^@^C^@^@^@^T^A^@^@^TM-^A^D^H^TM-^A^D^H^S^@^@^@^S^@^@^@^D^@^@^@^A^@^@^@^A^@^@^@^@^@^@^@^@M-^@^D^H^@M-^@^D^HM-^DM-V^@^@M-^DM-V^@^@^E^@^@^@^@^P^@^@^A^@^@^@M-^DM-V^@^@M-^Df^E^HM-^Df^E^HM-^P^E^@^@M-l^V^@^@^F^@^@^@^@^P^@^@^B^@^@^@M-^XM-V^@^@M-^Xf^E^HM-^Xf^E^HM-X^@^@^@M-X^@^@^@^F^@^@^@^D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^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^L^@^@^@^@^@^@^@^H^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@$

Open in new window

0
 
LVL 2

Author Comment

by:marietto2008
ID: 33491396
root@MicroKnoppix:/# cat -A /bin/mount|head -1

^?ELF^A^A^A^@^@^@...../lib/ld-linux.so.2....etc
0
 
LVL 35

Expert Comment

by:Duncan Roe
ID: 33491541
That's your mount. What about the one on the mastered CD?
cd into the source tree: cd /mnt/sda4/knx/source/KNOPPIX; cat -A mount|head -1. Make sure the indicated loader is in the tree
0
Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

 
LVL 2

Author Comment

by:marietto2008
ID: 33491666
Before to give your command should I give these commands ?

mount --bind /dev /mnt/sda4/knx/source/KNOPPIX/dev

mount --bind /proc /mnt/sda4/knx/source/KNOPPIX/proc

mount --bind /sys /mnt/sda4/knx/source/KNOPPIX/sys

chroot /mnt/sda4/knx/source/KNOPPIX

if I don't,this is the output :

root@Microknoppix:/# cd /mnt/sda4/knx/source/KNOPPIX; cat -A mount|head -1
cat: mount: no such file or directory
0
 
LVL 2

Author Comment

by:marietto2008
ID: 33491671
I have the same result if I give the commands I told to you.
0
 
LVL 2

Author Comment

by:marietto2008
ID: 33492314
and then what it means ? How Can I fix this error ?
0
 
LVL 35

Accepted Solution

by:
Duncan Roe earned 500 total points
ID: 33493602
Sorry, the command cd /mnt/sda4/knx/source/KNOPPIX; cat -A mount|head -1 was in error - it should have been  cd /mnt/sda4/knx/source/KNOPPIX/bin; cat -A mount|head -1.
mount -bind / chroot is overkill I think. You can just cd to /mnt/sda4/knx/source/KNOPPIX can't you? Then cd to bin and examine mount. But you did that already.
Can you confirm /mnt/sda4/knx/source/KNOPPIX is the loop-mounted iso? That is certainly the right place to be looking. If you have burned the CD / DVD, you could mount that and look there as an alternative.
Having checked that mount loads through /lib/ld-linux.so.2, ensure that file exists on the image and is executable; i.e. check the existence of /mnt/sda4/knx/source/KNOPPIX/lib/ld-linux.so.2 . If that file exists, then you have a different problem.
Recall that I originally posted "This could be what's happening". Maybe you have a different problem altogether. For instance, if the initrd (initial ramdisk image) is still mounted as /, the messages that mount and init don't exist will be perfectly correct. That could indicate a failure of pivot_root to swap root file systems.
0
 
LVL 2

Author Comment

by:marietto2008
ID: 33495150
What I need from Knoppix is that it can be loaded totally in RAM and I can eject the CDROM. Do you know any other kind of linux distro that has the feature I need ?
0
 
LVL 35

Expert Comment

by:Duncan Roe
ID: 33496963
I thought most live CD distributions worked that way - or do you find Knoppix doesn't? Can't you eject it? Otherwise you might want to look at building up from a bare VM to whatever you want, rather than cutting down a very full distribution.
Have you resolved your problem with the remastering process? I would advise to concentrate on that.
0
 
LVL 2

Author Comment

by:marietto2008
ID: 33497271
Most live CD distribution don't leave you eject the cdrom. You can do it anyway,by giving these commands :

$sudo umount -l /cdrom
$sudo eject /mnt/cdrom

but then they stop to working correctly. I'm trying to do a remastering very carefully from the beginning using VMWare doing the checks you said.
0
 
LVL 35

Expert Comment

by:Duncan Roe
ID: 33499549
Sounds good. I read somewhere that if you give root a password, you can use the account and stop having to mess with sudo all the time - hope that's a help.
0
 
LVL 2

Author Comment

by:marietto2008
ID: 33499661
Here is how I tried to make the remastering of Knoppix 6.2.1 on VMWARE :

fdisk -l

disk /dev/sda = 8.5 GB

/dev/sda1 6.3 GB Linux
/dev/sda2 2.2 GB Linux

mkdir /mnt/sda1/knx

mkdir -p /mnt/sda1/knx/master/KNOPPIX

mkdir -p /mnt/sda1/knx/source/KNOPPIX

cp -Rp /KNOPPIX/* /mnt/sda1/knx/source/KNOPPIX

cp -ar /mnt-system/boot /mnt/sda1/knx/master/boot

cp -ar /mnt-system/KNOPPIX/modules /mnt/sda1/knx/master/KNOPPIX/.

cp /mnt-system/index.html /mnt/sda1/knx/master/

cd /mnt-system && find . -size -10000k -type f -exec cp -p --parents '{}' /mnt/sda1/knx/master/ \;

mount --bind /dev /mnt/sda1/knx/source/KNOPPIX/dev

mount --bind /proc /mnt/sda1/knx/source/KNOPPIX/proc

mount --bind /sys /mnt/sda1/knx/source/KNOPPIX/sys

chroot /mnt/sda1/knx/source/KNOPPIX

nano /etc/resolv.conf

nameserver 208.67.222.222
nameserver 208.67.220.220

cd /mnt
mkdir usbkey
mount -t auto /dev/sdc1 /mnt/usbkey
cd /mnt/usbkey
cp script /usr/sbin
 
umount /mnt/usbkey
rm -r usbkey
umount /proc
exit

rm -rf /mnt/sda1/knx/source/KNOPPIX/.rr_moved

mkisofs -R -U -V "Knoppix" -publisher "Knoppix" -hide-rr-moved -cache-inodes -no-bak -pad /mnt/sda1/knx/source/KNOPPIX | nice -5 /usr/bin/create_compressed_fs - 65536 > /mnt/sda1/knx/master/KNOPPIX/KNOPPIX

genisoimage : File '/mnt/sda1/knx/source/KNOPPIX/sys/devices/platform/i8042/serio0/input/input2/id/bustype' did shrink. Files must not be changed while genisoimage runs!

cd /mnt/sda1/knx/source/KNOPPIX/ umount sys

done again the previous step,this time without errors

total translation table size: 0
total rockridge attributes bytes : 9816967
total directory bytes : 28773184
path table size (bytes) : 144346
max brk space used : 4c2f000
969150 extends written (1892 MB)

and then :

cd /mnt/sda1/knx/master
find -type f -not -name sha1sums -not -name boot.cat -not -name isolinux.bin \-exec sha1sum '{}' \; > KNOPPIX/sha1sums

mkisofs -pad -l -r -J -v -V "KNOPPIX" -no-emul-boot -boot-load-size 4 -boot-info-table -b boot/isolinux/isolinux.bin -c boot/isolinux/boot.cat -hide-rr-moved -o /mnt/sda1/knx/knoppix.iso  /mnt/sda1/knx/master

total translation table size : 2048
total rockridge attributes bytes : 3835
total directory bytes : 11356
path table size (bytes) : 70
done with : the files              blocks 368367
writing : ending padblock          start block : 368408
done with : ending padblock        blocks 150
max brk space used 1a000
368558 extends written (719 MB)

booted Knoppix.iso image with VMWare using these parameters :

knoppix 2 toram lang=it ;

error :

insmod : can't open '/mnt-system/KNOPPIX/modules/cloop.ko' : no such file or directory.
0
 
LVL 35

Expert Comment

by:Duncan Roe
ID: 33500457
Looks to me like a failure in the script obeyed in he initrd. Can you check that?
Is the toram argument standard or your addition?
0
 
LVL 2

Author Comment

by:marietto2008
ID: 33500969
Looks to me like a failure in the script obeyed in he initrd,can you check that ? yes,how ?
the toram argument is a standard cheat code. Without it,it boots correctly,I've checked right now.
0
 
LVL 35

Expert Comment

by:Duncan Roe
ID: 33506184
I am downloading Knoppix 6.2 so I can investigate this further.
I can't find cloop in any of my Linux sources - bit of a mystery that.
0
 
LVL 35

Expert Comment

by:Duncan Roe
ID: 33506306
In the meantime, does toram work with Knoppix as received?
0
 
LVL 2

Author Comment

by:marietto2008
ID: 33509073
I found what's the problem : media corrupted. Sometimes Knoppix is not able to read correctly the content of a media and it returns with strange error messages. This is because I've used rewritables cd/rom and after a lot of rewrites they become corrupted. Anyway Knoppix seems to have a very sensible mechanism of hardware detection.
0
 
LVL 2

Author Closing Comment

by:marietto2008
ID: 33515605
We have worked so hard to find the solution and the problem was the media easily corruptible,what a mockery !
0

Featured Post

Don't Cry: How Liquid Web is Ensuring Security

WannaCry is just the start. Read how Liquid Web is protecting itself and its customers against new threats.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Linux users are sometimes dumbfounded by the severe lack of documentation on a topic. Sometimes, the documentation is copious, but other times, you end up with some obscure "it varies depending on your distribution" over and over when searching for …
I. Introduction There's an interesting discussion going on now in an Experts Exchange Group — Attachments with no extension (http://www.experts-exchange.com/discussions/210281/Attachments-with-no-extension.html). This reminded me of questions tha…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses

617 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question