mount usb: same username different uid: problem

Uwe Brauer oub at mat.ucm.es
Mon Jun 18 06:35:31 UTC 2012


>> On Sat, 16 Jun 2012 19:19:42 +1000, Basil Chupin
>> <blchupin at iinet.net.au> wrote:

   > On 16/06/12 00:00, Uwe Brauer wrote:
   >> 
   >> Uwe Brauer

   > You don't say which desktop environment you are using.

As I figured out it has nothing to do with the desktop environment.

   > Nevertheless, I don't think that it is a matter of uid being 1000 or
   > 1002 but PERMISSIONS, and who owns the USB device.
Well yes and no. The standard mount command mounts the USB
system (with a jfs file system) according to the uid, and
gid of the system!

There seems to be a patch for extX system which allows to
specify the uid and gid of the usb disc.
https://lwn.net/Articles/497106/
alas as far as I can seems not to be standard, yet.



   > Mount the device and in a terminal as root - oops, Ubuntu doesn't have
   > 'root' - that is, using "sudo" issue these 2 commands in sequence:

   > sudo chown -R oub.users /dev/<USB-device> [ENTER]

   > then

   > sudo chmod -R u=rwx,g=rwm o= /dev/<USB-device> [ENTER]

Right but I consider this solution as being cumbersome
especially if there are a lot of files.

Another solution would be to use 
sudo rsync 

If rsync had an option to specify uid and gid on the target
system which I still don't know

Uwe Brauer 





More information about the ubuntu-users mailing list