Mini DSL Remastering HowTo


Forum: Other Help Topics
Topic: Mini DSL Remastering HowTo
started by: Del

Posted by Del on Feb. 29 2004,05:51
Quick DSL Remastering Howto.

This is completely untested with the new 0.6.x series. I know it worked with
0.5.3. I offer no promises that this will work as desired/expected,
nor do I take any responsibility for any damage it may or may not cause
to you, your computer, your relationships, your cat, etc... In other words,
use this at your own risk. This howto is not endorsed by John, or any other
person who directly has anything to do with Damn Small Linux. It's just a
compilation of techniques gathered from the web by one DSL pseudo-user who
has enough computers and backups to not really care if any data is lost. It
is assumed that you already have some idea what you are doing. If that is not
true, please stop now and read some more forum posts and play with the default
DSL for a few weeks, then come back and try again.

First thing's first, you need 300+ Mb of free space on an existing ext2
partition. To do it right, I'd suggest no less than one Gb of free, formatted
ext2 space. For the remainder of this howto it will be assumed you have a
dedicated partition for remastering DSL located at /dev/hda1 (the first
partition of the first hard disk). You must be root to accomplish this project,
'sudo su' at a command prompt will suffice.

This has been tested on a machine with 256Mb of physical RAM, and about 500Mb
of swap space. I'd suggest having at least 128Mb physical RAM with an equal
amount of swap.

#mount /mnt/hda1
#cp -Rp  /KNOPPIX    /mnt/hda1/
#mount --bind /dev /mnt/hda1/KNOPPIX/dev
#chroot /mnt/hda1/KNOPPIX
#mount -t proc /proc proc
(do whatever it is you did to get your internet connection up and running on the LiveCD)
#dpkg-restore
#vi /etc/apt/sources.list
(change to testing branch)

-- add/remove packages, etc... --

#umount /proc
#ctrl-d
(press Ctrl and 'D' together, to un-chroot)

