Thursday, April 27, 2017

mount - Root has taken rights



I installed root user of Ubuntu and it is working properly. But the only problem is when I come back to my main account, it says that I cannot unmount or mount any drive, as it's in root's ownership. I tried going into root and changing owner from there but when I change back it reverts quickly.



Please help as I've to go to root every time when I want to mount or unmount something



Thank You



EDIT:




Here is the content of /etc/fstab:



# /etc/fstab: static file system information.
#
#

proc /proc proc nodev,noexec,nosuid 0 0
#Entry for /dev/sda8 :
UUID=f406231f-88c0-4bcc-8f71-84f962ed0306 / ext4 errors=remount-ro 0 1
#Entry for /dev/sda6 :

UUID=5CFA3E3AFA3E112E /media/Games ntfs-3g defaults,locale=en_US.UTF-8 0 0
#Entry for /dev/sda3 :
UUID=AC7C4EC27C4E86D4 /media/OS ntfs-3g defaults,locale=en_US.UTF-8 0 0
#Entry for /dev/sda2 :
UUID=CC70378A703779F2 /media/Recovery ntfs-3g defaults,locale=en_US.UTF-8 0 0
#Entry for /dev/sda5 :
UUID=E6D61DB1D61D834B /media/Storage ntfs-3g defaults,locale=en_US.UTF-8 0 0
#Entry for /dev/sda7 :
UUID=5e23a31f-95c8-4d0b-ab6c-d34e83fa3a23 none swap sw 0 0



Use command with users option



sudo mount -o users /dev/sdXY /mountpoint


The users option gives rights to (un)mount for everybody.



The device node is a special device pseudo-file inside /dev directory. You can find information about your Storage's device node in Disks utility. X and Y are drive letter and partition number respectively.




enter image description here



You should modify your /etc/fstab file to make the changes permanent. Use sudo gedit /etc/fstab, find the line with /media/Storage and add users option to the 4th column:




# /etc/fstab: static file system information.
#
#

proc /proc proc nodev,noexec,nosuid 0 0

#Entry for /dev/sda8 :
UUID=f406231f-88c0-4bcc-8f71-84f962ed0306 / ext4 errors=remount-ro 0 1
#Entry for /dev/sda6 :
UUID=5CFA3E3AFA3E112E /media/Games ntfs-3g defaults,locale=en_US.UTF-8 0 0
#Entry for /dev/sda3 :
UUID=AC7C4EC27C4E86D4 /media/OS ntfs-3g defaults,locale=en_US.UTF-8 0 0
#Entry for /dev/sda2 :
UUID=CC70378A703779F2 /media/Recovery ntfs-3g defaults,locale=en_US.UTF-8 0 0
#Entry for /dev/sda5 :
UUID=E6D61DB1D61D834B /media/Storage ntfs-3g defaults,locale=en_US.UTF-8,users 0 0

#Entry for /dev/sda7 :
UUID=5e23a31f-95c8-4d0b-ab6c-d34e83fa3a23 none swap sw 0 0


Then, you can mount/unmount this drive using



mount /media/Storage      #mount Storage
umount /media/Storage #unmount Storage

No comments:

Post a Comment

11.10 - Can't boot from USB after installing Ubuntu

I bought a Samsung series 5 notebook and a very strange thing happened: I installed Ubuntu 11.10 from a usb pen drive but when I restarted (...