How to make Image.gz with usr_cram.fs inside for LAN Boot?

Using applications, configuring, problems
Message
Author
User avatar
sunburnt
Posts: 5090
Joined: Wed 08 Jun 2005, 23:11
Location: Arizona, U.S.A.

#21 Post by sunburnt »

Looks great Ted Dog, I'll try it tomorrow... getting sleepy now.

Pizzasgood; I'll see about inserting your code into Ted Dog's tomorrow.

User avatar
sunburnt
Posts: 5090
Joined: Wed 08 Jun 2005, 23:11
Location: Arizona, U.S.A.

#22 Post by sunburnt »

I got the Puppy 128 Special to LAN boot, answers my Q about usr_cram.fs being in Image.gz or image... image.
I beleave kernel arg. ramdisk_size= does override the RAMDISKFSSIZE file, usually what args. are for.
I can't fathom what's going on in Teb Dog's script, but some Qs & thoughts.
1) I assume that if I comment out the last line it won't burn a CD.
2) The best setup is to have an existing dir. "/image", that you would put any files you want added to the new image into.
The script extracts the iso to "/iso", then extracts Image.gz in "/iso", mounts it & copies it to "/image",& makes a new image.
To make a new iso file, more files would need to be added, so a different script to do it.
A gui can then be made that uses these utility scripts.

I'm making a short script just to modify the iso file.
Deletes from the iso: Boot.cat, Boot.msg, Goofy.16, Isolinux.bin, Isolinux.cfg
Adds to it: LinLd.com, it's kernel arg. file args.lin, & a batch file to run Puppy.
... So a multi. Puppy versions can be put on CD, HD, or USB & selected from a boot menu.

Ted sleepy Dog

iso to iso

#23 Post by Ted sleepy Dog »

You got the jist of it QEMU just runs a machine emulator with puppy. I find it useful to test if an ISO can boot prior to burning to CD.
I was able to get both Pizzasgoods (with a added bug- had to type XWIN) and grafpup running side by side in the same install.
The newer code was directly pulled from remaster-script. I'm glad he put in the comment on init since that is where my earlier attempts failed.

Had to add the WRKDIR since Pizzasgoods extra folder caused a bump in memory useage. It could be blank for tmp use.

iso2iso NameOfISO.iso [size in bytes] [working directory]

User avatar
sunburnt
Posts: 5090
Joined: Wed 08 Jun 2005, 23:11
Location: Arizona, U.S.A.

#24 Post by sunburnt »

Ted; so putting the cram file in image.gz allows you to run 2 Puppies in Win?
You said the RAMDISKFSSIZE is being auto. set now, so no command line arg. is needed?
So, iso2iso will extract: iso > Image.gz > image > files, wait for you to alter it, press [Enter] & it makes a new iso, right?

It looks like the Boot.*, Isolinux.*, & Goofy.16 files are needed to make the new iso file, right?
I looked up the mkisofs command & some of the args. you have aren't listed.
If the CDs not to boot, would the mkisofs line be "mkisofs -J -R -pad -o new.iso (files dir.)"?
What if you wanted to boot to DOS, what needs to be changed (briefly)?

User avatar
Ted Dog
Posts: 3965
Joined: Wed 14 Sep 2005, 02:35
Location: Heart of Texas

mkiso extra commands make CD bootable

#25 Post by Ted Dog »

These commands are under advanced commands. I personally leave off the -pad but that is the standard method of making CD/DVD bootable with ISOLINUX, The muliboot GRUB cd/DVD has like setting, and that is what works best for multiple linux on one CD/DVD my record is six, knoppix,katoix, Beatrix, Puppy, TCCBOOT, and GeeXBox on a single DVD.
I'm working on collection edition of best of bred (puppies) from the website http://www.puptrix.org where I am the webmaster.

sunburnt_

#26 Post by sunburnt_ »

I made a simple script to just make an image & mounts it & exits.
Checked properties to make sure it's executable.
Opened a console & typed the file name & it says: command not found.
ROX says /mnt/cdrive no such dir. or file.
I type ls & I can see the script & the mount dir., what's up?
The files name is mk-img.sh, here's it's code:

#!/bin/sh
######### create new image file & make ext2 file sys. on it.
dd if=/dev/zero of=image_new bs=1k count=100352
mke2fs -F -m 0 -b 1024 image_new
sync
mount -o loop image_new /image_tmp

P.S. when umounted, will the new image file be called image_new?
Thanks, sunburnt... struggling with the simple stuff

Pizzasgood;
PC = 2.4 Sempron, 1/4GB DDR333, 160GB + 120GB, DVD-R, ATI 7500, 4Mb cable, 100Mb LAN

User avatar
Pizzasgood
Posts: 6183
Joined: Wed 04 May 2005, 20:28
Location: Knoxville, TN, USA

#27 Post by Pizzasgood »

Say the script is /wherever/myscript. You have to either type

Code: Select all

/wherever/myscript
or be in the actual directory and type

Code: Select all

./myscript
Just typing

Code: Select all

myscript
will only work if it is in the path (like at /usr/bin or /usr/local/bin)

EDIT: Yeah, in that case it would be image_new. Whatever you call it when you make it is what it's called unless you rename it. Mounting doesn't change anything.
Last edited by Pizzasgood on Mon 21 Nov 2005, 00:55, edited 1 time in total.
[size=75]Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib[/size]
[img]http://www.browserloadofcoolness.com/sig.png[/img]

sunburnt_

#28 Post by sunburnt_ »

Thanks Pizzasgood; still won't work;

# ./mk-img.sh
: bad interpreter: No such file or directory
#

The drive shows mounted, I'm in the dir., I see the mount point /image/tmp & the file mk=img.sh.... ARRRGHH!!!!!
I have the worst luck with all Linux distros, can't make this, no lib for that, no permission, etc., etc.

I'm running Pizza105, that's why I'm using the alias, usually in Win98.
Hey... how are you doing with empty crust Puppy?

User avatar
Pizzasgood
Posts: 6183
Joined: Wed 04 May 2005, 20:28
Location: Knoxville, TN, USA

#29 Post by Pizzasgood »

Just a thought, last post you said image/tmp, and the post before it was imag_tmp/
Probably just typing one here while it's the other there, but I've actually done that before, so it's worth checking :wink:

Okay, first thing to do is find out which step is giving the error. Try doing it step by step in a console instead to pinpoint it.

The only other things I can say without being able to see the actual filetree is that you should check the locations in the script. Remember that /image_tmp is at the root, image_tmp is in the current directory. And make sure it's unmounted before you mount it (I don't think that's the problem though).

Maybe get rid of the .sh extension. Actually, I think that's probably it. That extention changes the working directory if I remember correctly.


As for empty crust, it's on hold 'till 1.0.7 comes out. Meanwile I'm working on PupBeGone (PupGet for removing standard built-in packages like Mozilla).
[size=75]Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib[/size]
[img]http://www.browserloadofcoolness.com/sig.png[/img]

User avatar
sunburnt
Posts: 5090
Joined: Wed 08 Jun 2005, 23:11
Location: Arizona, U.S.A.

#30 Post by sunburnt »

Same report, damn it! hdd1 is mounted by the wiz as /mnt/cdrive
I cd to /mnt/cdrive, do ls to check, & dir. tree is:

/mnt_old
/mnt_new
/image_tmp/usr_cram.fs
image
mk-img

I rewrote the script to extract the image file to /image_tmp, where usr_cram.fs is already.
I removed the .sh & the ROX icon changed, & now properties say it's an executable script.
=========
#!/bin/sh
######### Put the extra files you want in the new image in /image_tmp
######### Image = /mnt_old > image_tmp > /mnt_new = image_new

