Tuesday, May 26, 2009

How to mount a USB drive with writeable permissions on Linux

I have a Centos Linux server that I have connected at large USB drive to. Once I mounted the USB drive I can read and write files from the server only as the root user.

No matter how I chmod the files on the mounted share I could not get the permissions to stick. I came accross a solution online and figured I would post it here.
The solution was to mount the USB drive with the following command line.

mount /dev/sda1 /mnt/usbdata -o users,umask=000


This allowed all of my users access to the device. Normally I would not want this but in this case I just have the space for extra backups and scratch space.

Hope this helps someone else.

For other Linux articles please click here.

No comments: