Puppy files at any depth

I have been working on the search algorithm in the 'init' script. Previously, Puppy files could only be installed one-deep. Now, they can be any depth.

If 'psubdir' kernel boot parameter is not provided, the init script will firstly search one-deep, that is, all the top-level folders.
If that fails, then the init script will go deeper, two levels. So, you could have your files in /puppies/wary071.

Searching deeper than that is going to cause significant delay at bootup, however the 'psubdir' can be used to specify any depth. For example:

psubdir=puppies/ubuntu/lucid512

...note, a leading '/' is optional.

This is efficient as the init script will only search that path.

You can even narrow the probing down completely by specifying the boot partition:

pdev1=sda2

...however with booting from usb this can change, so don't use. Anyway, init is still using 'pmedia' for (at least) one situation, to tell init if booting from usb (ex: pmedia=usbflash) and then pdev1 parameter will be ignored if it is provided.

Yeah, I am keeping 'pmedia' for some purposes. It is still useful.

Note also that the search for Puppy files is now case-insensitive, so in that odd situation where people had files like INITRD.GZ, they will still be found.


Posted on 15 Sep 2010, 9:41


Comments:

Posted on 15 Sep 2010, 9:57 by technosaurus
simpler
This is all getting too complicated.
Can't we just use the full file path for each file so that the names are irrelevant.
Maybe even put in the filesystem type such as:

pupsfs=ntfs:sda1/puppyfiles/quirky-1.2.sfs
(similar for zdrv and save - but comma separated list for savefile choices)

This naming scheme would allow some REALLY quirky features:
pupsfs=http:http://distro.ibiblio.org/pub/linux/distributions/quirky/quirky-latest.sfs
(or the closest mirror that the user selects at install time)
similar for smb and nfs (all of which would need some modified init scripts)

No more (Searching for puppy files) every time I boot.
Installs only happen once and shouldn't take any longer for an all default install.
(Most users just keep pressing enter without bothering to read)


Posted on 15 Sep 2010, 13:51 by 8-bit
wrong partition
Well, try this one on for size,
I have Puppy 5.11 installed frugally on an NTFS partition and also an ext2 partition.
I set up my menu.lst to the ext2 partition, ex. root(hd1,3) for the ext2 partition.
My NTFS partition was root (hd1,2).
The directory on each partition was named the same for the frugal installs.
When I selected to boot to the frugal install on sdb4, the darn thing kept booting to sdb2 until I renamed one of the frugal install directories and also made the change in menu.lst.
So it is something for you to try.
Do a frugal install to a directory on 2 partitions with the directory name being the same and try booting.


Posted on 15 Sep 2010, 17:36 by BarryK
No complicated
technosaurus,
It is not getting any more complicated than it was before. But I am trying to make it simpler.

You cannot specify boot partition when booting from usb, as it may change. Therefore, they are separated. Two kernel boot parameters 'pdev1=sda2 psubdir=/puppy/wary071' are pretty straightforward, but they are optional, they are just helpers. Same thing with 'pmedia', just a helper. I intend that Puppy can boot without any boot parameters, how simple is that?

Newbies can get going without any boot parameters at all. Those who are more into it can add the helpers, which just narrows down the search for the Puppy files at bootup.

Of course, in the case of usb you might say, well then have 'pupsfs=usb:/wary071/wary_071.sfs' ...then you might also need 'zdrvsfs=usb:/wary071/zdrv_071.sfs'



Posted on 15 Sep 2010, 17:44 by BarryK
pdev1
8-bit,
This is a case where one of the helper boot parameters solves the problem. In your menu.lst, put "pdev1=sdb4" and "pdev1=sdb2" in the appropriate entries.



Posted on 15 Sep 2010, 17:54 by Terryphi
Location of extra sfs files
Just to clarify, will extra sfs files still be located at the top level?


Posted on 15 Sep 2010, 19:22 by BarryK
Yeah why not...
It is easy to add hardwired override into the init script. Now, if you want, you can specify 'pupsfs' and/or 'zdrv' like this:

pupsfs=sda2:/pup071/pup_071.sfs zdrv=sda2:/pup071/zdrv_071.sfs

Just a basic implementation for now. The idea of "usb:" or even "http:" are ideas for the future.



Posted on 15 Sep 2010, 19:27 by BarryK
Extra sfs's
A recent improvement that I announced on the blog, was extra sfs's can be located either at the top level or in psubdir.

In the case of a frugal installation, that means the extra sfs's can be inside the directory of the frugal installation, or at the top level. This code has to be tested, but the BootManager is supposed to display whatever it finds in both locations.



Posted on 15 Sep 2010, 21:07 by perthie
PDEV1 Variable Name
Would you consider renaming this variable to something like PDEVICE? The "one" character on the end can be easily confused with an "ell" by newcomers.




Posted on 15 Sep 2010, 22:57 by PaulBx1
Documentation
Every available boot parameter should be documented, and the documentation should be available AT BOOT, not buried in some forum or wiki (that usual page we see at boot that has been there since 2.0 is a mere shadow of what should be done). One of my constant pet peeves about Puppy.


Posted on 16 Sep 2010, 8:20 by slosleuth
narrowing the probing
Will the pdev boot option prevent the mounting of local partitions in search of Puppy files?

I am interested in creating a puplet for forensics/data recovery, and I want to boot puppy from CD or USB without mounting the partitions of the computer I examining. If not, do you have a recommendation as to modifying init for this purpose? I've been studying the code, but I don't have a command of it yet.


Posted on 17 Sep 2010, 5:49 by AdrianC
wakepuppy floppy
Hello,
please, can anyone make wakepuppy bootfloppy work from *usb external* floppy drive (for booting a usb flash or hd frugal install on a laptop). Only DSL can do this for me. Thank you very much.


Posted on 19 Sep 2010, 7:06 by David C
sfs not found?
Using pup511 and "BootFlash USB Installer" (choosing the USB-HDD option) to install a frugal puppy on my USB-HDD of 120G, I can't get puppy to get past the search for the "lupa-511.sfs" file, (its seem to only search the HD not the usb-hdd), no matter what extra commands I've tred for ex. psubdir, pmedia, pupsfs, zdrv.
Is this a bug? Anybody got some good suggestions/commands to get round it. Thanks


Posted on 12 Oct 2010, 5:14 by session
Puppy updates from any depth...
This feature seems to also work in reverse. I have a frugal install within a puppy full install.
Before the init script change, putting the frugal files in the top level would interfere with the full install;
this could be avoided by placing the files in a subdirectory. Quirky 1.3 and now Wary 0.9 will overwrite
alot of the full pup's files from any location short of a seperate partition.