Avoid "Searching for Puppy files" during bootup - revisited
Hello @Boof
I think @Gyro want info from this terminal command while your USB stick in plugged in.. Post it if you can.
I think @Gyro want info from this terminal command while your USB stick in plugged in.
Code: Select all
# fdisk -l
Updated to version 6
Version 6 should work with usb devices.
Version 5 could not.
I recommend that you upgrade to version 6.
See first post for downloads.
I tested this on a 4GB usbstick, doing manual frugal installs using the Tahrpup 6.0.2 files directly out of the iso, but replacing the "initrd.gz" with my patched version.
In each case I copied the puppy files onto the freshly partitioned usbstick, and then ran "Grun4Dos bootloader config", installing the "bootup loader" in the MBR of the usbstick.
Test1: all of stick formatted as fat32 by windows 8.1, worked.
Test2: 100MiB fat32 partition for booting, remainder of stick an ext4 partition containing the puppy files, worked.
gyro
Version 5 could not.
I recommend that you upgrade to version 6.
See first post for downloads.
I tested this on a 4GB usbstick, doing manual frugal installs using the Tahrpup 6.0.2 files directly out of the iso, but replacing the "initrd.gz" with my patched version.
In each case I copied the puppy files onto the freshly partitioned usbstick, and then ran "Grun4Dos bootloader config", installing the "bootup loader" in the MBR of the usbstick.
Test1: all of stick formatted as fat32 by windows 8.1, worked.
Test2: 100MiB fat32 partition for booting, remainder of stick an ext4 partition containing the puppy files, worked.
gyro
For those using SAVEMARK
Since "/mnt/home" is the partition where your savefile/savefolder is stored, it's probably more convenient to copy "PUPSTATE" there beside the savefile/savefolder.
Just ensure that the "nosearch=sd??" boot parameter specifies the partition that "PUPSTATE" was copied to.
gyro
Just ensure that the "nosearch=sd??" boot parameter specifies the partition that "PUPSTATE" was copied to.
gyro
BECAUSE I have updated my system, the.sfs in the iso is invalid. I can't mount it to use the universal installer. I DO wish the universal installer would install ANY puppy version, not just its own. I'm advised there is an sfs version updater in the utilities menu, but I don't recognise a name or know how to use it. Advice pls.
Re: Updated to version 5
I followed and tested through version 3. For me adding and keeping track of another file in the boot directory for each pup is a dealbreaker. One of the beauties of the frugal installs for me always has been the small and uniform number of files to keep track of and maintain (I juggle multiple pups on most of my platforms). Back to my 3 line "ignore=usb" patch.gyro wrote:This version greatly simplifies the code at the expense of a little processing inefficiency.
Instead of reading the file "PUPSTATE" directly from the savefile/savefolder, it looks for it in the frugal install directory. So it doesn't have to wait until the savefile/savefolder is available before making the final decision.
To use:
1) Put patched "initrd.gz" in the frugal install directory.
2) Reboot to show that everything is still the same.
3) Copy "/etc/rc.d/PUPSTATE" to the frugal install directory.
4) Add "nosearch=sda3" as boot parameter (using appropriate partition instead of "sda3").
5) Reboot.
The "nosearch" facility can be deactivated by either removing the "nosearch" boot parameter or deleting the "PUPSTATE" file in the frugal install directory.
To add an adrv or ydrv to the boot:
1) delete the copy of "PUPSTATE" in the frugal install directory.
2) Reboot.
3) Copy "/etc/rc.d/PUPSTATE" to the frugal install directory.
4) Reboot
See first post for download.
gyro
Just my humble opinion. I greatly respect and support those willing to maintain and support the foundations of puppy.
Pups currently in kennel :D Older LxPupSc and X-slacko-4.4 for my users; LxPupSc, LxPupSc64 and upupEF for me. All good pups indeed, and all running savefiles for look'n'feel only. Browsers, etc. solely from SFS.
- technosaurus
- Posts: 4853
- Joined: Mon 19 May 2008, 01:24
- Location: Blue Springs, MO
- Contact:
It's the only part that isn't obsolete. When you install puppy, the installer script knows where it puts stuff amongst other things. You have to develop the installer in conjunction with init.gyro wrote:Some of the complexity comes from trying to efficiently integrate it into the 'init' script.technosaurus wrote:WOW, I can't believe how overly complex this has becomeAre you suggesting that this code in the 'init' scripttechnosaurus wrote:when it could just be a single parameter SFS= with a ',' separated list of files to mount and use full paths vs. search if an item in the list starts with '/'is obsolete?Code: Select all
#100915 requested by technosaurus (formats get changed further down)... [ $pupsfs ] && PUPSFS=$pupsfs #format partition:<path><filename> ex: sda2:/wary071/wary_071.sfs [ $zdrv ] && ZDRV=$zdrv #ex: sda2:/wary071/zdrv_071.sfs [ $adrv ] && ADRV=$adrv [ $ydrv ] && YDRV=$ydrv
gyro
Don't fix installer deficiencies with init workarounds that slow down boots.
How many *DRVs do there need to be before you just have a list?
Why does init need to search for stuff if it's not a usb install?
A basic init to X can be done in ~10 lines of c and start in less than half a second (I've done it) search for nanosaurus if your curious.
Did you know jwm has a <StartupCommand> tag that could do most of the rest of the stuff that's in the init?
Check out my [url=https://github.com/technosaurus]github repositories[/url]. I may eventually get around to updating my [url=http://bashismal.blogspot.com]blogspot[/url].
version 4 released
I have uploaded a version 4.
This is a continuation of the version 3 concepts, but it uses a "nosearch" boot parameter instead of a "pupsave" parameter.
This is because a "pupsave" parameter could be interpreted as simply defining the pupsave to use. Using "nosearch" should avoid any such an incorrect impression.
gyro
This is a continuation of the version 3 concepts, but it uses a "nosearch" boot parameter instead of a "pupsave" parameter.
This is because a "pupsave" parameter could be interpreted as simply defining the pupsave to use. Using "nosearch" should avoid any such an incorrect impression.
gyro
I have puppy_slacko_5.7.iso It won't boot from usb because it can't find the sfs file.
If I expand this iso into into sub files, the initrd.gz file exists and is some 1MB.
If I then expand initrd.gz, The initrd file shows up as empty, having only 1 empty line for text shown in geany.
I can't locate where or how to patch the files to get this to work.
If I expand this iso into into sub files, the initrd.gz file exists and is some 1MB.
If I then expand initrd.gz, The initrd file shows up as empty, having only 1 empty line for text shown in geany.
I can't locate where or how to patch the files to get this to work.
How are you 'expanding' the initrd.gz file.boof wrote:I have puppy_slacko_5.7.iso It won't boot from usb because it can't find the sfs file.
If I expand this iso into into sub files, the initrd.gz file exists and is some 1MB.
If I then expand initrd.gz, The initrd file shows up as empty, having only 1 empty line for text shown in geany.
I can't locate where or how to patch the files to get this to work.
The usual way is to create a sub directory beneath where the initrd.gz file is then change directory into that new directory and
zcat ../initrd.gz | cpio -id
Personally I like to drop the puppy sfs into the initrd file i.e. I copy puppy*.sfs into tha sub directory and then reform using
find | cpio -o -H newc > ../initrd
and then compress that if desired. If you change your grub boot loader to point to initrd instead of initrd.gz then you don't need to compress it. To re-extract a non compressed initrd you use cat ../initrd | cpio -id
As I drop puppy sfs into initrd I changed init script code to not bother searching elsewhere
Code: Select all
#first look inside initrd...
[ -f /${PUPXXXSFS} ] && PUPSFS="rootfs,rootfs,/${PUPXXXSFS}"
[ -f /${ZDRVSFS} ] && ZDRV="rootfs,rootfs,/${ZDRVSFS}"
[ -f /${ADRVSFS} ] && ADRV="rootfs,rootfs,/${ADRVSFS}"
[ -f /${YDRVSFS} ] && YDRV="rootfs,rootfs,/${YDRVSFS}"
# Rufwoof if in initrd (my default) then don't bother spending time searching elsewhere
if [ "$PUPSFS" = "" ]; then # Rufwoof added
search_func ata #110425
...
...
...
if [ "$VMLINUZ" = "" -o "$PUPSFS" = "" -o "$SAVEPART" = "" ];then
search_func usb
fi
fi
fi # Rufwoof added
@boof,
You need to have a fully functioning puppy before worrying about this stuff. It won't help the "can't find puppy.....sfs" problem.
To help with editing the "init" script you could try this topic http://murga-linux.com/puppy/viewtopic.php?t=72842
gyro
You need to have a fully functioning puppy before worrying about this stuff. It won't help the "can't find puppy.....sfs" problem.
To help with editing the "init" script you could try this topic http://murga-linux.com/puppy/viewtopic.php?t=72842
gyro
Boof I always put all files pertaing to a distro in the same directory. This keeps things tidy and contained.boof wrote:I have puppy_slacko_5.7.iso It won't boot from usb because it can't find the sfs file.
If I expand this iso into into sub files, the initrd.gz file exists and is some 1MB.
If I then expand initrd.gz, The initrd file shows up as empty, having only 1 empty line for text shown in geany.
I can't locate where or how to patch the files to get this to work.
Recently I created a USB Flash Drive with two partitions. The first partition was formatted to fat32 and the second ext2 (linux).
The distro's were slacko-5.7 and precise-5.7.1. The reason I did this was so I could create a save folder on the second partition.
The USB was originally created with MultiPup-6.0 r22. After that I used gparted to reduce the size of the fat32 partition and created a second partition which I formatted to ext2 as previously stated.
The information below from CatDude shows how I achieved this:
Cheers & thanks CatDude.CatDude wrote: The flashdrive has two partitions: 1x Fat32 (sdb1) and 1x Ext2(sdb2)
If you wish to put your savefile on a different partition to that from which you boot,
add the following to the kernel line (just temporary at the grub screen):
PSAVEMARK=2
Use the RAM stanza, and tack PSAVEMARK=2 on the end.
When you reboot, it will create the savefile on (sdb2)
it also creates a subdirectory named identical to the one you are booting from.
Another way is to create a file called SAVEMARK is the pup directory. The only contents of the file is the partition number EG: 2
Contents of (sdb1)
# tree -a
.
├── boot
│ └── grub
│ ├── menu.lst
│ ├── Multipup
│ ├── stage1
│ └── stage2
├── index.txt
├── precise-5.7.1
│ ├── boot.cat
│ ├── boot.msg
│ ├── help2.msg
│ ├── help.msg
│ ├── initrd.gz
│ ├── isolinux.bin
│ ├── isolinux.cfg
│ ├── logo.16
│ ├── menu.lst
│ ├── OLDmenu.lst
│ ├── puppy_precise_5.7.1.sfs
│ ├── README.HTM
│ ├── SAVEMARK ( Content is: 2 (only 1 line ??) )
│ └── vmlinuz
└── slacko-5.7-NO-pae
├── boot.cat
├── boot.msg
├── help2.msg
├── help.msg
├── initrd.gz
├── isolinux.bin
├── isolinux.cfg
├── logo.16
├── menu.lst
├── puppy_slacko_5.7.sfs
├── README.HTM
├── SAVEMARK ( Content is: 2 (only 1 line ??) )
└── vmlinuz
4 directories, 32 files
#
Contents of (sdb2)
# tree -a
.
├── fsckme.flg ( Content is: sdb2,ext2,/precise-5.7.1/precisesave-usbtest1.3fs (only 1 line ??) )
├── lost+found
├── precise-5.7.1
│ └── precisesave-usbtest1.3fs
├── pupdesk.flg ( Content is: ati (only 1 line ??) )
└── slacko-5.7-NO-pae
└── slackosave.3fs
3 directories, 4 files
my usb, Fat32
my usb, Fat32
Pupsaves are stored in same partition Fat32, no need to create a linux one
Pupsaves are stored in same partition Fat32, no need to create a linux one
- Attachments
-
- fat32.jpg
- Just not to imagine more complicated
- (26.02 KiB) Downloaded 194 times
i was kind of disappointed, this is only for tahr6.0.2.
so i gathered information i found and did it on slacko5.7.0.
just another minimally invasive approach:
line 806 added:
813
blabla...
989
(now new) line 990 added:
how it works:
if i specify pdev1=[partition_puppy_lives_on] AND psubdir=[path_to_puppy] as bootparameter AND a copy of /etc/rc.d/PUPSTATE is found in /mnt/$PDEV1$PSUBDIR, searching for puppy-files is skipped. any other case init behaves like normal cd|pristine|whatsoevercalled boot.
so i gathered information i found and did it on slacko5.7.0.
just another minimally invasive approach:
line 806 added:
Code: Select all
if [ "$PDEV1" -a "$PSUBDIR" ];then
FSTYPE=$(echo "$PCPARTSALL" | grep "$PDEV1" | cut -f2 -d'|')
mount -t $FSTYPE /dev/$PDEV1 /mnt/data
[ -e /mnt/data/$PSUBDIR/PUPSTATE ] && . /mnt/data/$PSUBDIR/PUPSTATE && SKIPSEARCH="yes"
umount /mnt/data
fi
if [ "$SKIPSEARCH" != "yes" ];then
blabla...
989
(now new) line 990 added:
Code: Select all
fi #END SKIPSEARCHING
if i specify pdev1=[partition_puppy_lives_on] AND psubdir=[path_to_puppy] as bootparameter AND a copy of /etc/rc.d/PUPSTATE is found in /mnt/$PDEV1$PSUBDIR, searching for puppy-files is skipped. any other case init behaves like normal cd|pristine|whatsoevercalled boot.