Ubuntu's automounter: Configuration

Scott J. Henson scotth at csee.wvu.edu
Fri Sep 29 02:40:29 UTC 2006

Scott Severance wrote:
> Hi all!
> I've noticed many questions on the forums about permissions and other
> problems on removable Windows-formatted disks. Fixing the permissions
> is simple in fstab; the problem is that removable devices have
> changing names. If they were ext3 partitions, they could be mounted
> using a LABEL= device, but that doesn't apply to vfat/ntfs AFAIK. All
> that means that the ideal solution would bypass fstab for removable
> media--while still allowing configuration of mount options.
> 1. What program does Ubuntu use to auto mount?

pmount, udev, hald, and dbus.  pmount does the actual

> 2. I know that pmount is involved in the process, but I haven't been
> able to figure out what program calls pmount (gnome-volume-manager?)
> and how to configure the mount options that program uses. For example,
> I think that Win filesystems should be mounted with umask=000. How do
> I set that up?

I believe its hald-runner from hald. pmount already mounts
it with user which means that the current user owns all files.

> 3. How do I make the automounter use ntfs-3g instead of ntfs?

I don't know.  But I remember that ntfs-3g is a fuse
filesystem.  pmount may not like that.  This is the closest
I can get you to answering that questiion...

> 4. I've messed with udev, but it isn't general enough. I'm looking for
> a change that will affect EVERY vfat/ntfs removable device.

I don't think udev can get that shallow.  udev only cares
about the device and I doubt it even knows what file system
is on it.  hald might know, but it might just tell pmount to
mount it and not care what filesystem is on it.

> 5. I decided to hunt through the gnome-volume-manager source code to
> find out where the mount options get set. Beginning on line 1400 of
> src/manager.c, there are a number of mount options--presumably
> constants. But I'm not a C programmer, and I can't find where those
> constants (or variables?) get set. I've searched through every file in
> the source distribution and I can't find a single occurrence of the
> string "MOUNT_UMASK" aside from the section I mentioned. MOUNT_UMASK
> has to be defined somewhere, but where? Anyone able to find that?

You might want to check /etc/hal/policy/

> 6. Is there any documentation on this somewhere? I couldn't find
> anything useful through Google. I've also asked on the forum--that
> discussion is here: http://ubuntuforums.org/showthread.php?t=262696

See above...

Scott Henson
LCSEE Systems Staff
WVU MAE Undergraduate
Ubuntu User

More information about the ubuntu-users mailing list