[NTLUG:Discuss] Re: mounting drives from other os -- try Captive (if you can fool Windows into creating a portable NTFS)
Bryan J. Smith
b.j.smith at ieee.org
Wed Sep 22 13:19:40 CDT 2004
On Wed, 2004-09-22 at 13:14, MontyS at videopost.com wrote:
> Greetings.
> Does any one know of an application (freeware/shareware or commercial) that
> allows the Linux user to mount NTFS or HFS+ firewire and/or usb drives to
> Linux? The mount must be read/write to native format, must be able to see
> relatively large drives (250gig+) and must be STABLE.
- NTFS is _tied_ to a specific NT installation, _not_ for portables
Because NTFS relies on information in the SAM (Systems Accounting) part
of the registry, NTFS is _not_ for use on portables -- even with other
NT platforms. Supposedly the LDM disk label (aka "dynamic disks" --
instead of the BIOS/DOS Primary/Logic disk label aka "standard disk") in
NT 5.x+ (2000, XP, 2003) solves this issue (among other issues dealing
with the registry, geometry, etc...), but I have not seen Microsoft
enable such yet. I.e., Microsoft does _not_ let you create the LDM disk
label on removable media** (the last time I checked), but that might
have changed in a recent service pack or fix (anyone?).
[ **NOTE: Microsoft won't even let you use an LDM disk label for
portables. BTW, "disk label" is also known as the _format_ of a
"partition table." Don't confuse "disk labels" and "filesystems." Many
people do and don't understand the difference between LDM and NTFS. ]
NT 6 "Longhorn" probably will require the LDM disk label, to resolve the
limitations of FAT32, various geometry issues (e.g., buggy BIOSes as
we've seen with dual-booting Linux 2.6), etc... among other things. You
_may_ be able to "fool" NT 5.x into thinking it is a fixed disk. I've
never tried that.
Again, if I didn't make this clear, NTFS is _not_ considered "portable"
by Microsoft itself. In a nutshell, Microsoft designed the SAM and NTFS
without thinking things through. NT 5.x uses the LDM disk label to
store SAM information for NTFS filesystem in hidden sectors outside the
filesystem.
- Linux-LDM/NTFS support, user-space driver w/SAM reader
Linux supports both the LDM disk label and NTFS. Like with even a
_native_ NT system, NTFS write support is still considered a "poor
pracice" because of the SAM tie-in -- _unless_ you use "dynamic disks."
Linux-LDM support is getting better (especially as the last 12-18
months) at reading the SAM information so NTFS filesystems can be safely
_written_ to like NT 5.x+. Again, you _must_ be using an LDM disk label
(aka "dynamic disks"). The issue is with NT-NTFS itself, not Linux.
Fortunately, there _is_ now a "user space" NTFS filesystem driver for
Linux that reads the NT SAM _directly_. It is called "Captive":
http://www.jankratochvil.net/project/captive/
Unfortunately, if it is portable disk, then it can't access the SAM.
And then we're back to "fooling" NT 5.x to create a LDM disk label on
it.
- Universal Device Format (UDF)
As always, UDF (Universal Device Format) should be a consideration
instead. Unlike ISO9660, it is also built for read/write access (in
addition to being pre-mastered, like ISO966O). It works for generic
block devices (fixed discs/hard drives) as well.
Unfortunately, the last time I checked, no version of NT 5.x includes
write support for UDF (only read-only). You'll have to purchase it as
an add-on for $50+.
- FAT32
FAT32 is used for portable drives. It's size is typically limited to
128GiB (137GB), so you'll need to break it up. Geometry translation for
FAT32 above 128GiB is not universal, so be careful. You can _easily_
drop a filesystem if you access a FAT32 disk in a system that does not
use the same >128GiB geometry. And unlike a _real_ filesystem were you
can mark it "read-only," FAT32 does not offer such so all it takes is 1
access to toast it.
- HFS+
As far as HFS, Linux 2.2+ seems to support it well. Not sure what the
geometry limitations of HFS is. I'm fairly certain I've created >128GiB
HFS filesystems on MacOS X.
I believed HFS+ was just HFS with full data journaling (meta-data now?)
and a few other goodies.
> Our production side is unix based. What I am trying to acheive is the
> ability to mount a mac or pc firewire drive onto a linux box, then export it
> via nfs for read/write operations.
*IMPOSSIBLE* (kernel-wise)
Kernel NFS _requires_ an _inode_ filesystem. FAT32 and NTFS are FAT
filesystems. I'm not sure about HFS (I think it's inode?), but it's
probably incompatible with kernel NFS. JFS and ReiserFS were for the
longest time as well.
You can certainly try to use user-space NFS. But it is generally a
headache with severe limitations. You'd probably be better off
exporting SMB -- of course, smbfs is _only_ available on Linux. And
even then it has codepage/case issues (unless you enable the extensions,
which can be native SMB client -- i.e., Windows -- incompatible).
> I have played with the HFS+ and NTFS kernel modules, but there are quite a
> few caveats that accompany them, mostly when it comes to writing.
A common misconception is that Linux doesn't have "good" NTFS support.
That's not true at all! The problem is NTFS itself and the SAM-registry
tie-in that plagues even _native_ NT platforms. Otherwise, Linux's
support of LDM is very good now, just like NT 5.x (although not quite as
perfect), and solves the NTFS issues _if_ it is a "fixed" disk _and_ it
has an LDM disk label.
The problem is the fact that the disks are removable. Again, NT 5.x
does _not_ allow the creation of the LDM disk label or NTFS on portable
discs.
> Google has not been forthcoming.
Because it is rather impossible with NTFS in general.
> Any thoughts?
UDF.
--
Bryan J. Smith b.j.smith at ieee.org
------------------------------------------------------------------
"Communities don't have rights. Only individuals in the community
have rights. ... That idea of community rights is firmly rooted
in the 'Communist Manifesto.'" -- Michael Badnarik
More information about the Discuss
mailing list