mkSFS ... FIXED app. for making SFS files.

Stuff that has yet to be sorted into a category.
Post Reply
Message
Author
User avatar
sunburnt
Posts: 5090
Joined: Wed 08 Jun 2005, 23:11
Location: Arizona, U.S.A.

mkSFS ... FIXED app. for making SFS files.

#1 Post by sunburnt »

This is an old app. I wrote about a year ago, it seems to work well, consider it testing.
The original GUI was small & simple, but for it to do what's needed it had to grow to this.
It makes SFS files from: directories, & iso & squash files, & also ext2 & ext3 image files.
I haven't tried iso & the 2 ext image file types, but it should be good.

When making Squash files, the top dir. & it's contense, or just it's contense can be stored.
So the GUI has 2 list boxes, the top one keeps the top dir., the bottom one just the contense.
If there's only one dir. in the top list box, a dummy dir. "/+" is stored with it to keep the dir.

It auto mounts & unmounts the files: iso, squash, ext2, & ext3.
Rxvt runs the make squashfs command which gives a progress bar, it runs
once for the entire top list box & once for each item in the bottom list box.
So the top list is stored as a group & the bottom items are appended one at a time.
The Help is spartan, if more help is needed to explain the GUI I'll write somemore.
Let me know how it works...

I'm removing it again... Still problems with some with the functioning.
==================
Attachments
mksfs.png
Fairly simple to understand, & small enough to fit on a 800x600 screen.
(35.6 KiB) Downloaded 1679 times
Last edited by sunburnt on Mon 16 Jun 2008, 23:17, edited 6 times in total.

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#2 Post by MU »

I think there was a small bug in mksfs, I changed 2 lines in the beginning.
It did not create a file "dir.lst", but a folder "dir.lst".
So you could not add directories.
I attach the patched version.
EDIT: removed, as Sunburnt updated his package.

Looks very good at first sight :)
Different to SFS-Combiner, you now also can build SFS files, if you have no temporary Linux-partition!

