squashfs-tools 4.1 for Windows

Using applications, configuring, problems
Post Reply
Message
Author
disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

squashfs-tools 4.1 for Windows

#1 Post by disciple »

So... you want to extract the filesystem from Puppy's .sfs while running Windows.
Are you mentally unbalanced?! Forget about that Microsoft rubbish and get a real operating system! :lol:

Anyway, I've compiled squashfs-tools 4.1 on Windows, so I might as well post it somewhere in case anyone else is crazy enough to want it.

On WinXP and Win7 I can successfully extract the .sfs from a recent debian-compatible puppy inpu-001.iso (What its name actually is, I can't remember :) )
I'm not sure if it would work with the older .sfs versions used in older puppies. If not, you could try a package from http://fragilematter.blogspot.com/2010/ ... aries.html I used his squashfs-tools 4.0 patch. I have no idea why my build pulled in the cyg-gcc dependency as well.

BTW using his squashfs-tools 4 build I was getting the same error (below) reported in one of the comments there, so I'm interested as to whether it didn't work because 4.0 is not new enough for this .sfs, or whether my build works because of a newer cygwin.

Code: Select all

assertion "root_idx != -1" failed: file "/ext/build/netrel/src/cygwin-1.7.1-1/wi
nsup/cygwin/mount.cc", line 363, function: void mount_info::init()
EDIT
Warning - I think that you will lose permissions and stuff if you extract an .sfs in Windows.
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

User avatar
Terryphi
Posts: 761
Joined: Wed 02 Jul 2008, 09:32
Location: West Wales, Britain.

#2 Post by Terryphi »

Thanks, disciple. Another tool for my toolbox.

I have noted your edit about the permissions issue. Can anyone who has tested it clarify?

donkey
Posts: 1
Joined: Fri 22 Jun 2012, 20:16

thank you very much

#3 Post by donkey »

[quote=desiple]Are you mentally unbalanced?[/quote] :lol: yep
[quote=desiple]Forget about that Microsoft rubbish and get a real operating system![/quote]will do, but not quite yet

tyvm, extracting and playing with tomato firmwares

any extremely helpful advice :?:

calin3
Posts: 6
Joined: Wed 22 Aug 2012, 08:10
Location: Germany

"failed to read the xattr table"

#4 Post by calin3 »

Hello,

when using unsquashfs for WinXP to see the file list of an Android system.sfs, I get this error message:

D:\temp\Android>unsquashfs -ll system.sfs
Parallel unsquashfs: Using 2 processors
Read on filesystem failed because EOF
FATAL ERROR aborting: failed to read the xattr table

Any ideas?

THX
val

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

#5 Post by disciple »

Did you try the squashfs4.0 at the fragilematter link instead?
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

calin3
Posts: 6
Joined: Wed 22 Aug 2012, 08:10
Location: Germany

#6 Post by calin3 »

I can't, as I am unable to compile the source.
If there is a possibility for you to send the 2 .exe's (unsquash & mksquash, plus dll's), please do it, to calin3@gmx.de

THX
val

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

#7 Post by disciple »

You don't need to compile the source - there are binaries there. And you should try the 3.x versions as well.
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

User avatar
8-bit
Posts: 3406
Joined: Wed 04 Apr 2007, 03:37
Location: Oregon

#8 Post by 8-bit »

I just have two questions.
What is the advantage of being able to expand a SFS file in windows?
What would one hope to find inside that was of any use in windows?

calin3
Posts: 6
Joined: Wed 22 Aug 2012, 08:10
Location: Germany

#9 Post by calin3 »

@disciple: thanks, I'll give it a try this evening!
In fact, I downloaded 4.0 yesterday, but saw only source at first glance.

@8-bit: no use at all, you're right!
I must be mentally unbalanced, see posting above :)
Here's the background:
I'm playing with android-x86 on a hp550 notebook. The German keyboard layout has a mistake (missing @). So I need to unsquashfs the android system.sfs, correct a file and mksquashfs it back.
I tried it under a live Ubuntu 12.04, but get Bad magic when trying to unsquashfs system.img.
Just playing around, nothing serious...

calin3
Posts: 6
Joined: Wed 22 Aug 2012, 08:10
Location: Germany

#10 Post by calin3 »

@disciple: it did not work. See results below.