Make a new directory on /dev/hda1 called NewCD. Copy everything from the DSL CD
to this directory, _except_ for the KNOPPIX compressed image (since this is the
file we'll be replacing with the custom DSL remaster).

Create the compressed image file (your own custom KNOPPIX)

#mkisofs -R /mnt/hda1/KNOPPIX | create_compressed_fs - 65536 > /mnt/hda1/NewCD/KNOPPIX/KNOPPIX  

Now it's time to create the CD image

#cd /mnt/hda1

#mkisofs -r -J -b KNOPPIX/boot.img -c KNOPPIX/boot.cat -o my_custom_DSL.iso NewCd

That's it! You've just whipped up your own custom Linux distribution, with a little
(okay, a lot of) help from other people :) You can now burn this .iso image to a CD
and have a bootable LiveCD of your very own. Of course, if you want to test your
image first (that's probably a good idea) read on...

For testing, you must have a floppy drive for your computer to boot from. Make a boot
floppy from the boot.img you just used in your .iso.

#dd if=/mnt/hda1/KNOPPIX/boot.img of=/dev/fd0

This boot floppy will look for a KNOPPIX file in a /KNOPPIX partition on any partition
when booting up. Since we created a KNOPPIX compressed image in /dev/hda1/KNOPPIX/, that
will do just fine. Stick the floppy in the drive, and reboot the PC, taking care to remove
the Damn Small CD from the cdrom (so it'll boot from the floppy, not the cd).

If it boots up to your customized version of DSL, well, then things worked. If it doesn't,
reread this howto, make sure you're using a version of DSL that it's known to work with
(that'd be 0.5.3), and try again. If it still doesn't work, spit, stomp your feet, and
curse Del who is sitting back and saying "Well, it worked for me.".

Posted by libretto on Feb. 29 2004,20:33
Havent had a go yet, but it seems just what is needed, cheers! Better find some blank CDs under all these old DSL disks ;)
Posted by Rapidweather on Mar. 01 2004,04:34
I've saved this howto as a file, and I can later bring it up in Scite. Eventually, I'm going to get everything together to try it. I have also the .install_synaptic script, and have run it once, and it works fine. I'm wondering if that could be used in the
remastering procedure, (since it does work great), and as long as we keep the box running we can add more stuff. If all of it works, then the thing could be remastered. (No limit of 50 MB for me.)
Here's another thought. Could the /Knoppix folder that is under development, via
the process of adding and testing applications just be saved in another partition?
I have a big Redhat 9 partition to store it in, but I have found that /dev/hda1 (Windows) is where /knoppix needs to be for the boot floppy to find and run it.
I do that now, with the original DSL /knoppix, off the cd. I copy it to /dev/hda1.
Then, I restore with a 10 MB tarball, in another partition, at /dev/hdb1.
Temporarily keeping the /Knoppix folder that's under development would allow me to shut down the machine, and come back later, put the /knoppix folder back where it can be located, and go at it again. Eventually, I would need to
create a remastered cd, of course (to keep with the program), but would I
if I am doing it this way. As I add programs using Synaptic, will my /knoppix folder follow along? I'm thinking that all the additions are in /ramdisk, not /knoppix, so somehow that might have to be saved as a restorable folder.
-----
Just some thoughts on the possibilities...
-----

???

Posted by Del on Mar. 02 2004,04:27
Sorry Rapid, I'm feeling pretty lousy (cold, flu, something...) so I'm gonna come back and reread your post tomorrow when my head's on (more?) straight.

Right off the bat though, it doesn't really matter what partition you actually use. I've done this on a machine with only one partition (hda1) that had DSL hdinstall-ed to it, and just stored the other stuff in /mnt/hda1/KNOPPIX and /mnt/hda1/NewCD. Overall, this really isn't that picky as to where info is stored, as long as it's on an ext2 partition (I've had create_compressed_fs complain when the new filesystem was ext3).

Posted by charpie on Mar. 02 2004,04:31
I tried it twice and well everything works fine to create the KNOPPIX file. I did not create the iso. I did try to boot using a disk dd floppy of dsl 6.1 to boot the knoppix file on my partition..it work great except for one little thing : my mouse does not work at all. It is an optical usb mouse. Normally it works fine booting on the original KNOPPIX file which i have extracted from the original iso. Somehow the remaster creates a KNOPPIX file that does not recognize my mouse.

Also I can't apt-get synaptic, however i did install mozilla with no problem.

Anyone can help!!

My aim was to try to remaster it to produce a cd with firefox and thunderbird already insatll and ready to go from a minidisk. Then i would save my config on a usbdrive using rapidweather genaral howto!

I am new in linux and i find it a bit difficult to progress and understand how things works. So far i got the menu, the xinit and the icon. I cannot figure out how to have the icon on at boot up?

Any help is appreciated! Cheers.
NOSPAMdjig2000@hotmail.com

Posted by Rapidweather on Mar. 03 2004,13:46
I tried it, and decided to do a test without adding any applications just yet, to get
the feel for the remastering process. I am using 0.6.1
I burned the cd from the resulting custom iso, and it does not fully boot. Here is
what I get:
---
Accessing Knoppix cdrom at /dev/scd0 .../modules/cloop.o: init_module:
Hint: insmod errors can be caused by incorrect module parameters, including
invalid IO or IRQ parameters.
Can't find Knoppix filesystem, sorry. Dropping you to a (very limited) shell.
Press reset buton to quit.
Additional builtin commands available:
cat          mount       umount
insmod    rmmod     lsmod
Knoppix# (blinking cursor)
---
I also notice that the size is a few K short of the original 0.6.1 iso,
and when the cd is opened in Windows, it shows Cdrom instead of
Knoppix.  It will autorun, and open Internet Explorer with the message to
boot from the cdrom, etc. I do note that 0.6.1 will open 4 of these windows,
instead of just one, and so will this remaster.
I did the entire remastering process on a restored DSL 0.6.1, with Foxfire,
and wvdial, that I added. I had hoped to get them in the remaster, but apparently not, due to the size not being greater than the original, and in fact
a few K short.
I get no error messages during the remastering process, and everything is in
the right place, etc.
I'll have to look all this over again, and see what I can try next to get a working cd from the remastering process. Not sure where to begin, however.
---
I could follow the suggestion to do this on 0.5.3.1 instead of 0.6.1, and see
if that makes any difference.
---
 
 ???

Posted by Rapidweather on Mar. 05 2004,00:05
I'm still trying to get it to work with 0.6.1. Made lots of progress, but as they say, "close, but no cigar".
I did get one to wind up as "kernel panic", which is better than the one that could not even find "knoppix".
As long as Office Depot has a good supply of Maxell CD-R's, and I don't run out of $$, then I'll keep at it. Last one I did was about 57 mb, and had Foxfire and wvdial, just wouldn't boot.
---
:D

Posted by Rapidweather on Mar. 06 2004,00:01
Remastering 0.6.1:
-----
I have gone to testing without burning to cd, it's cheaper.
I got one /mnt/hdb1/NewCD/KNOPPIX made that fully boots, with no
unusual error messages, and has Foxfire and wvdial in it.
Problems are:
l. rxvt won't open, just flashes on the screen, and the console says:
rxvt: can't open pseudo-tty.
I can use the command line in emelfm, and use that to open Foxfire.
When I try and connect with wvdial, it has permission problems, and
disconnects after connecting.
I had also copied my entire /home/damnsmall directory into the NewCD, and
hoped for a restoration of my desktop wallpaper, menu, etc. (using emelfm)
That didn't happen.
---
So, I am still at it, may now try to remaster 0.5.3.1.
---
I reboot the machine into Redhat 9, and just rename my knoppix folders in
/dev/hda1, so I can flip back and forth between a working one, and the remastered, testing one.
---


:D

Posted by charpie on Mar. 07 2004,17:29
http://www.knoppix.net/docs/index.php/KnoppixRemasteringHowto

Have alook here. It seems to be more complete. Also this forum seems good as well:
Forum: DSL Ideas and Suggestions
Topic: DSL Remastering HOWto, Fairly definitive.
started by: Philly

I have yet to try it with 6.1

I will keep you posted on success! If any. Cheers ???

Posted by KriS on Mar. 12 2004,12:44
HI,

I've tried to remaster DSL 0.6.1 without any success...
But with 0.5.3.1 I was able to remaster it.

But there is one problem....
While my remastered DSL is booting from CD, I get an error:
"/etc/rcS.d/S00knoppix-autoconfig: line 355: /etc/sysconfig/desktop: Read-Only Filesystem"

Now I didn't really change anything, I just wanted to "test" the remastering...

So where would I have to change or search for the error?
Thx in adv.

So long
KriS

Posted by KriS on Mar. 12 2004,13:43
Hi again,

ok I solved that problem...
my misstake...
never try to remater while your still in an Xsession :)

The error is now gone...
But on the remastered CD X still wont start on boot...
Any ideas?

So long
KriS

Posted by Bryce on Mar. 24 2004,08:34
Quote (Rapidweather @ Mar. 05 2004,19:01)
Remastering 0.6.1:
-----
I have gone to testing without burning to cd, it's cheaper.
Problems are:
l. rxvt won't open, just flashes on the screen, and the console says:
rxvt: can't open pseudo-tty.
I can use the command line in emelfm, and use that to open Foxfire.

I get essentially the same results.  On the remastered DSL 0.6.2 CD everything works, except that any type of console based application results in "rxvt: can't open pseudo-tty".  Anyone solved this? :(
Posted by Bryce Nesbitt on Mar. 25 2004,08:43
I found the error in the instructions lead to the tty not opening (you need to unmount /dev).  A complete set of instructions to remaster Damn Small Linux (DSL) is:

-----------------------------------------------------------------
For the remainder of this howto it will be assumed you have a dedicated partition for remastering DSL located at /dev/hda1 (the first partition of the first hard disk). You must be root to accomplish this project, 'sudo su' at a command prompt will suffice.

You may need a lot of ram and/or hard disk space to make this work.

#mount /mnt/hda1
#cp -Rp  /KNOPPIX    /mnt/hda1/
#mount --bind /dev /mnt/hda1/KNOPPIX/dev
#chroot /mnt/hda1/KNOPPIX
#mount -t proc /proc proc
(do whatever it is you did to get your internet connection up and running on the LiveCD)
#dpkg-restore
#vi /etc/apt/sources.list
(change to testing branch)

-- add/remove packages, etc... --
#apt-get install mozilla-browser
#dpkg --purge emelfn
#dkpg --purge gimp1.2-print

#umount /proc
#ctrl-d
(press Ctrl and 'D' together, to un-chroot)
#umount /mnt/hda1/KNOPPIX/dev

Make a new directory on /dev/hda1 called NewCD. Copy everything from the DSL CD to this directory, _except_ for the KNOPPIX compressed image (since this is the file we'll be replacing with the custom DSL remaster).

Create the compressed image file (your own custom KNOPPIX)

#mkisofs -R /mnt/hda1/KNOPPIX | create_compressed_fs - 65536 > /mnt/hda1/NewCD/KNOPPIX/KNOPPIX  

Now it's time to create the CD image

#cd /mnt/hda1

#mkisofs -r -J -b KNOPPIX/boot.img -c KNOPPIX/boot.cat -o my_custom_DSL.iso NewCd

That's it! You've just whipped up your own custom Linux distribution, with a little (okay, a lot of) help from other people :) You can now burn this .iso image to a CD and have a bootable LiveCD of your very own.

Now if only someone can get the Java plugin for Mozilla or Firefox to work.... (I can't get the Java map at < http://www.nextbus.com > to funcion)

Posted by firefly2442 on Mar. 25 2004,20:25
Anybody tried Linux Live?

< http://www.linux-live.org/ >

Just wondering if that would work too. :)

Posted by Rapidweather on Mar. 26 2004,02:37
Bryce,
I have posted your mini-howto in my
< http://www.angelfire.com/ms/telegram/general_howto >
Since the items in that are in chronological order,
it's at the end (bottom).
----
I had gotten a remaster done, with wvdial added only, and I booted it
from floppy, but no xterminal could be brought up without crashing
immediately, and also, wvdial could be run out of emelfm, but did not
want to stay connected.
---
The rxvt error said:
rxvt: can't open pseudo-tty.
---
You may have, as you say, found the error, and I'll get back to testing
the remaster procedure, and see if I can get going. I do run the remaster
procedure in an X session, in Damn Small, so I can have the instructions on
one desktop, and my actual working rxvt's on another. As I said, I got close,
but no cigar.
---
Thanks for your fine detective work.
---
  :D

Posted by Rapidweather on Mar. 27 2004,06:40
Ok, I got it remastered.
Now, DSL 0.6.2 has Foxfire and wvdial included in the remaster.
Only problem is that my local settings are not included, such as my menu
in /home/damnsmall/.fluxbox/menu, and my .xinitrc.
I am posting from this remaster now, using Foxfire and wvdial.
It's not been burned as yet, I am booting from a floppy, and it finds
the /knoppix folder in /dev/hda1.
I copied the /mnt/hdb1/NewCD/KNOPPIX to /mnt/hda1 so the floppy would
locate it.
I used emelfm in X to do all of the file copy for the remastering process, which
makes it easy. I'll do another one tomorrow, and solve the local settings problem.
This remaster just comes up with the default desktop, menu and message in dillo.
I have my own message that I use, and set that in .xinitrc, and my experience with 0.6.2
has been that after a restore, from the boot prompt, my own
message, menu and wallpaper come right up after the usual xserver/mouse/resolution choices.
I am on the right track, and this remaster has 58 MB of Penguin Power.
---

:;):

Posted by brycen on Mar. 27 2004,07:34
The next frontier is installing browser plug-ins!  It is not as easy as you might think.  I have not solved it .
Posted by Rapidweather on Mar. 27 2004,15:31
I have Foxfire in my remaster, so I entered "about:plugins" in the url box and
it seems that I have this:
---
Shockwave Flash

   File name: libflashplayer.so
   Shockwave Flash 6.0 r81

MIME Type Description Suffixes Enabled
application/x-shockwave-flash Shockwave Flash swf Yes
application/futuresplash FutureSplash Player spl Yes
---
I have not bothered to get some extensions yet, that might be where I will have
a problem.
---
To get this remaster up and running, I cut /opt/foxfire from the filetool.lst,
and made a backup.tar.gz (now much smaller, about 750K vs 16 mb before),
and restore the local settings (menu, wallpaper, etc.) from that at the boot
prompt. I decided that remastering everything in /home/damnsmall might
not be needed, so I'll cook up a new remaster that is designed to go with a
backup.tar.gz for those items.
---
More on this later. I have not burned it yet, still in the testing phase.
---
:;):

Posted by Rapidweather on Mar. 27 2004,23:59
More details on my remaster: I left everything in DSL 0.6.2, and added Firefox and wvdial.
I now have it burned to cd, and run off that.
My backup.tar.gz is only 509.38 kb, and here is the filetool.lst to go with that:
--------
/home/damnsmall/.fluxbox
/home/damnsmall/.xtdesktop
/home/damnsmall/.xinitrc
/home/damnsmall/.blackboxrc
/home/damnsmall/.dillo
/home/damnsmall/.links
/home/damnsmall/.sylpheed
/home/damnsmall/.phoenix
/home/damnsmall/upload
/home/damnsmall/kreon
/etc/wvdial.conf
-------
There is a lot of files that are already included in the remaster, that
normally would go in my /home/damnsmall/kreon directory, such as
wallpapers, and various html files, etc. Notice I have a .xinitrc. When
I restore from the boot prompt, DSL comes up with my opening  message
in Dillo, with my menu, wallpaper, wvdial settings, all ready to go.
---
Without the restore tarball being applied, one has to set up wvdial
using SciTE, and wvdialconf, placing the output of wvdialconf in
/etc/wvdial.conf. Then that user is ready to go onto the Internet with
Firefox. To backup, however, the default filetool.lst in /home/damnsmall
would have to be edited to include /etc/wvdial.conf.
----
All in all, the backup/restore time is shortened over the default
DSL 0.6.2, and I do have the option to backup/restore to a floppy,
with the tarball being about 510 kb.
---

:;):

