1

Am the administrator of my Ubuntu system. Recently I added a new user account. But when ever the user tries to access or open the 'Volumes'(Drives where movies, songs and other files are stored) it asks for the Administrator's password. I created the user account to my other family members and I don't want to tell them my password.

So is it possible to allow them to access the Volumes without asking Administrator's password ?


UPDATE 1:

Ubuntu was installed alongside Windows in my system. I will provide a screenshot of the Volume details -

enter image description here

UPDATE 2:

enter image description here

TuKsn
  • 4,370
  • 2
  • 26
  • 43
TomJ
  • 566
  • 2
  • 8
  • 20

1 Answers1

2

First install sudo apt-get install gnome-system-tools

Than open the account manager:

enter image description here

Click on "Manage Groups" then create a new group and add your two users:

enter image description here

(if you don't want to install a GUI for groups you can create a new group from command line)

Now we have to change the /etc/fstab run:

gksu gedit /etc/fstab 

and add for the first Volume (at the end of the file):

/dev/sda5 /media/Volume1 ntfs rw,auto,user,exec,nls=utf8,dmask=027,fmask=137,gid=1002,uid=1000 0 2

"gid" must be the group id from your new group.

"dmask" are the permissions for the directories:

  • 0 at the beginning is for the owner (in this case the user with the id 1000 should be your admin user) he has all permissions ( 0 -> read, write and execute)
  • 2 as the second digit is for all users in the group 1002 ( 2 -> read and execute)
  • 7 at the end is for others ( 7 -> no permissions )

"fmask" are the permissions for the files: 1 -> read and write 3 -> read only 7 -> no permissions

For more info look also at this answer https://askubuntu.com/a/54324/265974


Edit:

Mountpoints for the other partitions:

/dev/sda6 /media/Volume2 ntfs rw,auto,user,exec,nls=utf8,dmask=027,fmask=137,gid=1002,uid=1000 0 2
/dev/sda7 /media/Volume3 ntfs rw,auto,user,exec,nls=utf8,dmask=027,fmask=137,gid=1002,uid=1000 0 2
TuKsn
  • 4,370
  • 2
  • 26
  • 43
  • Will the user be able to delete or add files, if I did like you said ? – TomJ May 29 '14 at 18:12
  • @Tom Ok i changed it now the user in the group can only read files. – TuKsn May 29 '14 at 20:13
  • What you mean by this - "Click on "Manage Groups" then create a new group and add your two users:" ? Who are the 2 users ? Is it the administrator and the user ? – TomJ May 30 '14 at 14:57
  • You can add your admin but it is not necessary because if he has the uid 1000 he as full access to the partition. – TuKsn May 30 '14 at 16:40
  • I said as you did. But now the user is not able to access 2 partitons - sda5 and sda6. Why did this happened ? – TomJ Jun 02 '14 at 14:26
  • When the user clicks on the other 2 partitions, then password is asked. – TomJ Jun 02 '14 at 15:14
  • Ok seems to be right but i gave you only an example for 1 partition, you have to add the others same way, i will edit my answer. – TuKsn Jun 02 '14 at 15:37