| Author |
Message |
Jesse
Joined: 08 May 2005 Posts: 465 Location: Auckland, NZ
|
Posted: Tue 12 May 2009, 01:05 Post subject:
new ext4 detection for puppy linux Subject description: an update for guess_fstype that will indicate ext4 partitions correctly |
|
Barry asked me to have a look at getting guess_fstype to identify ext4 partitions with the tag 'ext4' rather than what it did previously and incorrectly with 'ext3'.
I have had a quick look and I believe I've made the right changes to make the distinction correctly. For those interested in using ext4 with Puppy Linux, and are happy doing terminal window testing, please download the binary and have a go, and please report any correct or incorrect behavior, along with how you expected things to work.
guess_fstype is just a utility to identify a file system type and report back, the types are vfat/ext2/ext3/ext4/iso9660/etc...
example: | Code: | # ./guess_fstype /dev/sda1
ext2 |
| Description |
Source code for guess_fstype, plus binary.
|

Download |
| Filename |
guess_fstype_withext4_test1.tar.gz |
| Filesize |
17.24 KB |
| Downloaded |
507 Time(s) |
| Description |
Just the binary executable file guess_fstype.
|

Download |
| Filename |
guess_fstype_withext4_test1-bin.tar.gz |
| Filesize |
5.08 KB |
| Downloaded |
497 Time(s) |
|
|
Back to top
|
|
 |
Jim1911
Joined: 19 May 2008 Posts: 2353 Location: Texas, USA
|
Posted: Tue 12 May 2009, 23:30 Post subject:
|
|
Jesse,
I have an ext4 partition on my computer and am happy to test your revised guess_fstype in a terminal. However, I have little experience in installations from a .tar file. I have unzipped the file to /root/My Applications, what do I do next to make the command available to execute in a terminal?
Jim
|
|
Back to top
|
|
 |
Jesse
Joined: 08 May 2005 Posts: 465 Location: Auckland, NZ
|
Posted: Tue 12 May 2009, 23:57 Post subject:
|
|
Hi Jim1911,
The .tar file is simply a container for linux files and directories.
When you extracted the .tar file you will have a new directory containing the new guess_fstype executable file.
So you just need to run the new program asking it about your ext4 partition.
So type in something like this in the console (rxvt) | Code: | # cd /root/My Applications
# tar zxvf guess_fstype_withext4_test1-bin.tar.gz
# cd guess_fstype_withext4_test1
# ./guess_fstype /dev/sda1 | The "tar zxvf ..." is the command line instruction to extract the tar file, but you can skip that step as you've already done it.
Don't foget to put the ./ before the guess_fstype, because that means to run the program in the current directory rather than the one on the command line auto search list of directories (the PATH environment variable).
You can of course replace the /dev/sda1 with the device partition node of your ext4 partition, e.g. /dev/sdb1, /dev/sdc3, etc...
Jesse
|
|
Back to top
|
|
 |
Jim1911
Joined: 19 May 2008 Posts: 2353 Location: Texas, USA
|
Posted: Wed 13 May 2009, 00:24 Post subject:
|
|
Jesse,
./guess_fstype /dev/sdb1 correctly identifies my ext4 partition
vfat, ntfs, and ext3 partitions are also correctly identified
Pmount returns error: "unable to mount sdb1"
Do you need further information?
Jim
|
|
Back to top
|
|
 |
Jesse
Joined: 08 May 2005 Posts: 465 Location: Auckland, NZ
|
Posted: Wed 13 May 2009, 00:58 Post subject:
|
|
Hi Jim1911,
Thats great to hear, thanks for your help testing.
Ok so guess_fstype is now good to go for ext4, but now it is something else that is not correctly setup.
When PMount does the action of asking the kernel to mount the ext4 partition it would run this command: | Code: | | mount -t ext4 /dev/sdb1 /mnt/sdb1 | Can you please run this command from the command line?, and copy & paste the error message, so that we may see a more exact error message that will help us figure out the next step to fix it.
It may be that the kernel does not have the ext4 filesystem kernel module loaded or compiled in. But the error code from the mount command may help identify the issue.
Jesse
|
|
Back to top
|
|
 |
