Page 4 of 4
Posted: Mon 13 Oct 2014, 09:24
by Gobbi
slavvo67 wrote: Can you remaster and create an iso without having to move files in or have a cd in the drive? For example, I boot from USB but wouldn't mind making the remaster into an .iso for later use, as well.
The ISO file is needed for the
vmlinuz , etc ... and the other files that makes the remaster to boot from an optical drive .
No matter where I boot from - USB , HDD partition or CD/DVD , I have the exact ISO file corresponding to running puppy - mounted from outside the File System ( or at most in the
/tmp ) folder , and I indicate it as the source of those files required - that's all it takes .
This way I don't have to burn ISO's , or use phisical optical media.
Posted: Mon 13 Oct 2014, 13:26
by stemsee
4U Gobbi
Sometimes things sound like nonsense to me, and other times they don't! My advice to you is write your own script or use one that has already been written by someone who understands your special needs. Do what you think is best! I'm certain that your own efforts will exceed mine. I'm sure you will have the entire support of the entire forum. As for me, I am just a visitor ready to move on. You'll be glad to know.
Remember
"Many is called; but few is chosen! Init?"
Posted: Wed 15 Oct 2014, 12:02
by Smithy
Hi Stemsee, had a go with your script, just a few remarks.
It moves very fast, like mission impossible "you have 10 seconds and your sfs will be overwritten!" Maybe no need for that until one has made their mind up?
The number choices are not entirely clear to a noobish, maybe another sentence saying what the number will do (direct to sfs for example)?
It certainly whizzed off doing stuff pretty quickly, but unfortunately I didn't have enough ram for it to do the remaster job.
Not your fault or the fault of the remaster script I might add.
Maybe most people are 16gb ram these days, but it has to be noted that an attempted quick ram remaster of a puppy sfs of over 250mb is going to fail on 2gb ram, because puppy is really 700mb+.
Nice remaster script!
Posted: Wed 15 Oct 2014, 13:18
by Gobbi
Hi stemsee !
I didn't want to trouble you in any way ...
In my last post on your thread I meant etc as etcetera and not as etc folder from the File System. I was simply using the normal puppy remaster but without having a physical optical disk .
I do appreciate your efforts in this direction as I'm interested in merging a savefile into an ISO or at least the main SFS file . From what I read until now , because of how puppy layer system is built , it was difficult to hope in such thing .
I did try your tool with Lighthouse64 602B with a savefile , but with no luck .
In Lighthouse 602B the only way I could keep the benefit of the installed AMD driver was through a savefile. With this exception , I don't use savefile , I use the remaster as tool to make the taylored puppies I need .
About the last lines of your previous post :
I don't want to bother you , or anybody else . I'm a curious tester , I notice things and sometimes my questions or statements can be wrong . i learn something , also from the errors I do .
You have more knowledge than I have , and also the ability to create new things . You already did more for this community than I did .
Posted: Tue 04 Nov 2014, 12:22
by stemsee
temseeS-Remastering-Suite works from the command line in X or nox. You
can exit the desktop to the > prompt and gain additional processor speed/memory
for the remaster and/or utilities. Alternatively run it from a terminal.
These scripts require additional files to function properly, which are
in the .pet and .sfs and .deb packages on my google drive.
StemseeS-Remastering-Suite.sfs
sfs-direct-remaster
sfs-unattended-remaster
https://drive.google.com/file/d/0B4GhZV ... sp=sharing
StemseeS-Remastering-Suite.pet
sfs-direct-remaster
sfs-unattended-remaster
https://drive.google.com/file/d/0B4GhZV ... sp=sharing
sfs-unattended-remaster: I have added routines to the utilities to allow
live rsync with running system to update a remaster directory. Also added
option to mksquashfs the remaster directory on some other partition,
in case of low space situations. CD/DVD burning utilities may or may not
be working - I haven't tested them (...I know).
Code: Select all
#!/bin/bash
#SFS-Unattended-Remaster script by StemSee copyright (C) 2014 Marcos Contant
intro () {
clear
echo "
User assumes all responsibility, use at your own risk!
INTRODUCTION
This script provides an unattended remastering session.
Answer two or three questions, then, no need to answer more.
There are also other useful utilities.
Please note: on a full installation copy initrd* to /boot/ directory
Press enter to continue ...
"
read dummy
clear
}
menu () {
clear
echo " REMASTER FUNCTIONS
For processing an existing remaster directory apupsys or bpupiso
or for any of the utilities; enter the code number;
MKSQUASHFS
'1' for a xz compressed sfs/squashfs system file from apupsys.
'2' for a gz compressed sfs/squashfs
'3' for a max '-comp xz -b 1024k -Xbcj x86' sfs/squashfs
ISO
'4' for bootable iso remake from bpupiso.
'5' for burning iso to cd/dvd.
'6' for writing iso to usb storage device with option to isohybrid.
SAVEFILE
'7' for savefile/swapfile creation.
NEW REMASTER
'8' for New SFS-Unattended-Remaster.
'9' for EXIT from this script.
'10' for SFS-Direct-Remaster.
'11' for Intro.
CD RW / DVD RW TOOLS
'12' for multisession/formatting/data-iso.
Enter a number now and press 'Enter'."
read sf
clear
}
menu
timelimit=10
dir1=apupsys
dir2=bpupiso
pathdef () {
if [ -d /live-rw-backing ]; then
path=/media/
else
path=/mnt/
fi
}
pathdef
rtn2menu="sfs-unattended-remaster && exit"
start () {
echo "Enter the drive and directory you wish to sync with running system.
For example 'sda2 apupsys' which are defaults in SFS-Unattended-Remaster
script."
read drive dir
mount /dev/$drive /$path/$drive
if [ -d "$dir" ]; then
xmessage -e "Press ok to rsync running system with /mnt/'$drive'/'$dir'."
geany /etc/DISTRO_SPECS /
touch /tmp/excluded.txt
cp ~/my-applications/.exclude /tmp/exclude
excludefiles
rsync -a -e --delete /* /$path/$drive/$dir -F --exclude-from=/tmp/excluded.txt
sync
else
echo "."
xmessage "'$dir' on '$drive' wasn't found. Please check spelling and path. Then try againPress 'ok' to try again."
start
fi
}
echo ""
workdrive () {
echo -e "Enter partition name of ext 2/3/4 partition for work directory
or for existing remaster directories/iso, for use with special functions.
eg 'sda3' or 'home'
or wait for default 'sda2' $timelimit seconds\n: \c"
drive=""
read -t $timelimit drive
if [ ! -z "$drive" ]; then
echo -e "\n You entered '$drive'"
else
echo -e "\n TIME OUT\n Assume default."
drive=sda2
fi
echo
if [ "$drive"="home" ]; then
echo "home is already mounted."
elif [ ! -d $path$drive ]; then
mkdir $path$drive
mount /dev/$drive $path$drive
else
mount /dev/$drive $path$drive
fi
echo
}
pathdef1 () {
echo "Please enter the path for the new file to be created at, in case present
partition doesn't have enough space. eg sda6/EmSeeV2.3/"
read pth1
if [ -d $path$pth1 ]; then
echo "ok"
else
echo "retry"
$retn2menu && exit
fi
}
fndboot () {
if [ -d /aufs ]; then #fatdog
. /etc/DISTRO_SPECS
name=$DISTRO_FILE_PREFIX.sfs
niso=new-$DISTRO_NAME.iso
subd=fd
echo "Please type the current boot partition and directory
eg /home/fatdog700/ or /sda2/fd700/"
read boot
if [[ -d $path$boot ]]; then
echo "OK"
else
clear
echo "error! try again" && fndboot
fi
elif [ -d /live-rw-backing ]; then #DebianDog-OpenBox version & puppy boot
name="01-filesystem.squashfs"
niso=new-DebianDog.iso
subd=dd
echo "Please type the current boot partition and directory
eg /sda1/live/"
read boot
if [[ -d $path$boot ]]; then
echo "OK"
else
clear
echo "error!" && fndboot
fi
elif [[ ! -d /aufs && ! -d /live-rw-backing ]]; then #normal pups
. /etc/DISTRO_SPECS
name=$DISTRO_PUPPYSFS
niso=new-$DISTRO_NAME.iso
subd=pp
. /etc/rc.d/PUPSTATE
echo $PUPSFS | cut -c 1-4,11-40 > /tmp/sfs
sed -i "s/$DISTRO_PUPPYSFS//g" /tmp/sfs
sed -i 's/^/boot=/' /tmp/sfs
. /tmp/sfs
elif [[ -d /media && -d /mnt ]]; then #lighthouse
. /etc/DISTRO_SPECS
name=${DISTRO_FILE_PREFIX}-${DISTRO_VERSION}.sfs
niso=new-$DISTRO_NAME.iso
subd=pp
. /etc/rc.d/PUPSTATE
echo $PUPSFS | cut -c 1-4,11-40 > /tmp/sfs
sed -i "s/$DISTRO_PUPPYSFS//g" /tmp/sfs
sed -i 's/^/boot=/' /tmp/sfs
. /tmp/sfs
fi
clear
}
cdburn () {
# borrowed from 'burniso2cd' by BK
#(c) Copyright 2006, 2007 Barry Kauler.
#Lesser GPL licence v2 (/usr/share/doc/legal). 2007 www.puppylinux.com
export TEXTDOMAIN=burniso2cd
export TEXTDOMAINDIR=/usr/share/locale
export OUTPUT_CHARSET=UTF-8
eval_gettext () {
local myMESSAGE=$(gettext "$1")
eval echo \"$myMESSAGE\"
}
export LANGORG=$LANG
Yes_lbl="$(gettext 'Yes')"
No_lbl="$(gettext 'No')"
CDRECORD='cdrecord'
if [ "`which xorriso`" != "" ];then
CDRECORD='xorrecord'
export MKISOFS='xorrisofs' #growisofs reads this variable.
fi
MEDIATYPE="`Xdialog --wmclass "mini-cd" --title "Burniso2cd" --stdout --menubox "$(gettext "Welcome to our little CD/DVD burner program!\nPlease choose whether you want to burn to a CD or DVD media.\nNote that DVDs are always burnt 'open' so can be used by Puppy\nas normal or multisession, whereas for CD you will be given\nthe choice further on whether to burn as closed or open.")" 0 0 5 CD "$(gettext 'CD-R or CD-RW (must be blank)')" DVD "$(gettext 'DVD-R or DVD-RW (must be blank)')"`"
[ ! $? -eq 0 ] && sfs-unattended-remaster && exit
SELECTIONS="`probedisk | grep '|optical|' | grep '/dev/' | cut -f 1,3 -d '|' | tr " " '_' | tr -s '_'`" #110205
SELECTIONX="`echo "$SELECTIONS" | tr '|' " " | tr "\n" " "`"
if [ "$SELECTIONX" = "" ];then
pupmessage -bg '#FF8080' "$(gettext 'Sorry, no CD/DVD drive detected')"
sfs-unattended-remaster && exit
fi
BURNERDRIVE="`Xdialog --wmclass "mini-cd" --title "$(gettext 'Burniso2cd: Choose burner drive')" --stdout --menubox "$(gettext 'Choose the CD/DVD drive to burn to')" 400x200 5 $SELECTIONX 2> /dev/null`"
[ ! $? -eq 0 ] && sfs-unattended-remaster && exit
[ ! -f /etc/cdburnerdevice ] && echo -n "$BURNERDRIVE" | sed -e 's/\/dev\///g' > /etc/cdburnerdevice
ISOFILE="`Xdialog --wmclass "mini-cd" --backtitle "$(gettext 'Please choose the iso file...')" --title "$(gettext 'Burniso2cd: Choose iso file')" --stdout --no-buttons --fselect "*.iso" 0 0`"
if [ ! $? -eq 0 ];then
sfs-unattended-remaster && exit
fi
CDR="$BURNERDRIVE"
CDDESCR="`echo "$SELECTIONS" | grep "$CDR" | cut -f 2 -d '|'`"
while [ ! "`mount | grep "$CDR"`" = "" ];do
pupmessage -bg "#ff8080" -center -name "burniso2cd" -title "Burniso2cd: ERROR" "The $CDR CD/DVD drive, described as:
$CDDESCR
is currently mounted.
Use MUT or Pmount to unmount it.
Please unmount CD drive, then click OK button..."
done
if [ "$MEDIATYPE" = "CD" ];then
Xdialog --wmclass "mini-cd" --title "Burniso2cd" --stdout --ok-label "$(gettext 'NORMAL')" --cancel-label "$(gettext 'MULTI')" --yesno "$(gettext 'You have selected iso file:')
$ISOFILE
$(gettext 'Do you want to burn a multi-session CD?
A multi-session CD is one that is left "open" so that further
tracks may be burnt later. The iso file that you have selected
will be burnt now as the first track.
Note, this is an experimental option for the Puppy live-CD, to
allow burning of sessions back to CD, thus personal data is saved
to CD and a hard drive or usb stick is not required.')
$(gettext "Please choose 'NORMAL' unless you have some special reason to burn
the CD multi-session (such as the iso is specifically for multisession).
Click 'NORMAL' button for normal burn...
Click 'MULTI' button for multi-session...")" 0 0
RETVAL=$?
else
RETVAL=12
fi
case $RETVAL in
0) #normal cd
BURNMULTI="-dao" #v2.02 added -dao
BURNMSG=""
;;
1) #multi cd
#BURNMULTI="-multi -tao -pad" #v2.02 added -tao -pad
BURNMULTI="-multi -tao padsize=300k" #w482
BURNMSG=""
;;
12) #multi dvd
BURNMULTI="yes"
BURNMSG="$(gettext '(blank DVD-R. A DVD+/-RW will be fast-wiped if it has data)')"
;;
*)
$rtn2menu && exit
;;
esac
RECHECK="yes"
BURNSPEED="10"
while [ 1 ];do #burn-again-loop
BURNSPEED="`Xdialog --wmclass "mini-cd" --title "$(gettext 'Burniso2cd: Burn') $MEDIATYPE" --stdout --spinbox "$(eval_gettext "Please insert blank \\\$MEDIATYPE into \\\$CDR")
$BURNMSG
$(gettext '(which is described as:') ${CDDESCR})
$(gettext 'Then click 'OK' button...')" 0 0 4 32 $BURNSPEED "$(gettext 'Set burn speed')"`"
[ ! $? -eq 0 ] && sfs-unattended-remaster && exit
sync
if [ "$MEDIATYPE" = "CD" ];then
DEVDEV="$CDR" #w482
echo "$(gettext 'Now executing:')"
echo " $CDRECORD $BURNMULTI -data -eject -v speed=$BURNSPEED dev=$DEVDEV $ISOFILE"
rxvt -name burniso2cd -bg blue -geometry 80x10 -e $CDRECORD $BURNMULTI -data -eject -v speed=$BURNSPEED dev=$DEVDEV "$ISOFILE"
else #dvd
echo "$(gettext 'Now executing:')"
echo " growisofs -speed=$BURNSPEED -Z $CDR=$ISOFILE"
rxvt -name burniso2cd -bg blue -geometry 80x10 -e growisofs -speed=$BURNSPEED -Z $CDR="$ISOFILE"
fi
sync
echo "$(gettext '...done')"
#v2.10 kirk contributed this...
# ******Verify burn******
DEVNAME="`echo -n "$CDR" | grep '/dev' | cut -f 3 -d '/'`"
if [ ! "$DEVNAME" = "" -a "$RECHECK" = "yes" ];then
Xdialog --wmclass "mini-cd" --title "$(gettext 'Burniso2cd: Finished')" --stdout --ok-label "$Yes_lbl" --cancel-label "$No_lbl" --yesno "$(gettext 'Would you like to verify that the burn was successful?
This may take a while depending on the size of the iso file.')" 0 0
if [ "$?" = "0" ] ;then
pupmessage -bg "#3CA8EE" -center -name "burniso2cd" -title "$(gettext 'Burniso2cd: Burn Verify')" "$(gettext 'Make sure the CD/DVD drive is closed,
then click OK')"
echo "Waiting 15 seconds to allow drive lights to finish blinking" > /tmp/burniso2cd.log #v431
sleep 15 #v431
if [ "$( md5sum $ISOFILE | cut -f 1 -d " " )" = "$(dd if=$CDR 2>> /tmp/burniso2cd.log | head -c `stat --format=%s $ISOFILE` | md5sum | cut -f 1 -d " " )" ] ;then #v431
pupmessage -bg "#3CA8EE" -center -name "burniso2cd" -title "$(gettext 'Burniso2cd: Burn Verify')" "$(gettext 'The burn has been verified as good!')"
else
pupmessage -bg "#1E90FF" -center -name "burniso2cd" -title "$(gettext 'Burniso2cd: Burn Verify')" "$(gettext 'The burn was not verified. See details in /tmp/burniso2cd.log. You should start over.')"
fi
else
RECHECK="no" #do not check if doing repeat burns.
fi
fi
eject $CDR
Xdialog --wmclass "mini-cd" --title "$(gettext 'Burniso2cd: Finished')" --stdout --ok-label "$(gettext 'FINISHED')" --cancel-label "$(gettext 'REPEAT')" --yesno "$(gettext 'If all went well, you have now burnt iso file')
$ISOFILE
$(gettext 'to a') $MEDIATYPE!
$(gettext 'If you want to burn the iso file to another') $MEDIATYPE,
$(gettext "click 'REPEAT' button...")
$(gettext "Otherwise, click 'FINISHED' to quit...")" 0 0
[ $? -ne 1 ] && break
done #burn-again-loop
$rtn2menu && exit
}
case $sf in
10) sfs-direct-remaster
$rtn2menu && exit;;
1) workdrive
if [ -d $path$drive/$dir1/aufs ]; then
. $path$drive/$dir1/etc/DISTRO_SPECS
name=$DISTRO_FILE_PREFIX.sfs
elif [ -d $path$drive/$dir1/live-rw-backing ]; then
name="01-filesystem.squashfs"
elif [[ ! -d $path$drive/$dir1/aufs && ! -d $path$drive/$dir1/live-rw-backing ]]; then
. $path$drive/$dir1/etc/DISTRO_SPECS
name=$DISTRO_PUPPYSFS
elif [[ -d $path$drive/$dir1/media && -d $path$drive/$dir1/mnt ]]; then #lighthouse
. $path$drive/$dir1/etc/DISTRO_SPECS
name=${DISTRO_FILE_PREFIX}-${DISTRO_VERSION}.sfs
fi
echo "Do you want to sync/update with running system?
y or n ?"
read option
case $option in
y) start;;
n) echo "Not updating.";;
*) ;;
esac
pathdef1
mksquashfs $path$drive/$dir1 $path$pth1$name -comp xz -noappend
if [[ "$drive"=`echo "$pth1" | cut -f1 -d '/'` ]]; then
rm -f $path$drive/$dir2/$name
mv -f $path$drive/$name $path$drive/$dir2/
else
echo "squashed using xz compression and is in '$path''$pth1'"
sleep 2
fi
$rtn2menu && exit;;
2) workdrive
if [[ -d $path$drive/$dir1/aufs ]]; then
. $path$drive/$dir1/etc/DISTRO_SPECS
name=$DISTRO_FILE_PREFIX.sfs
elif [[ -d $path$drive/$dir1/live-rw-backing ]]; then
name="01-filesystem.squashfs"
elif [[ ! -d $path$drive/$dir1/aufs && ! -d $path$drive/$dir1/live-rw-backing ]]; then
. $path$drive/$dir1/etc/DISTRO_SPECS
name=$DISTRO_PUPPYSFS
elif [[ -d $path$drive/$dir1/media && -d $path$drive/$dir1/mnt ]]; then #lighthouse
. $path$drive/$dir1/etc/DISTRO_SPECS
name=${DISTRO_FILE_PREFIX}-${DISTRO_VERSION}.sfs
fi
echo "Do you want to sync/update with running system?
y or n ?"
read option
case $option in
y) start;;
n) echo "Not updating.";;
*) ;;
esac
pathdef1
mksquashfs $path$drive/$dir1 $path$pth1$name -noappend
if [[ "$drive"=`echo "$pth1" | cut -f1 -d '/'` ]]; then
rm -f $path$drive/$dir2/$name
mv -f $path$drive/$name $path$drive/$dir2/
else
echo "squashed using gz compression and is in '$path''$pth1'"
sleep 2
fi
$rtn2menu && exit;;
3) workdrive
if [ -d $path$drive/$dir1/aufs ]; then
. $path$drive/$dir1/etc/DISTRO_SPECS
name=$DISTRO_FILE_PREFIX.sfs
elif [ -d $path$drive/$dir1/live-rw-backing ]; then
name="01-filesystem.squashfs"
elif [[ ! -d $path$drive/$dir1/aufs && ! -d $path$drive/$dir1/live-rw-backing ]]; then
. $path$drive/$dir1/etc/DISTRO_SPECS
name=$DISTRO_PUPPYSFS
elif [[ -d $path$drive/$dir1/media && -d $path$drive/$dir1/mnt ]]; then #lighthouse
. $path$drive/$dir1/etc/DISTRO_SPECS
name=${DISTRO_FILE_PREFIX}-${DISTRO_VERSION}.sfs
fi
echo "Do you want to sync/update with running system?
y or n ?"
read option
case $option in
y) start;;
n) echo "Not updating.";;
*) ;;
esac
pathdef1
mksquashfs $path$drive/$dir1 $path$pth1$name -comp xz -b 1024k -Xbcj x86 -noappend
if [[ "$drive"=`echo "$pth1" | cut -f1 -d '/'` ]]; then
rm -f $path$drive/$dir2/$name
mv -f $path$drive/$name $path$drive/$dir2/
else
echo "squashed using max xz compression and is in '$path''$pth1'"
sleep 2
fi
$rtn2menu && exit;;
4) workdrive
pathdef1
if [[ -d $path$drive/$dir1/live-rw-backing ]]; then
name="01-filesystem.squashfs"
niso=new-DebianDog.iso
subd1=dd
elif [[ -d $path$drive/$dir1/aufs ]]; then
. $path$drive/$dir1/etc/DISTRO_SPECS
name=$DISTRO_FILE_PREFIX.sfs
niso=new-$DISTRO_NAME.iso
subd1=fd
elif [[ ! -d $path$drive/$dir1/aufs && ! -d $path$drive/$dir1/live-rw-backing ]]; then
. $path$drive/$dir1/etc/DISTRO_SPECS
name=$DISTRO_PUPPYSFS
niso=new-$DISTRO_NAME.iso
subd1=pp
elif [[ -d $path$drive/$dir1/media && -d $path$drive/$dir1/mnt ]]; then #lighthouse
. $path$drive/$dir1/etc/DISTRO_SPECS
name=${DISTRO_FILE_PREFIX}-${DISTRO_VERSION}.sfs
niso=new-$DISTRO_NAME.iso
subd1=pp
fi
cd $path$drive
if [ $subd1=dd ]; then
genisoimage -b isolinux/isolinux.bin -c isolinux/boot.cat -D -l -R -v -no-emul-boot -boot-load-size 4 -boot-info-table -o "$pth1$niso" $path$drive/$dir2
elif [ $subd1=pp ]; then
mkisofs -b isolinux.bin -c boot.catalog -D -l -R -v -no-emul-boot -boot-load-size 4 -boot-info-table -o "$pth1$niso" $path$drive/$dir2
elif [ $subd1=fd ]; then
mkisofs -b isolinux.bin -c boot.cat -D -l -R -v -no-emul-boot -boot-load-size 4 -boot-info-table -o "$pth1$niso" $path$drive/$dir2
fi
clear
echo "ISO has been made. It is suitable for cd/dvd.
Do you want to
a) burn to cd/dvd now
b) write to usb storage
c) exit to the Menu
enter a or b or c"
read write
case $write in
a) echo "Enter the cd/dvd writer eg sr0 or sr1.
Make sure a writeable disc is in it!"
read writer
if [[ -e /dev/'$writer' ]]; then
growisofs -dvd-compat -Z /dev/$writer=$path$pth1$niso
echo "Finished!"
else
echo "No Go!"
fi
$rtn2menu && exit;;
b) echo "Enter the usb device; eg sdb1"
read usb
umount /dev/$usb
isohybrid $niso
dd if=$path$pth1$niso of=/dev/$usb bs=4M
echo "Finished!"
sleep 2
$rtn2menu && exit;;
c)$rtn2menu && exit;;
esac
;;
5) echo "Do you want to use puppy native burn app with gui?
Or simple in-built command?
Or dd?
Enter p or s or dd"
read in
case $in in
p) cdburn
$rtn2menu && exit;;
s) echo "Enter the cd/dvd writer and the path to the iso
eg 'sr0 /mnt/sda2/new-FatDog64.iso'
Make sure a writeable disc is in it!"
read writer iso
if [[ -e /dev/'$writer' ]]; then
growisofs -dvd-compat -Z /dev/$writer=$iso
echo "Finished!"
else
echo "No Go!"
fi
$rtn2menu && exit;;
dd) echo "Enter the cd/dvd writer and the path to the iso
eg 'sr0 /mnt/sda2/new-FatDog64.iso'
Make sure a writeable disc is in it!"
read writer iso
if [[ -e /dev/'$writer' ]]; then
dd if=$iso of=/dev/'$writer' seek=0 bs=32k
echo "Finished!"
else
echo "No Go!"
fi
$rtn2menu && exit;;
esac;;
6) echo "Enter 'usb partition iso' eg 'sdb1 sda5 /my-folder/new-Slacko-8.8.iso'
NB: If you choose to make the iso a hybrid back it up first."
read usb part iso
umount /dev/$usb
mount /dev/$part $path$part
echo "Gparted will open for you to prepare your usb device. When ready close gparted."
gparted /dev/$usb
echo "Make the iso a hybrid? y or n?"
read hybrid
if [ $hybrid=y ]; then
isohybrid $path$part$iso
else
dd if=$path$part$iso of=/dev/$usb bs=4M
fi
parted /dev/$usb set 1 boot on
echo "Finished!"
$rtn2menu && exit;;
7)
menu2 () {
echo " a) Create savefile
b) Create swapfile
c) Exit to Menu.
choose one"
read create
}
menu2
case $create in
a) echo "Create savefile; casper-rw, parsistence, pupsave.2fs etc
Enter 'path/name' and 'fs' (ext2/3/4) and 'size'.
eg /mnt/sda2/EmSee/EmSeeV2-3save.3fs ext3 5000
( ^ about 512mb)
make sure the partition is mounted. "
read savefile fs size
dd if=/dev/zero of=$savefile bs=1024k count=$size
mkfs -t $fs -q -m 0 -F $savefile
echo "Savefile Created!"
sleep 2
$rtn2menu && exit;;
b) echo "Create a pupswap.swp swapfile.
Enter path and size;
eg /mnt/home 5000"
read swap size
dd if=/dev/zero of=$swap/pupswap.swp bs=1024k count=$size
mkswap $swap/pupswap.swp
swapon $swap/pupswap.swp
echo "Swapfile Created and in use!
To make it permanent add this line to the bottom of fstab
"$swap/pupswap.swp none swp sw 0 0""
echo
sleep 4
geany /etc/fstab
echo "Press Enter when ready"
read dummy
$rtn2menu && exit;;
c) $rtn2menu && exit;;
esac;;
12) menu3 () {
echo "CD/DVD image burning and multisession functions
'1' BURNING A MULTISESSION DVD
'2' CREATE A DISC IMAGE (not bootable)
'3' BURN AN ISO IMAGE TO DVD
'4' FORMATTING A DVD RW DISC
'5' FORMATTING A CD RW DISC
'6' Return to main Menu
Type number and press enter"
read number
clear
}
menu3
case $number in
1) echo "To burn to a disk first time or add to a muti-session disc.
Enter the device and path-to-folder/file and session-type= new or multi;
eg sr0 /mnt/sda5/docs new -or- sr1 /media/sda3/e-books multi"
read writer files session
case $session in
new) if [[ -e /dev/'$writer' ]]; then
growisofs -Z /dev/$writer -r -J $files
echo "Finished!"
else
echo "No Go!"
fi
$rtn2menu && exit;;
multi) if [[ -e /dev/'$writer' ]]; then
echo "writing to a multisession disc."
growisofs -M /dev/$writer -r -J $files
echo "Finished!"
else
echo "No Go!"
fi
$rtn2menu && exit;;
esac;;
2) echo "Create a data image (iso); enter name-for-iso path-to-file
eg data-2014.iso /media/sda4/docs/*"
read nfi files
genisoimage -r -J -o $nfi $files
echo "Finished!" && $rtn2menu && exit;;
3) echo "Write iso image to disc; enter device and path-to-iso;
eg sr0 /media/home/ISO/lina-1.8.iso"
read writer niso
if [[ -e /dev/'$writer' ]]; then
#growisofs -dvd-compat -Z /dev/$writer=$niso
dd if=$niso of=/dev/$writer seek=0 bs=32k
echo "Finished!"
else
echo "NoGo!"
fi
$rtn2menu && exit;;
4) echo "Format DVD-RW disc, enter device to use; eg sr0"
read writer
if [[ -e /dev/'$writer' ]]; then
dvd+rw-format -blank /dev/$writer
echo "Finished!"
else
echo "No Go!"
fi
$rtn2menu && exit;;
5) echo "Format CD-RW disc, enter device to use; eg sr0"
if [[ -e /dev/'$writer' ]]; then
cdrecord blank=fast dev=1,0,0
echo "Finished!"
else
echo "No Go!"
fi
$rtn2menu && exit;;
6) echo "Exiting to Menu."
$rtn2menu && exit;;
esac
;;
8) if [ $sf==8 ]; then
clear
echo "ok"
fi;;
9) if [ $sf==9 ]; then
exit
else
rtn2menu
fi && exit;;
11) intro
$rtn2menu && exit;;
*) $rtn2menu && exit;;
esac
fndboot
workdrive
echo ""
echo
echo "Proceeding with remaster on '$drive'."
sleep 2
echo
echo "Checking if previous remaster directories exist."
clear
sleep 4
if [ -d $path$drive/$dir1 ]; then
echo "Previous remaster directories on '$drive' exist.
They will be overwritten unless you press Ctrl + c to stop this script now
and backup the directories '$dir1' '$dir2' which are on '$drive'."
sleep 12
echo "removing"
rm -rf $path$drive/{$dir1,$dir2}
clear
echo "removed!!"
sleep 1
fi
echo
echo "Checking for previous '$niso'."
sleep 1
if [ ! -e $path$drive/$niso ]; then
echo "No previous '$niso' found on '$drive'."
sleep 1
else
clear
echo "About to delete previous '$niso' on '$drive'.
Press 'Ctrl + c' now to stop and manually save it.
Or wait 6 seconds to proceed."
sleep 8
echo
rm -f $path$drive/$niso
echo "Deleted previous '$niso'"
clear
fi
mkdir -p $path$drive/{$dir1,$dir2}
echo "Start copying from your running system.
Press Ctrl+c anytime to stop!"
sleep 2
echo
echo "rsync '/'"
rsync -a --progress /* $path$drive/$dir1/ --exclude=/{/run/*,media,live,/lib/live/mount,cdrom,aufs,proc,mnt,sys,tmp,initrd,archive,audit,/var/cache/apt/*,/var/slapt-get/*,/var/lib/apt/lists/*,/var/lib/slapt/lists/*}
for subdir in {media,cdrom,live,/lib/live/mount,aufs,dev,proc,mnt,sys,tmp,archive,audit,live-rw-backing}
do
if [[ -e /"$subdir" ]]; then
mkdir -p $path$drive/$dir1/$subdir
echo "'$subdir' created."
else
echo "'$subdir' directory not needed for this distro."
fi
done
echo ""
echo "Entering remaster directory '$dir1'."
sleep 1
cd $path$drive/$dir1
echo "
Cleaning caches and .bak, .wh files and history."
rm -rf var/run/*
rm -rf var/tmp/*
rm -rf /var/log
rm -rf tmp/*
rm -rf audit/*
rm -rf lost+found/*
rm -rf /root/.config/geany/geany.conf
cd $path$drive/$dir1/root
rm -rf .bash_history
rm -rf .history
rm -rf .Trash/*
rm -rf .cache/mozilla
rm -rf .cache/google
rm -rf Downloads/*
rm -rf .minecraft/*
rm -rf .steam/*
rm -rf .wine/drive_c/users/root/Cookies/*
rm -rf .wine/drive_c/users/root/AppData/XBMC/userdata/addon_data/*
rm -rf .wine/drive_c/users/root/AppData/Tencent/Users/*
rm -rf .wine/drive_c/users/root/AppData/Tencent/QQ/*
rm -rf .wine/drive_c/windows/temp/*
rm -rf .wine/drive_c/users/root/Temp/*
rm -rf .Skype/*
rm -rf .thumbnails/*
echo "
Leaving '$dir1' directory."
cd ../../../../
echo -n "More cleaning..."
rm -f $path$drive/$dir1/root/.XLOADED
rm -f $path$drive/$dir1/etc/.XLOADED
chroot $path$drive/$dir1/ find . -type f -name '.wh.*' -print -exec rm -rf {} \; #remove .wh. files
chroot $path$drive/$dir1/ find . -type f -name '*.bak' -print -exec rm -rf {} \; #remove *.bak files
clear
echo -e "
Making the main.sfs squashfs filesystem choose mksquashfs code.
Key: 'pp' for puppy xz
'fd' for fatdog xz with initrd repack
'dd' for debbiandog xz max and essential tweaks
'Enter' for puppy.sfs gz
Or wait for auto detect
Enter mksquashfs code within $timelimit seconds\n: \c"
comp=""
read -t $timelimit comp
if [ ! -z "$comp" ]; then
echo -e "
\n You entered '$comp'.
Using '$comp' code for mksquashfs."
else
echo -e "
\n TIME OUT\n Assume default -comp xz."
if [[ -d /aufs ]]; then
cp -a ~/my-applications/bin/start $path$drive/$dir1/root/Startup/
comp=fd
elif [[ "$path" = /media/ ]]; then
comp=dd
elif [[ "$path" = /mnt/ ]]; then
cp -a ~/my-applications/bin/start $path$drive/$dir1/root/Startup/
comp=pp
else
cp -a ~/my-applications/bin/start $path$drive/$dir1/root/Startup/
echo "Enter custom name for sfs. '00-filesystem.squashfs' 'puppy2.sfs' etc"
read comp
fi
fi
modules () {
clear
echo "Checking for kernel-modules.sfs!"
if [ -d /initrd/pup_z/lib/modules ]; then
echo "Found so Removing modules."
rm -r $path$drive/$dir1/lib/modules
echo "Removing firmware."
rm -r $path$drive/$dir1/lib/firmware
echo "done."
elif [ -d /aufs/kernel-modules/lib/modules ];then
echo "Found so Removing modules."
rm -r $path$drive/$dir1/lib/modules
echo "Removing firmware."
rm -r $path$drive/$dir1/lib/firmware
echo "done."
else
echo "No Huge detected, modules and firmware left in sfs."
fi
}
case $comp in
pp) modules
mksquashfs $path$drive/$dir1 $path$drive/$name -comp xz -noappend
mv $path$drive/$name $path$drive/$dir2/;;
fd) modules
mksquashfs $path$drive/$dir1 $path$drive/$name -comp xz -noappend
mkdir $path$drive/$dir2/fdi; cd $path$drive/$dir2/fdi
cpio -i < $path$boot/initrd
mv -f $path$drive/$name $path$drive/$dir2/fdi
cd $path$drive/$dir2/fdi
find . | cpio -o -H newc > $path$drive/$dir2/initrd
rm -r $path$drive/$dir2/fdi
echo "done";;
dd) cp -a /dev/console $path$drive/$dir1/dev/
chmod a=rwx,o+t $path$drive/$dir1/tmp
zerosize() {
find $* | while read file; do
echo -n "."
rm -f $file
touch $file
done
}
zerosize $path$drive/$dir1/usr/share/doc -type f -size +1c
zerosize $path$drive/$dir1/usr/share/doc -type l
zerosize $path$drive/$dir1/usr/share/man -type f -size +1c
zerosize $path$drive/$dir1/usr/share/man -type l
zerosize $path$drive/$dir1/usr/share/info -type f -size +1c
zerosize $path$drive/$dir1/usr/share/info -type l
zerosize $path$drive/$dir1/usr/share/gnome/help -type f -size +1c
zerosize $path$drive/$dir1/usr/share/gnome/help -type l
zerosize $path$drive/$dir1/usr/share/gtk-doc -type f -size +1c
zerosize $path$drive/$dir1/usr/share/gtk-doc -type l
chown -R man:root $path$drive/$dir1/usr/share/man
rm -f $path$drive/$dir1/etc/resolv.conf
rm -f $path$drive/$dir1/etc/rc.d/PUPSTATE
rm -f $path$drive/$dir1/etc/.pupevent
rm -f $path$drive/$dir1/var/lib/alsa/asound.state
rm -f $path$drive/$dir1/root/.xsession-errors
rm -rf $path$drive/$dir1/root/.cache
rm -f $path$drive/$dir1/etc/blkid-cache
rm -f $path$drive/$dir1/etc/resolv.conf
rm -rf $path$drive/$dir1/etc/udev/rules.d/70-persistent*
rm -f $path$drive/$dir1/var/lib/dhcp/dhclient.eth0.leases
rm -f $path$drive/$dir1/var/lib/dhcpcd/*.lease
rm -rf $path$drive/$dir1/etc/rc.d
rm -f $path$drive/$dir1/etc/DISTRO_SPECS
rm -rf $path$drive/$dir1/lib/consolefonts
rm -rf $path$drive/$dir1/lib/keymaps
rm $path$drive/$dir1/etc/blkid.conf
mksquashfs $path$drive/$dir1 $path$drive/$name -comp xz -b 1024k -Xbcj x86 -noappend
mv $path$drive/$name $path$drive/$dir2/;;
*) modules
mksquashfs $path$drive/$dir1 $path$drive/$comp -noappend
mv $path$drive/$name $path$drive/$dir2/;;
esac
clear
echo "
If you want to make an iso file then boot files will be supplied.
copied from /boot to '$path''$drive'/'$dir2'."
echo
echo -e "
Type 'y' to create iso or 'n' to NOT create iso then press enter.
Default is 'y'. or 'm' to exit to Menu.
You have $timelimit seconds\n: \c"
answer=""
read -t $timelimit answer
if [ ! -z "$answer" ]; then
echo -e "
\n You entered '$answer'"
else
echo -e "
\n TIME OUT\n Assume yes"
answer=y
fi
case $answer in
y) echo "Copying boot files for iso."
cp -a /boot/$subd/* $path$drive/$dir2/
if [ -d /aufs ]; then
for file in vmlin* initr*
do
cp -a $path$boot$file $path$drive/$dir2/
done
cd $path$drive
mkisofs -b isolinux.bin -c boot.cat -D -l -R -v -no-emul-boot -boot-load-size 4 -boot-info-table -o "$niso" $path$drive/$dir2
echo "'$niso' is on drive '$path''$drive'."
elif [ -d /live-rw-backing ]; then
for file in vmlin* initr* wheezy-i486.sgn
do
cp -a $path$boot$file $path$drive/$dir2/live/
mv $path$drive/$dir2/$name $path$drive/$dir2/live/
done
cd $path$drive
genisoimage -b isolinux/isolinux.bin -c isolinux/boot.cat -D -l -R -v -no-emul-boot -boot-load-size 4 -boot-info-table -o "$niso" $path$drive/$dir2
echo "'$niso' is on drive '$path''$drive'."
else
for file in vmlin* initr*
do
cp -a $path$boot$file $path$drive/$dir2/
done
cd $path$drive
mkisofs -b isolinux.bin -c boot.catalog -D -l -R -v -no-emul-boot -boot-load-size 4 -boot-info-table -o "$niso" $path$drive/$dir2
echo "'$niso' is on drive '$path''$drive'."
fi;;
n) cp -a /boot/$subd/* $path$drive/$dir2/
if [[ ! -d /live-rw-backing ]]; then
for file in vmlin* initr* wheezy-i486.sgn
do
cp -a $path$boot$file $path$drive/$dir2/
done
elif [[ -d /live-rw-backing ]]; then
for file in vmlin* initr* wheezy-i486.sgn
do
cp -a $path$boot$file $path$drive/$dir2/live/
done
mv $path$drive/$dir2/$name $path$drive/$dir2/live/
echo "'$dir2' directory left in existence.
Can be deleted for you if no longer needed."
fi;;
*) clear
echo "Sorry, unexpected input.'$dir1' and '$dir2' directories on '$drive'
left in existence. Exiting to Menu!" && $rtn2menu;;
esac
clear
echo -e "
Enter 'k' to keep or 'd' to delete /'$path/'$drive'/'$dir2'.
You have $timelimit seconds\n: \c"
choice=""
read -t $timelimit choice
if [ ! -z "$choice" ]; then
echo -e "
\n You entered '$choice'."
else
echo -e "
\n TIME OUT\n Assume keep"
choice=k
fi
case $choice in
k) echo "'$dir2' directory left in existence.";;
d) echo "Deleting '$path''$drive'/'$dir2'"
rm $path$drive/$dir2 -r
echo "DELETED!";;
*) echo "Unexpected input. Not deleting!";;
esac
clear
#if [ ! -f $path$drive/$niso ]; then
#echo "'$drive'/'$dir2' directory left in existence."
#sleep 3
#else
#echo "'$niso' has been created on '$drive' so deleting '$dir2' directory."
#sleep 3
#rm -rf $path$drive/$dir2
echo "
All done!
Press enter to return to menu."
read dummy
#fi
$rtn2menu
##THE END##
Posted: Wed 17 Dec 2014, 03:13
by Ted Dog
-dvd-compat and -J are problematic in growisofs and geniso commands.
-J Is for Microsoft XP days and not needed , will cause filesystem corruption with multisession.
-dvd-compat write out a large block of dead space and for VIDEO not data, removes needed space for multisessions, generally will not allow multisession.
Good work otherwise, will play and make some adjustments to support bootible BluRay and large sized file support ( > 2G )
Posted: Wed 17 Dec 2014, 08:39
by stemsee
@TedDog
Thanks so much. I am not an expert at DVD cd burning commands, I just googled, i knew there was a problem or two. Maybe you could detail what the code should be, and of course I will credit you with the credit that is due!
Great that someone else has shown interest. Please check the updated thread. StemseeS-Remastering-Suite
http://www.murga-linux.com/puppy/viewtopic.php?t=96315
Posted: Mon 09 Feb 2015, 19:55
by rufwoof
jamesbond wrote:This figure, which I gave in
this post is wrong. It is too big by a factor of two.
jamesbond wrote:stemsee wrote:No problem. But I got the scripts working for fatdog 700, studio1337, EmSeeV2.2 and DebianDog. For fatdog 700 when i remastered and got the sfs to 800mb and packed into the initrd, it wouldn't boot. So I wondered what is the limit of the initrd size and why?
The normal limit of initrd is about 30% to 50% of the RAM size by default, and increased to 80% if you use "rootfstype=ramfs" on the bootloader. I haven't tested an SFS of that size for a long time, but I remember I could get it to boot with 2GB of RAM in a qemu. I may be wrong, though, it was a long time ago.
The correct figure is (for recent kernels):
- without rootfstype=ramfs - max initrd size is 20-25% of RAM.
- with rootfstype=ramfs - max initrd size is 45-50% of RAM.
And this is true for *ALL* LiveCD Linuxes, not only Fatdog or Puppies.
Note: this is only for the size of initrd, not the size of the basesfs. If you put your basesfs outside initrd, then you can use basesfs a whole lot bigger than your RAM size, but of course it won't be loaded in RAM.
Is the limit induced by having copies? i.e the (large) initrd is loaded into memory, and then installed (copied and maybe expanded) to the new root before chroot'ing to that new root upon which the original copy is deleted. Mixed in with decompressing (so a partial third copy in temp space) ... and the normal initial puppy running/consuming space.
Having played around with PXE and gPXE a little I've noted the extreme slowness of such. Looks like TFTP is the bottleneck (small packet sizes) making booting a sizable pup nigh on pointless. As a extension of that playing around I grabbed a copy of Barebone Wary (50MB), stripped out the layers (to make a non layered pup) dropped in a later kernel/firmware/modules which enlarged that some - but that enables a puppy to be booted that can then net connect and wget larger files at reasonable speeds (my internet speed runs at 50Mbit i.e. half the LAN speed). The wget download can be a copy of the second layer that finally get's chroot'ed to - making the bootup a lot quicker and ending up with the puppy running as intended. The download and build target root system could conceptually be implemented piecemeal - bit by bit.... download a small part, extract that to the new root, delete the downloaded file and download the next piece....etc. Potentially raising the top end of puppy size that could be downloaded/run via a PXE type boot.
A bit like a very small linux (vmlinuz) boots and loads a larger linux (initrd) that then loads a even larger linux (puppy sfs). But with the addition of the larger linux (50MB wary pup) booted as a non layered pup that then loads a even larger (layered) pup.
To create the non layered Wary pup I simply left clicked to open the Wary Pup SFS, selected all and dragged to / (opting to merge contents) and then changed initrd to simply execute /sbin/init. I then packed that all into a initrd using the normal : find | cpio -o -H newc | gzip >../initrd.gz
Posted: Mon 09 Feb 2015, 21:59
by stemsee
So using your method what is the largest pup you have packed into initrd?
EmSeeV2.3 is about 2gb in size? I wonder if that would work and if it did, what advantage would that give?
As for the size limitation in FatDog64 700 you should ask jamesbond.
Posted: Tue 10 Feb 2015, 00:05
by rufwoof
stemsee wrote:So using your method what is the largest pup you have packed into initrd?
EmSeeV2.3 is about 2gb in size? I wonder if that would work and if it did, what advantage would that give?
My current ram based boot is around 1.64 GB on a 1.5GB ram system with no HDD's mounted nor swap file/partition. With that loaded and frugal ram booted the free space indicated is around 750MB. Initrd file size with pup and sfs contained within (Base Pup plus Skype, Libre Office, Openshot, full Inkscape, Audacity, Blender, xvidcap) is around 450MB.
Adding more above that and PXE boots start to fail.
Provided a PXE booted PC has sufficient ram it can remaster a initrd with pup sfs contained. With a local HDD with sufficient space available the capacity to remaster is more assured - but obviously requires mounting of the local HDD. I've adapted my remaster script to use internally stored copies of the CD files so that no CD or ISO image is required during remastering. So a PXE booted PC can in turn remaster its own 'humongous' initrd and has the vmlinux stored internally - so it can then become a PXE server for other PXE clients itself (which could then also remaster and become PXE servers ...etc).
Posted: Tue 10 Feb 2015, 01:09
by stemsee
I am definetely going to try this soon. May I see your remaster script?
PXE to Remaster to new ISO for PXE
Posted: Tue 10 Feb 2015, 01:27
by gcmartin
Hello et.al. I too have used the PXE-remaster-PXE. BUT my experience was totally within the LightHouse602 (LH) distro and a LAN PC. @TaZoC took great insight and effort to automate PXE use, so that any user ONLY NEEDS TO KNOW WHICH ISO distro he wants a LAN PC to boot. It not only is TOO EASY, but, its builtin to the LH distro and takes very little space with no impact in LH uses or application impacts when its active in the LH background.
LH has a neat utility builtin;namely Menu>Network>Netboot Server. It will ask anyone for the ISO and will use the user's ISO to build the "Humongous" which is used for booting by the LAN PC. (The term Humongous was coined by @jamesBond, the father of the PXE service used and written about in Puppyland)
Powerup the LAN PC which will boot over the LAN from the LH Netboot Server, tailor the system/subsystems, add necessary functionality with PETs/SFSs, and Remaster the system into an ISO; saving the the new ISO on a
LAN shared resource so that the LH Netboot Server PC can see it.
Then rerun the LH using the new ISO, and bot/reboot a LAN PC on the new Humongous.
I have never investigated the Humongous size and have booted, even the LightHouse Mariner distros via this technique over the LAN.
Questions
- Has anyone discovered problems with this subsystem's use in LH with some particular ISOs?
- Am I understanding the recent posts: Is there a known limit to how big a Humongous can be? OR is there a limit to things which can fit into a Humongous?
thanks in advance for any clarity on the questions anyone can provide.
Posted: Tue 10 Feb 2015, 08:01
by rufwoof
Yes I also have JamesBond's script to 'drop in' a ISO instead of a directly formed initrd.
Code: Select all
#!/bin/sh
#jamesbond 2011
# convert a puppy iso into netboot-compatible vmlinuz and humongous initrd.gz
Xdialog --title "mknetboot" --msgbox "This script will create a set of files suitable for puppy netbooting.
The input is a puppy ISO file. The output will be located in /tmp/netboot - one vmlinuz and one huge initrd.gz.
If /root/tftpboot/pxelinux.cfg exist, the output files will be symlinked to this directory as well,
so you can use netboot-server to server them straight away." 0 0
ISO=$(Xdialog --title "Choose puppy ISO" -fselect "" 0 0 2>&1 | tail -n 1)
if [ -n "$ISO" ]; then
rm -rf /tmp/netboot /tmp/netboot_iso
mkdir -p /tmp/netboot/x /tmp/netboot_iso
if mount -o loop "$ISO" /tmp/netboot_iso; then
if [ -f /tmp/netboot_iso/vmlinuz -a -f /tmp/netboot_iso/initrd.gz ]; then
Xdialog --title "mknetboot" --no-buttons --infobox "This will take a while. Please wait ..." 0 0 60000 &
PID=$!
cp /tmp/netboot_iso/vmlinuz /tmp/netboot
cd /tmp/netboot/x
zcat /tmp/netboot_iso/initrd.gz | cpio -i
cp /tmp/netboot_iso/*.sfs .
find . | cpio -o -H newc | gzip -9 > ../initrd.gz
cd /tmp/netboot
rm -rf x
if [ -d /root/tftpboot/pxelinux.cfg ]; then
rm /root/tftpboot/pxelinux.cfg/vmlinuz /root/tftpboot/pxelinux.cfg/initrd.gz
ln -s /tmp/netboot/vmlinuz /root/tftpboot/pxelinux.cfg
ln -s /tmp/netboot/initrd.gz /root/tftpboot/pxelinux.cfg
fi
kill $PID
Xdialog --title "mknetboot" --infobox "Done. Output is in /tmp/netboot." 0 0 10000
else
Xdialog --title "mknetboot" --msgbox "Invalid ISO - cannot find vmlinuz and initrd.gz" 0 0
rm -rf /tmp/netboot
fi
umount /tmp/netboot_iso
rm -rf /tmp/netboot_iso
else
Xdialog --title "mknetboot" --msgbox "Failed to mount $ISO" 0 0
fi
fi
That copies in any other sfs's as well - so I'm surprised that LH Mariner PXE booted ok with presumably such a large humongous initrd. My 1.5GB ram system hits the wall at around 450MB initrd size of high compressed content i.e. 30% of available ram. Somewhat oddly that also applies if I PXE boot on a PC with a larger amount of memory (4GB), so it may be down to a limitation of the PC that formed the initrd (1.5GB system) rather than the PC that was PXE booting that initrd.
Posted: Tue 10 Feb 2015, 19:58
by stemsee
I don't think so. I had 8g2g laptop but could not get past 600MB fandom.
Posted: Tue 10 Feb 2015, 21:41
by gcmartin
Recommend an ISO (here or PM me) and I will test the Netboot utility on my Mariner.
Posted: Thu 12 Mar 2015, 16:06
by sketchman
OP needs updated with latest script. I did try the one that is updated in the OP, and I got an iso that was 34k and could not be mounted or used.
Trying the latest one now.
EDIT: Not working. It does not create a sfs and the iso it makes is 34k still and useless. Not sure what else to try.
It's doing some weird stuff too. I selected sdc1 (a usb flash drive) as the only dir to work with each time it asked me for a dir. It used it, but it created a secondary "/sdc1/apupsys/" inside "/sdc1/bpupiso" (so "/mnt/sdc1/bpupiso/sdc1/apupsys/") and just left it there. No sfs is ever made.
Posted: Thu 12 Mar 2015, 17:38
by stemsee
Here is the up-to-date thread, StemseeS-Remastering-Suite v4.9
http://murga-linux.com/puppy/viewtopic. ... 5&start=15
Posted: Thu 12 Mar 2015, 18:10
by sketchman
ahh thank you