I want to make some permanent changes to the main pupxxx.sfs but when I tried the Edit-SFS utility the result was a much larger sfs than the original. I believe this may have to do with use of xz compression (not that I know what that means).
Please tell me the best tool to edit the sfs and keep the original size relationship. If it's via command line like unsquashfs and mksquashfs then please point out the correct parameters to use.
What is best way to edit pupxxx.sfs? Compression type xz.
after installing the Lib in /usr/lib i get# ./mksquashfs-4.2-xz
./mksquashfs-4.2-xz: error while loading shared libraries: liblzma.so.2: cannot open shared object file: No such file or directory
# ./mksquashfs-4.2-xz
SYNTAX:./mksquashfs-4.2-xz source1 source2 ... dest [options] [-e list of exclude dirs/files]
.
.
.
Compressors available and compressor specific options:
gzip (no options) (default)
xz
.
.
-comp xz for mksquashfs 4.2
Here is the command i used for racy, run from the parent dir of squashfs-root:
mksquashfs squashfs-root/ puppy_racy_5.2.1.90.sfs -comp xz
Otherwise, the main script for Edit-SFS in ~/my-roxapps/Edit-SFS/apprun could be altered with -comp xz added to (line 222 or so) and would probably work.
echo -e "#!/bin/sh\n'$MKSQUASHFS' '$TREE' '$TREE_BASE/$SFSFILE' -comp xz" > "${TREE_BASE}/script"
mksquashfs squashfs-root/ puppy_racy_5.2.1.90.sfs -comp xz
Otherwise, the main script for Edit-SFS in ~/my-roxapps/Edit-SFS/apprun could be altered with -comp xz added to (line 222 or so) and would probably work.
echo -e "#!/bin/sh\n'$MKSQUASHFS' '$TREE' '$TREE_BASE/$SFSFILE' -comp xz" > "${TREE_BASE}/script"
Re: -comp xz for mksquashfs 4.2
Thank you for explaining the syntax in the script file and very good. That's exactly what I had hoped for and the sfs size stays the same now. Looks like using the xz compression has quite an impact.upnorth wrote:Otherwise, the main script for Edit-SFS in ~/my-roxapps/Edit-SFS/apprun could be altered with -comp xz added
How will this effect the use of two utilities, edit-SFS and edit-init?
I use one to edit the puppy SFS files and the other to edit initrd.gz.
I have noticed that I used to be able to click on a puppy SFS file to mount it if it was not in use.
But some of the releases now will not mount by just clicking on them.
Is that due to the new xz compression method?
I use one to edit the puppy SFS files and the other to edit initrd.gz.
I have noticed that I used to be able to click on a puppy SFS file to mount it if it was not in use.
But some of the releases now will not mount by just clicking on them.
Is that due to the new xz compression method?
Mounting xz compressed sfs works since kernel 2.6.38 .
Slacko 2.6.37.x would have still a problem to mount these .
Slacko 2.6.39.x not .
You would have to unsquashfs the sfs and mksquashfs -comp gz again for backwards compatibility .
The diff is not small : a 60MB sfs xz comp would become 72MB gz comp (+20%) .
Slacko 2.6.37.x would have still a problem to mount these .
Slacko 2.6.39.x not .
You would have to unsquashfs the sfs and mksquashfs -comp gz again for backwards compatibility .
The diff is not small : a 60MB sfs xz comp would become 72MB gz comp (+20%) .
I also had the need to change some minor things afterwards.
So I extracted the puppy_slacko_6.3.0.sfs ( 172 MB ) by using of unsquashfs and did my wanted changes.
To created the new SFS I used mksquashfs.
Unfortunately the new SFS is now a lot bigger than the original.
I tested once again without any changes.
The same here. The new one is 191 MB.
How to increase the compression ?
To increase the blocksize leads to a better compression
but I'm not sure whether this is the right way.
How is the original SFS compressed ?
So I extracted the puppy_slacko_6.3.0.sfs ( 172 MB ) by using of unsquashfs and did my wanted changes.
To created the new SFS I used mksquashfs.
Unfortunately the new SFS is now a lot bigger than the original.
I tested once again without any changes.
The same here. The new one is 191 MB.
Code: Select all
# mksquashfs puppy_slacko_6.3.0 puppy_slacko_6.3.0.sfs
Parallel mksquashfs: Using 8 processors
Creating 4.0 filesystem on puppy_slacko_6.3.0.sfs, block size 131072.
[===========================================================|] 18590/18590 100%
Exportable Squashfs 4.0 filesystem, xz compressed, data block size 131072
compressed data, compressed metadata, compressed fragments, no xattrs
duplicates are removed
Filesystem size 195083.67 Kbytes (190.51 Mbytes)
31.31% of uncompressed filesystem size (622990.50 Kbytes)
Inode table size 166106 bytes (162.21 Kbytes)
23.99% of uncompressed inode table size (692398 bytes)
Directory table size 184786 bytes (180.46 Kbytes)
42.79% of uncompressed directory table size (431826 bytes)
To increase the blocksize leads to a better compression
but I'm not sure whether this is the right way.
How is the original SFS compressed ?
-
- Posts: 1543
- Joined: Mon 22 Feb 2016, 19:43
It adds the parameters -comp xz -Xbcj x86 -b 512K to the end, see lines 224 and 2539 in 3builddistro-Z.norgo wrote:How to increase the compression ?
To increase the blocksize leads to a better compression
but I'm not sure whether this is the right way.
How is the original SFS compressed ?
Are you using mksquashfs 4.3? If your changes are not too substantial it might be easier to just put them in an adrv.
@Sailor Enceladus
Thank you for quick answer.
It's exactly what I was searching for.
Yes, I'm using mksquashfs version 4.3
Here the different results for comparison:
Created the new SFS by using of mksquashfs and following options:
xz compression (default) + block size 128k (default) = 191 MB
xz compression (default) + block size 512k = 180 MB
xz compression (default) + block size 512k + x86 filter = 172 MB
Once again thank you very much
norgo
Thank you for quick answer.
It's exactly what I was searching for.
Yes, I'm using mksquashfs version 4.3
Here the different results for comparison:
Created the new SFS by using of mksquashfs and following options:
xz compression (default) + block size 128k (default) = 191 MB
xz compression (default) + block size 512k = 180 MB
xz compression (default) + block size 512k + x86 filter = 172 MB
Once again thank you very much
norgo