Mark
Last edited by MU on Thu 12 Jun 2008, 23:27, edited 1 time in total.
[url=http://murga-linux.com/puppy/viewtopic.php?p=173456#173456]my recommended links[/url]

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

#3 Post by sunburnt »

Thanks Mark; I don't know why I didn't run into the problem testing it,
but yesterday it popped up on me too & I caught it.

I've streamlined the code somemore & I'll post it after more testing.
It won't do any more than it does now, but some functions are better.

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

#4 Post by sunburnt »

Sorry about the broken app., it's an old project & was peppered with errors.

I've used the reworked version for awhile now & it's working good... SunBurnt

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

#5 Post by sunburnt »

22 downloads as of the 14th of June 2008, does anyone have a reply?

How is it working guys ??? ... Someone talk to me, I need to know!

Tell me about how it's working good, or... tell me it screws up doing whatever.

charnisingh
Posts: 138
Joined: Sat 06 Oct 2007, 11:58

mkSFS

#6 Post by charnisingh »

Hi Sunburnt,

i tried mkSFS but sorry to report that i could make any headway..

may be fault is mine as i could not understand where to put what even if i tried many times but i could not make it respond. presently i use MU sfsCombiner it works very fine and some movements are visible
immediately.

regards, Charni.

User avatar
erikson
Posts: 735
Joined: Wed 27 Feb 2008, 09:22
Location: Ghent, Belgium
Contact:

#7 Post by erikson »

sunburnt wrote:22 downloads as of the 14th of June 2008, does anyone have a reply? How is it working guys ??? ... Someone talk to me, I need to know!
I'm interested, will use it and report... but where do I get it? I assume it's temporarily withdrawn for correction?
[size=84][i]If it ain't broke, don't fix it.[/i] --- erikson
hp/compaq nx9030 (1.6GHz/480MB/37.2GB), ADSL, Linksys wireless router
[url]http://www.desonville.net/[/url]
Puppy page: [url]http://www.desonville.net/en/joere.puppy.htm[/url][/size]

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#8 Post by MU »

there was an error in checking, if a file was ext2/ext3/iso/squashfs.
I always got the message "BAD source item in list".
(muppy 0083 = Puppy 3).

So I modified around line 108:
from:

Code: Select all

   if [ "$FS" != 'ext2' -o "$FS" != 'ext3' -o "$FS" != 'iso' -o "$FS" != 'squashfs' ];then
......
to:

Code: Select all

  if [ "$FS" != 'ext2' ];then
    if [ "$FS" != 'ext3' ];then
      if [ "$FS" != 'iso' ];then
        if [ "$FS" != 'squashfs' ];then
   xmessage -title " ERROR..." "
  BAD source item in list!  

  $LINE  
   " &
   touch /tmp/mkSFS/sfs.exit
        fi
      fi
    fi
  fi
So I replaced the "-o" with seperate "if"s.
I attach my patched version.
I'm currently trying to build a 1 gigabyte SFS on a slow network-computer, so I could not test yet, if it works.

Mark
Attachments
mksfs-mufixed.tar.gz
for TESTING only!
(2.58 KiB) Downloaded 503 times
[url=http://murga-linux.com/puppy/viewtopic.php?p=173456#173456]my recommended links[/url]

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#9 Post by MU »

no, there still is something wrong...
I think it is the issue described by sunburnt here:
http://murga-linux.com/puppy/viewtopic. ... 7&start=60
So this is a conceptual problem?

I combined 5 sfs files to one.

I now get this folderstructure in "/":
# ls -1
archive
backup
bin
dev
etc
etc_1
etc_2
etc_3
initrd
lib
lib_1
lib_2
lost+found
malice
media
minisys
minisyscd
mnt
opt
proc
root
root_1
root_2
sbin
sys
test1
test2
tmp
usr
usr_1
usr_2
usr_3
usr_4
var
var_1
And the help requires an absolute Path:
help() {
xmessage -center -title " Help for: SFS file maker." "`cat /usr/local/bin/mksfs.help`"
}
Mark
[url=http://murga-linux.com/puppy/viewtopic.php?p=173456#173456]my recommended links[/url]

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

#10 Post by sunburnt »

MU; Correct, mksquashfs creates duplicates of dirs. Did you do the files all at once, or one at a time?

I'll be testing if this command fixes it:
-no-duplicates do not perform duplicate checking

But then how does it fix it? Hopfully it just merges the files in the same dir., & last file rules.

Also this command should eliminate the need for a "dummy" dir. for just one path:
-keep-as-directory if one source directory is specified, create a root
directory containing that directory, rather than the
contents of the directory

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#11 Post by MU »

sunburnt wrote:MU; Correct, mksquashfs creates duplicates of dirs. Did you do the files all at once, or one at a time?

I'll be testing if this command fixes it:
-no-duplicates do not perform duplicate checking
I added all at once, but had the same result with just 2 folders I added to a new sfs.

-no-duplicates
This does not work for me.

It seems the only way would be to use a temporary folder.
To make this possible also on windows-partitions, an empty ext2 file could be created.
like such a 10 MB file:
dd if=/dev/zero of=test.ext2 bs=1024k count=10
mkfs.ext2 test.ext2
This now could be mounted.

Disadvantage:
- requires another loop-device (if not added to /etc/fstab)
- lot of checks and free-space calculations.

These reasons currently hinder me, to add that to SFS-Combiner.
Mark
[url=http://murga-linux.com/puppy/viewtopic.php?p=173456#173456]my recommended links[/url]

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

#12 Post by sunburnt »

MU said; I added all at once, but had the same result with just 2 folders I added to a new sfs.
I assume you ment that you added 2 dirs. one at a time, & it did the same thing (I'm not surprised).

So... Unfortunately this means that mksquashfs can't handle the merging of dir. trees. BUMMER!
It'd be way too much trouble to figure out if merging's needed, so an image file it is.
Oh well... Accepting the image compilcation as is, at least this simplifies the code & GUI.

Mark; Are you goin to add other file types & dirs. to your app.? If you do, mine's not needed.

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#13 Post by MU »

sunburnt wrote: So... Unfortunately this means that mksquashfs can't handle the merging of dir. trees. BUMMER!
yep :cry:
sunburnt wrote: Mark; Are you goin to add other file types & dirs. to your app.? If you do, mine's not needed.
No, not in the next two months or so.
This week I look for the panel-issues in Muppy.
And my new girl-friend issues ;)

Then 2 weeks of server-installations.
Then I'd really need to upgrade some packages in Muppy, like firefox 3, Wine 1, Gtk 2.12 and such.
This will take another 3 weeks.
Then some unforseen issues like customer-requests, maybe new contracts...
So no time for a upgrade of SFS-Combiner, and I would highly appreciate, if you would continue mksfs instead :)
Mark
[url=http://murga-linux.com/puppy/viewtopic.php?p=173456#173456]my recommended links[/url]

User avatar
HairyWill
Posts: 2928
Joined: Fri 26 May 2006, 23:29
Location: Southampton, UK

#14 Post by HairyWill »

sunburnt wrote:Unfortunately this means that mksquashfs can't handle the merging of dir. trees. BUMMER!
I haven't read all the history to this so my suggestion may miss the point and be completely useless.

Why don't you use unionfs to union the 2 sfs and build the new one from the union?
Will
contribute: [url=http://www.puppylinux.org]community website[/url], [url=http://tinyurl.com/6c3nm6]screenshots[/url], [url=http://tinyurl.com/6j2gbz]puplets[/url], [url=http://tinyurl.com/57gykn]wiki[/url], [url=http://tinyurl.com/5dgr83]rss[/url]

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

#15 Post by sunburnt »

HarryWill; Excellent suggestion, in fact I had the same idea over a year ago but I forgot it!
I think it'll work because I'm sure that UnionFS can have several instances running.
It may not be what we'd hope for, but it does allow making an SFS file without an image file.
I'll look into it tomorrow. too late tonight to start on something new.
HarryWill... Thanks!

MU; Got it... I'm writing script libraries as I'm sick of rewriting the wheel. :P
It's essentally writing a programming language, choosing syntax & all...
I'll look into Harry's idea & let you know ( FYI ).

User avatar
erikson
Posts: 735
Joined: Wed 27 Feb 2008, 09:22
Location: Ghent, Belgium
Contact:

#16 Post by erikson »

A couple of n00b questions...

So I downloaded Mark's mksfs_mufixed.tar.gz

The downloaded file was named ...tar.gz.bin ; I renamed it to ...tar.gz

I clicked on it to extract, and extracted to /mnt/home ; giving three files
/mnt/home/mksfs-mufixed/mksfs
/mnt/home/mksfs-mufixed/mksfs.gtk
/mnt/home/mksfs-mufixed/mksfs.help

I clicked on mksfs.gtk which opened the Squash File Maker gui. I could enter a path and name for the new SFS file, but I can't enter source directories nor files. Also clicking help does nothing (should open mksfs.help, I presume).

I guess that I extracted to the wrong place. Where should it be? Or what else did I do wrong?

Further the gui says "(...) to have their contense stored". What is "contense", or is that a typo for "contents"?
[size=84][i]If it ain't broke, don't fix it.[/i] --- erikson
hp/compaq nx9030 (1.6GHz/480MB/37.2GB), ADSL, Linksys wireless router
[url]http://www.desonville.net/[/url]
Puppy page: [url]http://www.desonville.net/en/joere.puppy.htm[/url][/size]

User avatar
MU
Posts: 13649
Joined: Wed 24 Aug 2005, 16:52
Location: Karlsruhe, Germany
Contact:

#17 Post by MU »

copy the 3 files to /usr/local/bin/
Then type:
mksfs

Mark
[url=http://murga-linux.com/puppy/viewtopic.php?p=173456#173456]my recommended links[/url]

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

#18 Post by sunburnt »

erikson; Don't bother... It's still got errors in it. I'll repost it when i've rewritten it.

User avatar
erikson
Posts: 735
Joined: Wed 27 Feb 2008, 09:22
Location: Ghent, Belgium
Contact:

#19 Post by erikson »

sunburnt wrote:erikson; Don't bother... It's still got errors in it. I'll repost it when i've rewritten it.
Okay. I'm just starting to explore the issue of making & manipulating squashfiles, so I'm not in a hurry :-)

In the mean time I can already have a look at the script code. Even if not yet fully correct, I'll surely learn from it.

For info, here is a post of HairyWill with a remarkable script for merging, that uses unionfs. Maybe you already know it, maybe it gives some inspiration, or maybe I'm way off in my understanding of your difficulties...
http://www.murga-linux.com/puppy/viewto ... 686#164686
[size=84][i]If it ain't broke, don't fix it.[/i] --- erikson
hp/compaq nx9030 (1.6GHz/480MB/37.2GB), ADSL, Linksys wireless router
[url]http://www.desonville.net/[/url]
Puppy page: [url]http://www.desonville.net/en/joere.puppy.htm[/url][/size]

Post Reply