Posted by Rapidweather on Mar. 28 2004,15:15
About the filetool.lst shown above. If you want to use the Sylpheed mail client,
you need to have these lines in your filetool.lst and run a backup after you have set up Sylpheed.
---
/home/damnsmall/.fluxbox
/home/damnsmall/.xtdesktop
/home/damnsmall/.xinitrc
/home/damnsmall/.blackboxrc
/home/damnsmall/.dillo
/home/damnsmall/.links
/home/damnsmall/.sylpheed     < This has all your personal settings, etc.
/home/damnsmall/.phoenix
/home/damnsmall/Mail          < This one.
/home/damnsmall/upload
/home/damnsmall/kreon
/etc/wvdial.conf
----
:;):

Posted by Rapidweather on Mar. 28 2004,19:08
I am now testing the DSL/FireFox remaster on a laptop, a Toshiba 4015CDS.
I have Luit Linux /knoppix folder on /dev/hda1 and boot that with a boot floppy,
and restore with a USB drive.
---
So, the remaster is run from the CD, and I have to unplug the USB pen drive
when I restore from the floppy, as the script will first look to the USB drive
then to the floppy. My restoration files are only about 550K, so they fit on the
floppy just fine.
---
I want to see if I can restore from the boot prompt, from the floppy. I see that
DSL wants the device to be /dev/floppy, and not /dev/fd0 when restoring from
the menu.
---
A side note, I find that lots of ram and cpu power are needed if I try and
remaster from my own remaster. 256 MB of ram is not enough, when I
try and create the compressed file, (that usually takes 10 min) I get a
lockup around 90-95 % completed. So, I have to remaster from the
original 0.6.2 DSL cd, but can insert a restore on that, to work with.
---
:D

Posted by Rapidweather on Mar. 28 2004,21:02
Here is the boot up procedure on the laptop (above posts) using my
remastered DSL with FireFox:
l. At the boot prompt:
  boot: fb800x600 restore
2. USB Mouse? _yes_
---
That's it, and I am looking at my desktop,  with my welcoming message, my
menu, with Firefox, ready to go.
---
To speed up the restore part, I removed a lot of the images I did not need
to keep for backgrounds on the restore floppy. Several are already included
in the remaster, and can easily be used. In /home/damnsmall/.fluxbox, I have
init (which the window manager uses) and init_background, which has the
background line:
session.screen0.rootCommand: bsetbg -f /home/damnsmall/kreon/woodroad.jpg
(that's all on one line in the init file)
I can easily copy init_background to init anytime I want a background
image. I can, before doing that, copy init to init_nobackground so I can
have both. Just restart the window manager after the switch.
---
:;):

Posted by Modrak on Mar. 29 2004,07:44
Quote (Rapidweather @ Mar. 28 2004,19:08)
IA side note, I find that lots of ram and cpu power are needed if I try and
remaster from my own remaster. 256 MB of ram is not enough, when I
try and create the compressed file, (that usually takes 10 min) I get a
lockup around 90-95 % completed. So, I have to remaster from the
original 0.6.2 DSL cd, but can insert a restore on that, to work with.

Make a lot of swap space (500 MB ?) or buy another 256 RAM module
I thing the first is cheaper :)

Posted by firefly2442 on Mar. 30 2004,07:15
I think this would be a great for the documentation that Jon is putting together. :)
Posted by Tomo on April 06 2004,12:07
Can i make a CD Remaster of my HD install ?

I have 5 Gb HD

995 Mb /dev/hda1
3400mb /dev/hda2
600mb /dev/hda3 Swap

I have 0.6.2 installed with synaptic, firefox, apache, make, gcc, my sql and intend to install. Webalizer, send mail, samba, spam assasin, proFTPd, open SLP and Webmin.


Could i make a CD remaster with all this preinstalled ?

If its image is too big could i burn it to DVD ?

Thanks

-Tom

Powered by Ikonboard 3.1.2a
Ikonboard © 2001 Jarvis Entertainment Group, Inc.