[PLUG] iPod with Linux?

AthlonRob athlonrob at axpr.net
Mon Jul 4 06:35:37 UTC 2005


John Jordan wrote:
> I did tail -f /var/log/messages, then unmounted, unplugged, and 
> plugged it back in. The messages were identical to what I sent 
> earlier, that is, the last line still says "localhost kernel: HFS-fs: 
> Filesystem is marked locked, mounting read only."

Okay, I'm relatively certain now you *are* using the proper driver.  I'm
also relatively certain the filesystem being marked locked is the issue
at hand.... or at least *one* issue at hand.  :-)

I have absolutely zero experience with HFS and what utilities are
available for it, and my quick google search didn't turn up much of use.
 You may need to google some more.

If you dig in to the kernel source, you'll see in fs/hfs/mdb.c:
        if ((attrib & cpu_to_be16(HFS_SB_ATTRIB_SLOCK))) {
                hfs_warn("HFS-fs: Filesystem is marked locked, mounting
read-only.\n");
                sb->s_flags |= MS_RDONLY;
        }

...which is where our issue sits.  That if is happening.  I'm guessing
HFS_SB_ATTRIB_SLOCK is true here.  So it seems there's some sort of a
property an HFS filesystem can have that "soft locks" it.  How do we
un-lock it?  I don't know.  That's where Google should come in and help.
 :-)

Oh, a thought just occured to me.  What are the odds you're mounting the
OS partition (which would likely be marked read-only) instead of the
data/music partition on the iPod?  No, wait, the partition you're
mounting was reported to be 60GB in size, wasn't it?

While I wouldn't recommend it, you could potentially modify the kernel
source, commenting out that if block, and see what happens from there.
If that soft lock is just one of those "save the user from himself"
locks I say throw it away.  :-)

I wonder if other pluggers here have experience with HFS?  Maybe
somebody could shed some light on this soft lock issue?

Rob



More information about the PLUG mailing list