Tweaks for network-booting 2.16 with humongous initrd

Under development: PCMCIA, wireless, etc.
Post Reply
Message
Author
raffy
Posts: 4798
Joined: Wed 25 May 2005, 12:20
Location: Manila

Tweaks for network-booting 2.16 with humongous initrd

#1 Post by raffy »

Barry recently successfully built a humongous initrd for net-booting Puppy 2.16, see this developer thread and the forum discussion that begins here.

(Edit: See the link in the next post below for Barry's instructions about creating the humongous initrd. )

Some questions:

- what tweaks would you do to enable the netboot in a 128-MB RAM client?

- can you use a pup_save.2fs locally saved (say, in USB boot) to netboot the client and no longer use zdrv.sfs from the server? (this is using local storage to store the needed drivers)

Have fun!

EDIT: The URL of Barry's original post about humongous initrd.gz creation is gone, so here is the original page:
Thursday, May 24, 2007, 07:45 PM
Tweaking the humongous-initrd

Raffy posted this forum message to invite participation:
http://www.murga-linux.com/puppy/viewtopic.php?t=18421

If you want to build your own humongous initrd, it is very easy. Just download 'puppy-unleashed-core-2.16.1.tar.gz' and expand it inside a ext2/ext3/reiserfs hd partition:
# tar -zxf puppy-unleashed-core-2.16.1.tar.gz

You will then have a directory 'puppy-unleashed', inside you will find 'boot' directory, and inside that 'initrd-tree' directory.

Mount the 2.16.1 live-CD, or use Isomaster to open up the 'puppy-2.16.1-seamonkey-fulldrivers.iso' and copy 'pup_216.sfs' and 'zdrv_216.sfs' into puppy-unleashed/boot/initrd-tree.

Open a terminal window in puppy-unleashed/boot and execute:
# ./makeext2initrd

That's it, you will have created a humongous initrd.gz!

Note, initrd-tree/init is a script but it is not used and gets removed by the makeext2initrd script -- that one is for an initramfs. The bootup script that is used is sbin/init and that's where all the tweaking will occur.

BarryK
Thursday, May 24, 2007, 08:20 PM
If you download the PET packages into 'packages' directory and follow instructions in the README, you can build a humongous initrd, that is a 'zdrv_216.sfs' with a cutdown set of drivers, or a 'pup_216.sfs' with a cutdown set of drivers built-in (no zdrv file). This could be used to reduce the size of the humongous initrd.

Raffy
Thursday, May 24, 2007, 08:53 PM
Thanks, Barry, this is a fun way to get started with "unleashed" - building one's unique Puppy. :-)
Last edited by raffy on Sun 20 Apr 2008, 04:23, edited 3 times in total.

User avatar
BarryK
Puppy Master
Posts: 9392
Joined: Mon 09 May 2005, 09:23
Location: Perth, Western Australia
Contact:

#2 Post by BarryK »


raffy
Posts: 4798
Joined: Wed 25 May 2005, 12:20
Location: Manila

drivers in pup_save work

#3 Post by raffy »

Good news, net-booting works even if zdrv is not in initrd, provided that pup_save (previously saved in the client) is available in the client machine.

As to booting a 128-MB client, I had no success with a 58-MB initrd.gz (that expands to 62548 KB). The available RAM is 126 MB (as only 2 MB is left for the shared video).

What tweaks can we do to the booting process to maximize the use of available RAM (and enable booting of that 58-MB initrd.gz in a 128-MB machine)?

Btw, that 58-MB initrd.gz has no problem, as am using it now in a machine with 256 MB RAM.

Thanks!

In case it's needed, here's df output:

Code: Select all

Filesystem           1k-blocks      Used Available Use% Mounted on
/dev/root                60561     58924      1637  97% /initrd
/dev/loop0               57792     57792         0 100% /initrd/pup_ro2
/dev/sda1               255716    254612      1104 100% /initrd/mnt/dev_save
/dev/loop1               63461      5858     57603   9% /initrd/pup_ro1
tmpfs                   119880      1440    118440   1% /initrd/pup_rw
unionfs                 241132     65092    176040  27% /

raffy
Posts: 4798
Joined: Wed 25 May 2005, 12:20
Location: Manila

no pup_216.sfs inside initrd

#4 Post by raffy »

While this situation is outside the usual practice, an admin might one day want to enable use of pup_216.sfs in the client machine (perhaps he adds a last option in the server that says, "OK, load your own Puppy").

Here are the error messages and bootinit.log when doing this with the current init scripts:

Code: Select all

Looking for Puppy in hda1... sda1...

PLEASE CHOOSE WHICH PERSONAL FILE TO USE
0 none
1 pup_save.3fs (in partition hda1)
2 pup_save.2fs (in partition sda1)
Please type a number then press ENTER key: 2
Using personal data file pup_save.2fs which is on partition sda1

ERROR, cannot find Puppy on 'idehd' boot media.
PUPMODE=9 PDEV=
Exited to initial=ramdisk (initramfs) commandline...
The "cannot find Puppy" error shows regardless of storage used, idehd or usbflash.

While using a USB stick at boot time, bootinit.log in /tmp shows this:

Code: Select all

USB-Storage: Loading usb-storage module
USB-Storage: Detecting connected device(s)... 1 2 3 4 5
USB-Storage: Device scan complete, found 1 devices
PDEV1=
FSTYPE=
PUPSFS=
DEV1PUP=
PUPSAVE=vfat,sda1,/pup_save.2fs
ZDRV=

User avatar
BarryK
Puppy Master
Posts: 9392
Joined: Mon 09 May 2005, 09:23
Location: Perth, Western Australia
Contact:

#5 Post by BarryK »

Raffy, if you want to do that, then why have network booting at all, why not just boot Puppy off the Flash drive?

raffy
Posts: 4798
Joined: Wed 25 May 2005, 12:20
Location: Manila

policy as an example

#6 Post by raffy »

Yes, right. I was just thinking that if a computer lab starts with a network-boot policy, this policy will stick. This could also be a way of ensuring that some important attributes are common in the whole lab, like Puppy version or a small added sfs, while allowing personal styles, such as in a remastering lesson.

I tend to think now beyond the standalone PC and of a whole Puppy lab (luv?) - hey, what a coincidence there! (Lobster must be smiling. :) )

MrLars
Posts: 1
Joined: Mon 15 Mar 2010, 10:18

#7 Post by MrLars »

Hey,

i tryed to make the puppy 4.2 bootable over my network, but it cant find the .sfs file.

so i tryed to make an humongous initrd.gz, but without succes. when i do the last step, the ./makeext2initrd the machine hangs an i get errors that there is not enough diskspace.

im running the script on a live-cd version so when i reboot the logfiles are gone.

can someone point me in the right direction or be so kind and do it for me?

Post Reply