chmod a freshly mounted external drive to set up writing access

zero picture zero · Dec 14, 2013 · Viewed 58.1k times · Source

I have mounted a external drive at:

# mkdir /mnt/external

and subsequently:

mkdir -p /mnt/external
mount /dev/sdb1 /mnt/external

Now only the root-user has access to write to these folders.

linux-wyee:/home/martin # dir /mnt
drwxr-xr-x 2 root root 4096 13. Dez 22:01 external

How to change this - how to change that all can write to the external drive. I need to change the permissions within the terminal.

chmod 777 /dev/sdb1 /mnt/external or something alike -

Answer

Balaji Perumal picture Balaji Perumal · Dec 14, 2013

Try this first,

umount /dev/sdb1

chmod -R 0777 /mnt/external   

then mount with

mount /dev/sdb1 /mnt/external

or try

chmod -R 0777 /mnt/external