_____________________________________________________________
squashfs_tools 4.1:
D:\temp\Android>unsquashfs system.sfs -ll
Parallel unsquashfs: Using 2 processors
Read on filesystem failed because EOF
FATAL ERROR aborting: failed to read the xattr table

squashfs_tools 4.0:
D:\temp\Android>unsquashfs system.sfs -ll
Parallel unsquashfs: Using 2 processors
0 inodes (0 blocks) to write
2 [main] unsquashfs 6056 _cygtls::handle_exceptions: Exception: STATUS_INT
EGER_DIVIDE_BY_ZERO
19696 [main] unsquashfs 6056 open_stackdumpfile: Dumping stack trace to unsquashfs.exe.stackdump
***contents of stackdump***
Exception: STATUS_INTEGER_DIVIDE_BY_ZERO at eip=0040D91F
eax=00000001 ebx=00000000 ecx=00000000 edx=00000000 esi=00000000 edi=00000000
ebp=0022CC98 esp=0022CC78 program=D:\temp\Android\unsquashfs.exe, pid 4500, thread main
cs=001B ds=0023 es=0023 fs=003B gs=0000 ss=0023
Stack trace:
Frame Function Args
0022CC98 0040D91F (00000000, 00000000, 00000000, 00000000)
0022CCE8 00405AF0 (00000000, 00000000, 00000000, 00000000)
0022CD48 00406B61 (00000003, 007183B8, 00718260, 00000001)
0022CDA8 61006DDA (00000000, 0022CDE0, 610066E0, 7FFD8000)
***End of stack trace***

squashfs_tools 3.4:
D:\temp\Android>unsquashfs system.sfs -ll
Filesystem on system.sfs is (4:0), which is a later filesystem version than I support!

squashfs_tools 3.1:
D:\temp\Android>unsquashfs system.sfs -ll
Major/Minor mismatch, filesystem on system.sfs is (4:0)
I only support Squashfs 3.0 filesystems! Later releases will support older Squashfs filesystems

squashfs_tools 3.0:
D:\temp\Android>unsquashfs system.sfs -ll
Major/Minor mismatch, filesystem on system.sfs is (4:0)
I only support Squashfs 3.0 filesystems! Later releases will support older Squashfs filesystems
_____________________________________________________________

Hints / ideas welcome!

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

#11 Post by disciple »

The message with 4.1 actually sounds like it might not be the complete file. Have you tried downloading/extracting it again?
Have you tried the unsquashfs in Puppy?
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

calin3
Posts: 6
Joined: Wed 22 Aug 2012, 08:10
Location: Germany

#12 Post by calin3 »

The file seems to be complete, as I boot my netbook with Android from it and it runs stable.
Puppy is a good idea, thanks! I'll give it a try under Ubuntu (I have an USB memo stick for a Live Ubuntu 12.04). Under Ubuntu, I tried to mount system.sfs, but it did not work (I saw a file system.sfs, bun not its contents). Now I'll try to unsquash it and copy the contents.

THX!

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

#13 Post by disciple »

Also, on Linux you can use the `file` command to find out what version of squashfs it is supposed to be... or maybe that it is something else entirely (I seem to remember seeing the same file extension used for something else).
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

calin3
Posts: 6
Joined: Wed 22 Aug 2012, 08:10
Location: Germany

#14 Post by calin3 »

I used this weekend's rainy weather to play a little around.
Managed to solve it like this:
- boot Ubuntu 12.04 from USB stick, SD card with Android plugged in
- copy system.sfs from SD-Android to Ubuntu
- unsquashfs system.sfs
- mount system.img (result of unsquashfs)
- edit needed files and save (rw now granted :-)
- mksquashfs back to system.sfs
Now, Android needs a rename system.sfs -> system.img, but
that's another story :-)
Thanks for your ideas!

brokenman
Posts: 25
Joined: Thu 20 Oct 2011, 23:00

Thanks

#15 Post by brokenman »

Not having much luck trying to decompress squashfs using lzma2. I can think of a great reason to want to use mksquashfs on windows. An installer. I am currently building an installer that allows widnows users to build there custom portable linux distro by downloading a base, unpacking it, downloading the user choices (firefox, chrom etc) and then packing everything together. Permissions are not a problem as the boot scripts will sort out the mess.

Post Reply