Jesse
Joined: 08 May 2005 Posts: 465 Location: Auckland, NZ
|
Posted: Wed 13 May 2009, 01:10 Post subject:
|
|
Hi Jim1911,
You might want to ask the kernel to load the ext4 filesystem module into the kernel, so that it can then mount ext4 filesystems. The command for this is probably: But it might be something different, do a ls of /lib/modules/2.6.29.2/kernel/fs/ext4/*.ko and that will list the names of the modules that are associated with ext4, hopefully just one, use the name without the .ko extension, with the modprobe command.
Jesse
|
|
Back to top
|
|
 |
Joe J
Joined: 13 May 2009 Posts: 7 Location: New Jersey, USA
|
Posted: Wed 13 May 2009, 07:22 Post subject:
EXT4 Test |
|
Here is the error and the dmesg. There is no ext4 directory in /lib/modules/2.6.29.1/kernel/fs. Modeprobe ext 4 says "Module ext4 not found."
By the way, I replaced my guess_fstype with the new one, but when I mouse over the partition icon on the desktop, it still lists it as ext3.
mount: wrong fs type, bad option, bad superblock on /dev/sda5,
missing codepage or other error
In some cases useful info is found in syslog - try
dmesg | tail or so
EXT4-fs: sda5: Filesystem with huge files cannot be mounted read-write without CONFIG_LBD.
EXT4-fs: sda5: Filesystem with huge files cannot be mounted read-write without CONFIG_LBD.
|
|
Back to top
|
|
 |
Jim1911
Joined: 19 May 2008 Posts: 2353 Location: Texas, USA
|
Posted: Wed 13 May 2009, 10:47 Post subject:
|
|
Jesse,
This is the result of the commands you asked me to execute.
# modprobe ext4
mount: wrong fs type, bad option, bad superblock on /dev/sdb1,
missing codepage or other error
In some cases useful info is found in syslog - try
dmesg | tail or so
# dmesg | tail
unionfs: new lower inode mtime (bindex=0, name=cups)
unionfs: new lower inode mtime (bindex=0, name=run)
unionfs: new lower inode mtime (bindex=0, name=cups)
unionfs: new lower inode mtime (bindex=0, name=cups)
unionfs: new lower inode mtime (bindex=0, name=chrome)
EXT3-fs: sdb1: couldn't mount because of unsupported optional features (240).
unionfs: new lower inode mtime (bindex=0, name=.AbiSuite)
EXT4-fs: sdb1: Filesystem with huge files cannot be mounted read-write without CONFIG_LBD.
unionfs: new lower inode mtime (bindex=0, name=run)
EXT4-fs: sdb1: Filesystem with huge files cannot be mounted read-write without CONFIG_LBD.
# dmesg | so
did not return anything
# modprobe ext4
WARNING: Deprecated config file /etc/modprobe.conf, all config files belong into /etc/modprobe.d/.
FATAL: Module ext4 not found.
# cd /lib/modules/2.6.29.2/kernel/fs/ext4/
bash: cd: /lib/modules/2.6.29.2/kernel/fs/ext4/: No such file or directory
#
After this, I renamed the guess_fstype file and copied the same file from the my-applications/guess_fstype_withext4_test1 directory. No change when I executed the above commands again.
My sdb1 partition is ext4 with Kubuntu 9.04 running on it.
Hope this helps,
Jim
|
|
Back to top
|
|
 |
paulh177

Joined: 22 Aug 2006 Posts: 869 Location: ST862228
|
Posted: Wed 13 May 2009, 12:46 Post subject:
|
|
jesse i ran your new guess_fstype (from the bin+src tarball) against an ext4 ptn created with arch linux, and it returns "unknown"
anything further i can do ?
paul
_________________ Want to report a bug or problem? Have a read of this first ...
|
|
Back to top
|
|
 |
Joe J
Joined: 13 May 2009 Posts: 7 Location: New Jersey, USA
|
Posted: Wed 13 May 2009, 13:11 Post subject:
Ext4 |
|
Paul,
Did you run the guess_fstype from within puppy. When I tried running it from within Ubuntu, all my partitions came back as "unknown." However when I ran it in puppy, it correctly identified the ext4 partition (as well as the rest). Joe
|
|
Back to top
|
|
 |
paulh177

Joined: 22 Aug 2006 Posts: 869 Location: ST862228
|
Posted: Wed 13 May 2009, 13:44 Post subject:
|
|
excuse me for being a bufffoon (i can tell the difference between puppy and ubuntu but not puppy 4 and upup a6)
Properly tested with alpha6 against apup alpha6, Jesse's scrip works fine
_________________ Want to report a bug or problem? Have a read of this first ...
|
|
Back to top
|
|
 |
Jesse
Joined: 08 May 2005 Posts: 465 Location: Auckland, NZ
|
Posted: Wed 13 May 2009, 20:16 Post subject:
|
|
Hi,
I had a look into this error:
EXT4-fs: sdb1: Filesystem with huge files cannot be mounted read-write without CONFIG_LBD
Large file size enabled file system can only be
mount if kernel is build with CONFIG_LBD
looks like on a 32bit system, if CONFIG_LBD is not enabled when compiling kernel, ext4 volume will can only be mounted in readonly mode, so re-configue the kernel to enable CONFIG_LBD, then I can mount the ext4 volume successfully.
PS: to enable CONFIG_LBD, go to “Main menu” -> “Enable the block layer” -> “Support for large block devices and files”.
BarryK we need a new kernel option and a fresh compile!
|
|
Back to top
|
|
 |
Jesse
Joined: 08 May 2005 Posts: 465 Location: Auckland, NZ
|
Posted: Wed 13 May 2009, 20:28 Post subject:
|
|
| paulh177 wrote: | jesse i ran your new guess_fstype (from the bin+src tarball) against an ext4 ptn created with arch linux, and it returns "unknown"
anything further i can do ?
paul | Hi Paul,
You have to be running as root user for the guess_fstype application to be able to access hard disks (block devices) directly. This isn't a problem on Puppy Linux, but it is on other distros.
Jesse
|
|
Back to top
|
|
 |
paulh177

Joined: 22 Aug 2006 Posts: 869 Location: ST862228
|
Posted: Thu 14 May 2009, 02:42 Post subject:
|
|
Sorry Jesse I've been unclear as well as dumb ...
I created the ptn using Arch but ran the new guess_fstype from a (full) install of 4.1.2 (dumb) which returned unknown.
Realising my dumbness, I ran it again from a (frugal) install of uPup466, which returned the correct fstype (for all my devices btw - ntfs, ext2, ext3 and ext4 partitions were correctly detected)
paul
_________________ Want to report a bug or problem? Have a read of this first ...
|
|
Back to top
|
|
 |
amigo
Joined: 02 Apr 2007 Posts: 1757
|
Posted: Thu 14 May 2009, 14:39 Post subject:
|
|
Wouldn't 'blkid' do what is wanted and maybe more?
|
|
Back to top
|
|
 |
|