[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

controlling mount options on FC5?



I want to control some mount options for my USB flash disk (actually,
an MP3 player).  I don't yet know how.

Why?  Here's what I get, just for plugging it in, according to mount:
/dev/sdf1 on /media/disk type vfat (rw,noexec,nosuid,nodev,shortname=winnt,uid=104)

What would I like to change?

- the mount point -- /media/disk is rather nondescript

- the mount options to be kinder to flash memory:
  + noatime
  + async (probably the default), but I'd like to be able to chose sync


Changing the mount point
========================

To change the mount point, I think all I have to do is put a label on
the (vfat) file system.  Fine.  How do I do this using Linux?

There are two very awkward ways that I know.  Are there more
convenient ways?

(a) reformat the file system: mkfs.vfat has a option -n to add a
    volume name

(b) mtools has a program mlabel(1) which can add a label to a vfat
    file system.  Unfortunately, to operate on a device, that device
    needs to be assigned a CP/M-style drive letter in
    /etc/mtools.conf.  For USB drives this is very unsatisfactory
    because every time you plug in the drive, it might be somewhere
    else in /dev.  And don't forget to unmount the drive's file system
    before using mlabel.

This is much easier in MS Windows, but I don't want to stoop to that.



Changing mount options
======================

HAL and friends now do the mounting.  How can I control the mount
options?

There are some hints in the Fedora Core 5 release notes.  In
particular, 7.1 talks about udev rules and 7.7 talks about how fstab
is no longer magically edited.

I don't *think* that udev rules are the right way to control mount
options, but I might be wrong.

Time to figure out hal.  Unfortunately, it seems to be changing
rapidly and the obvious place to look for documentation is silent.
Worse, actually: we are teased with a promise that is not fulfilled.
"man -k hal" lists:
    gnome-mount         (rpm) - Mount replacement which uses HAL to do the mounting
    hal                 (rpm) - Hardware Abstraction Layer
    hal-cups-utils      (rpm) - Halified CUPS utilities
    hal-devel           (rpm) - Libraries and headers for HAL
    hal-gnome           (rpm) - GNOME based device manager for HAL
but none of these man pages seems to exist!  A man section "rpm" does
not exist either.

The relevant control files are probably those with a .fdi suffix.
Locate is my friend.  There seem to be a lot of them in the
directories /usr/share/doc/hal-0.5.7/conf/ and /usr/share/hal/fdi/.
My guess is that these are samples and that to be active they must be
would have to be under /etc/hal/fdi.  Currently that directory has
only empty subdirectories.

.fdi files appear to be in XML.  Not my favourite format for
modifying.  Are there any official tools for creating and modifying
.fdi files?

Is there any documentation to describe the schema?

Googling gets me stuff that seems to be obsolete.  Mostly FC3-era
stuff.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]