Announcement

Collapse
No announcement yet.

VFAT USB Drive Mount Permissions

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    VFAT USB Drive Mount Permissions

    [size=10pt]I have a mount permission issue which started after my recent upgrade from Lucid (10.04) to Maverick (10.10), without changing any relevant settings. While the auto-mounting works, my VFAT USB stick solid state drive is mounted with 0755 [USER].root permissions, meaning only root and one user (first one logged on?) can write to the USB drive. Prior to the upgrade it worked as expected, though I never bothered to check the mount permissions.

    lsusb reports it as:

    Code:
      Bus 001 Device 006: ID 1687:6211 Kingmax Digital Inc.
    usb-devices reports it as:

    Code:
      T: Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 6 Spd=480 MxCh= 0
      D: Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1
      P: Vendor=1687 ProdID=6211 Rev=02.00
      S: Manufacturer=Kingmax
      S: Product=USB2.0 FlashDisk
      S: SerialNumber=xxxxxxxxxxxxxxxxxxxxx
      C: #Ifs= 1 Cfg#= 1 Atr=80 MxPwr=200mA
      I: If#= 0 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage
    After is is mounted, /etc/mtab has the following entry for the drive (and mount reports the same information):

    Code:
      /dev/sdc1 /media/disk vfat rw,nosuid,nodev,uhelper=hal,uid=1000,utf8,shortname=
    mixed,flush 0 0
    After some protracted efforts at solving this problem myself, the best solution I could come up with to modify the mount permissions set by Kubuntu's auto-mount system was to create the file '/usr/share/hal/fdi/policy/20thirdparty/20-vfat-config-write-policy.fdi' with the following content:

    Code:
    <?xml version="1.0" encoding="UTF-8"?> <!-- -*- SGML -*- -->
    
    <deviceinfo version="0.2">
    
    <!-- file created by CalDre -->
    <!-- mount vfat with umask 000 to enable write support for all users -->
    
      <device>
        <match key="volume.fstype" string="vfat">
         <merge key="volume.policy.mount_option.umask" type="string">000</merge>
         <merge key="volume.mount_option.umask" type="string">000</merge>
       </match>
      </device>
    
    </deviceinfo>
    Obviously, that was of no avail .... Suggestions?

    #2
    Re: VFAT USB Drive Mount Permissions

    I have had a similar problem I caused by removing a mounted stick.

    Try this:

    WITHOUT the usb stick plugged in, do ls -l /media in a terminal. If you have anything there like "disk" or "pendrive", look at it's permissions. Likely, root will only have access. If this is the case, delete (or move out of the directory if you're unsure of the outcome) the file(s).

    Then plug in your usb stick and wait for the notification widget, mount it, and do ls -l /media again.

    It now should have a file name with permissions and ownership like:

    drwxr-xr-x 10 yourusername root 4096 31.12.1969 16:00 PENDRIVE/

    or something similar and you should be able to access it OK.

    Please Read Me

    Comment


      #3
      Re: VFAT USB Drive Mount Permissions

      Originally posted by oshunluvr
      ...

      WITHOUT the usb stick plugged in, do ls -l /media in a terminal. If you have anything there like "disk" or "pendrive", look at it's permissions.
      [size=10pt]
      I don't.

      ...

      Then plug in your usb stick and wait for the notification widget, mount it, and do ls -l /media again.

      It now should have a file name with permissions and ownership like:

      drwxr-xr-x 10 yourusername root 4096 31.12.1969 16:00 PENDRIVE/

      or something similar and you should be able to access it OK.
      [size=10pt]
      My problem is that other users lack permission to write to it.

      Other than changing the mount options to mount with a umask of '000', another solution would be if the group were set to floppy and the USB drive were mounted group-writable (i.e., a umask of '002'), but this requires modifying an additional mount option and I am content with the drive being world-writable.

      Comment

      Working...
      X