SELinux enforcing, an external ntfs-3g mount, Samba and Fedora 8
Craig White
craigwhite at azapple.com
Tue Dec 11 15:33:12 UTC 2007
On Wed, 2007-12-12 at 01:45 +1030, Tim wrote:
> On Tue, 2007-12-11 at 07:55 -0700, Craig White wrote:
> > It would appear that mounting ntfs-3g systems is like mounting vfat
> > where the user/group that mounts the files is the owner/group of those
> > files and no amount of chown/chmod will change that.
> >
> > Mount the disk with uid/gid that you want.
>
> Without some sort of additional user mapping between which user is which
> on Windows versus Linux, I can't see how you could avoid that.
----
I don't understand your point.
I know that a fat/vfat mount doesn't understand posix attributes and
they cannot be stored on the filesystem so the uid/gid is declared at
the time of mounting (or if undeclared, root:root because only root can
mount the filesystem unless designated otherwise, i.e. by hal or within
fstab).
Normally, I would point someone to 'man mount' but the parameters for
ntfs-3g aren't included in mount's man pages since it isn't part of the
distribution but I would guess that there is some man page for ntfs-3g.
Guessing (I have read nothing to suggest better), something like this
in /etc/fstab would probably work...
/dev/sdXX /mnt/ntfsdrive ntfs-3g uid=Y,gid=Z,ANY_SELINUX_CONTEXTS 0 0
where XX is the drive letter and partition of the hard drive
(discoverable by typing mount)
where Y is the uid of the desired "user"
where Z is the gid of the desired "user's group"
It seems obvious to me that ntfs-3g is not a good filesystem for
permanent storage but rather a means to use a hard drive on Linux that
is normally used on a Windows computer temporarily.
Craig
More information about the users
mailing list