# mount Image file on /mnt_old, copy its insides to /image_tmp, umount /image_old
mount -o loop Image /mnt_old
cp -a /mnt_old/* image_tmp
umount /mnt_old
sync
# create image_new file & make ext2 file sys. on it
dd if=/dev/zero of=image_new bs=1k count=100352
mke2fs -F -m 0 -b 1024 image_new
sync
# mount image_new on /mnt_new & copy the contense of the /image_tmp to /mnt_new
mount -o loop image_new /mnt_new
cp -a /image_tmp/* /mnt_new
umount /mnt_new
sync
=====
Also, will the new image file be named: image_new?
Again... thanks, if there's something I can do, say so, sunburnt
Last edited by sunburnt on Mon 21 Nov 2005, 03:30, edited 1 time in total.

User avatar
Pizzasgood
Posts: 6183
Joined: Wed 04 May 2005, 20:28
Location: Knoxville, TN, USA

#31 Post by Pizzasgood »

If that's copied and pasted, the problem is that you have
A. a capital I in image, then lowercase i's.
B. You start things with /. That takes it all the way back to /. In other words, either use the name or use /mnt/cdrive/mnt_old. If you really want to have /s on directories, stick them on the back like mnt_new/.

Try this:

Code: Select all


#!/bin/sh
######### Put the extra files you want in the new image in image_tmp
######### image = mnt_old > image_tmp > mnt_new = image_new

# mount image file on mnt_old, copy its insides to image_tmp, umount mnt_old
mount -o loop image mnt_old
cp -a mnt_old/* image_tmp
umount mnt_old
sync
# create image_new file & make ext2 file sys. on it. ~ 150MB (150*1024) = 153600
dd if=/dev/zero of=image_new bs=1k count=100352
mke2fs -F -m 0 -b 1024 image_new
sync
# mount image_new on mnt_new & copy the contense of the image_tmp to mnt_new
mount -o loop image_new mnt_new
cp -a image_tmp/* mnt_new
umount mnt_new
sync 

That worked for me when run with ./mk-img
And it does make img_new as the new one.
[size=75]Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib[/size]
[img]http://www.browserloadofcoolness.com/sig.png[/img]

User avatar
sunburnt
Posts: 5090
Joined: Wed 08 Jun 2005, 23:11
Location: Arizona, U.S.A.

#32 Post by sunburnt »

It's running now, but it has errors on all of the files; cannot create symbolic link & failed to preserve ownership.
I don't know what's wrong or if it's normal (doesn't seem so), but I'm going to try it anyway, & who knows?
Hope it works, I'll let you know, but either way you've made it possable.
If I get it running right it would make a great addition for ROX, if that can be done?
ROX opening, extracting, & compressing; iso, image, & gzip files. It'd make Puppy work easy.

User avatar
sunburnt
Posts: 5090
Joined: Wed 08 Jun 2005, 23:11
Location: Arizona, U.S.A.

#33 Post by sunburnt »

It's running, but with errors on all files; cannot create symbolic link & failed to preserve ownership.
Don't know what's wrong, I tried "cp -a -P " to preserve ownership, no change, I'll try it anyway.
Maybe an addon for ROX to work with iso, image, & gzip files, it'd make Puppy work easy.

User avatar
Ted Dog
Posts: 3965
Joined: Wed 14 Sep 2005, 02:35
Location: Heart of Texas

Windows files lack full linux atrribute flags

#34 Post by Ted Dog »

Many of the messages could be due to using FAT directly. RAM is safe and so is ext3 that I was using, sorry to not make that clear. This has tripped me up countless times. Try moving your working directories into /root/ (which is ext2 inside a file on FAT drive called pup015) or /tmp (which is in memory and linux full supported) to clear those errors. Permissions are important to preserve.

User avatar
Pizzasgood
Posts: 6183
Joined: Wed 04 May 2005, 20:28
Location: Knoxville, TN, USA

#35 Post by Pizzasgood »

That's why I use a big partition image in HackyRemaster. Then I know it will be within an ext2 filesystem, and it can be put anywhere Puppy can read and write to.

So solve this on the harddrive, do the same thing you do to make the image to make another image, and put those mountpoints within that. Then it would work correctly.
[size=75]Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib[/size]
[img]http://www.browserloadofcoolness.com/sig.png[/img]

Guest

#36 Post by Guest »

: bad interpreter: No such file or directory
usually means it does not like the first line of your script ... it should be
#!/bin/sh
you could try deleting the first line and typing it again

you could try typing:
cd /
sh mk-img.sh


if it runs ok, then the first line of your script (#!/bin/sh) has something wrong with it

User avatar
sunburnt
Posts: 5090
Joined: Wed 08 Jun 2005, 23:11
Location: Arizona, U.S.A.

#37 Post by sunburnt »

Reworked it again, Pizzasgood's right, I keep thinking of a drive as root dir.... wrong, everything is a dir. tree.
Damn DOS habits, & Ted's right about the DOS drive not working, anyway it runs with no errors reported.
But, I put the new Image.gz & kernel in /tftpboot, boot the client & I get:

mounted root (ext2 file system) ... then ... attempt to access beyond end of device
(then a list of EXT2-fs errors) unable to read inode block (block numbers)
More: attempts to access beyond end of device ... Finally: kernel panic: No init found.

Puppy's image + cram file is 58MB, almost half the 96MB size of the image I created, is there any "image size" setting?
Puppy106 & Pizza105 both failed, the 128 special worked, any differences you know of, WHO MADE 128?

User avatar
Ted Dog
Posts: 3965
Joined: Wed 14 Sep 2005, 02:35
Location: Heart of Texas

two issues

#38 Post by Ted Dog »

1) ramdrive_size on boot line incorrect (too small)
2) removing the odd code that I ripped from BK's script which removes one type of init and restores the busybox version.

bonus: #3) ramsize in etc wrong
good thing it will usally tell you what it wants (size for ramdrive) and what it currently is.

User avatar
sunburnt
Posts: 5090
Joined: Wed 08 Jun 2005, 23:11
Location: Arizona, U.S.A.

#39 Post by sunburnt »

Changed the 2 Pizza files in .etc to 98304, that's 749KB bigger than than the image & cram files.
The 2 files were the same in Puppy105, & the same in 128 special, but different in Pizza.
Same errors, 128 special is the only Puppy that LAN boots & it isn't even offered as such!
128 special is old, how old I'm not sure, perhaps whoever made it could update it, 1.0.7?
WHO MADE 128 special? If they'd answer Qs, I might solve this & there'd be a LAN Puppy.
The front page has advertized it for some time now, that's what attracted me to Puppy.
Went to Freesco for BladeHunter's post, but it stopped dead & I never heard of it again.
I beleave LanPuppy is the only nonexistant Puppy there is, all the others are working.

ADDENDUM: I went to the Damn Small Linux site, I hadn't been there in a long time, they had a LAN boot version & it worked great, but I don't care for DSL much, I do like Puppy, I'm taken with the fuzzy little guy.
I think most people just don't know that their PC can run with only the MB, CPU, memory, video bd., & the box, NO DRIVES, & that if something goes wrong just reboot, no data on HDs scattered all over the place to corrupt.
As PCs proliferate in the home as they have the work place this will become the defacto way of network supported PCs.
How about diskless desktops & laptops that boot from wireless LANS?

ADDON #2 I thought to DnLd John's version & it's big image like the older one I have (I didn't know that) & it LANboots as well, I messaged him & hopefully he can throw some light on how to convert std. Puppies.

Better than the 128 special would be Image.gz in ramdisk & nfs mount /usr file system, better in memory use & the puppy files & layout would be the same, I think it'd run in 64MB, a totally nfs mounted file system might run in 32MB.
Last edited by sunburnt on Tue 22 Nov 2005, 09:50, edited 3 times in total.

User avatar
Ted Dog
Posts: 3965
Joined: Wed 14 Sep 2005, 02:35
Location: Heart of Texas

John Murga special puppy version

#40 Post by Ted Dog »


Post Reply