Find the answer to your Linux question:
Results 1 to 6 of 6
I have a problem mounting some hfsplus drives. I just need them mounted readonly.(disabling journal is not an option) I did a lot of research and found out that due ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Oct 2013
    Posts
    3

    Post Problems with mounting HFS+ drives


    I have a problem mounting some hfsplus drives. I just need them mounted readonly.(disabling journal is not an option) I did a lot of research and found out that due to changes from kernel version 2.6.37 to 2.6.38 the problem started. (bugs.launchpad.net/ubuntu/+source/util-linux/+bug/734883) Have a look at this link.

    So I tested it with Linux kernel version 2.6.37 and lower and it worked fine as it should.

    Versions above including my version which is 3.2.0-54-generic(ubuntu 12.04) did not work fine with mounting hfsplus images and disks. So I need the hfsplus module from a working version like 2.6.31-14-generic from ubuntu 9.

    I use these commands in this case with a HFS+ DD image. But I did this with other hfsplus physical drives and other images. They all work with kernel 2.6.37 and lower but not with newer versions:

    sudo losetup -d /dev/loop0 sudo losetup /dev/loop0 -o $((512*409640)) /folder/iMac_21.dd

    sudo mount -t hfsplus /dev/loop0 /mnt/hfs mount: wrong fs type, bad option, bad superblock on /dev/loop0, missing codepage or helper program, or other error

    dmesg | tail [84980.380254] hfs: invalid secondary volume header

    I have to add this information to "proof" that the problem is after kernel 2.6.38. Have a look at this. That is a NTFS und HFS+ driver from Paragon.

    "What's new in Paragon NTFS & HFS+ for Linux 8.5: Support for modern Linux Kernels (up to 2.6.3;" paragon-software.com/home/ntfs-linux-per/features.html

    To fix the problem I just copied "/lib/modules/2.6.27/kernel/fs/hfsplus.ko" to my current 3.2.0-54-generic kernel. But that did not work. How do I get the working hfsplus part into my current 3.2.0-54-generic kernel ubuntu 12.04 linux? Or how to fix my kernel to work just like in 2.6.37 ?

    The best hint I did see was this one: bugs.launchpad.net/ubuntu/+source/util-linux/+bug/734883/comments/2

    I hope someone can help me out

    greetings

    krayt

  2. #2
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,572
    There were considerable changes from 2.6.3x kernels to the current 3.x ones that would make it impossible to use many kernel drivers from the 2.6.x branch on newer ones. My suggestion is to try using FUSE (user space) drivers instead as they aren't so kernel-version locked, though they are marginally slower.
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

  3. #3
    Just Joined!
    Join Date
    Oct 2013
    Posts
    3
    ok Rubberman, thanks I will try this

    But I need youre help how to use FUSE for my problem. Can you be a little bit more specific, thank you
    Last edited by krayt; 10-12-2013 at 02:19 PM.

  4. #4
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,572
    If it isn't installed already, install the fuse package. On my RHEL 6.4 clone (Scientific Linux), there is also a fuse hfs driver. I would suspect that your newer system will have that as well as an hfs+ fuse driver. Look in your package manager. Since you haven't said what distribution you are using I don't know what your package manager may be.
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

  5. #5
    Just Joined!
    Join Date
    Oct 2013
    Posts
    3
    I fixed the problem, its described in detail here:
    linuxsleuthing.blogspot.ch/2012/10/christmas-come-early-hfshfs-mounting.html

    Its because -o $((512*409640)) with losetup and mount do not mount into this offset value within hfs+ images...

  6. #6
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,572
    This does make sense. You had an hfs+ disc but you needed to mount a file system within that, hence the need for the offset option. This is not uncommon when mounting a file system contained within a disc image file as well. Sorry that I didn't even consider that issue.. Sigh...
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •