Software & hardware support > Newbie questions

[SOLVED] permissions locked on one external drive


Hello, just installed and everything's great; just this one issue. 4 x ext4 externals attached, but one is locked. Am not very tech, and have taken a run at this kind of issue previously, and failed, so if I can ask your advice about how to free up the drive, without formatting (8tb). Thanks.

A bit of care is needed here as you haven't provided a lot if information about this drive.

The most important question is the file system - was this drive formatted under a version of windows or linux?

If you're not sure, connect the drive and wait for it to be recognised then type
--- Code: ---df -Th
--- End code ---
and copy / paste the output.

When you say 'permissions', do you mean that you cannot access the files at all? If you mount the drive and right click on a file and go to properties/permissions does it show your user name anywhere? If so, what permissions does it show.

If it was simply a user ID issue, and if this were a drive formatted ext4 in linux and it just contained files/data then I would run
--- Code: ---sudo chown -R yourusername:yourusername /media/yourusername/UUID of drive/
--- End code ---

In other words use sudo to change the user name and group recursively to your user ID for all files on that drive.

If the files all show your ownership, but are for example all Read Only then you'll be needed to use chmod to change them to allow you to work with them.
--- Code: ---sudo chmod -R 644  /media/yourusername/UUID of drive/
--- End code ---
This assumes none of these are executables.

If you are not sure please come back with more information/questions rather than just running commands blind. Please note that the above makes certain assumptions about your system and that you use these suggestions at your own risk.

Hi @bin and thank you very much for your response. Sorry I didn't include that the drive was formatted as ext4 on linux. Can copy/paste from, but not to, or save to. External drives are always connected, via usb hub.

watership@watership:~$ df -Th
Filesystem     Type      Size  Used Avail Use% Mounted on
udev           devtmpfs   16G     0   16G   0% /dev
tmpfs          tmpfs     3.2G  1.9M  3.2G   1% /run
/dev/nvme0n1p2 ext4      907G  152G  710G  18% /
tmpfs          tmpfs      16G  1.4M   16G   1% /dev/shm
tmpfs          tmpfs     5.0M  4.0K  5.0M   1% /run/lock
/dev/nvme0n1p1 vfat      300M  8.4M  291M   3% /boot/efi
tmpfs          tmpfs     3.2G   92K  3.2G   1% /run/user/1000
/dev/sda1      ext4      7.3T  6.9T   31G 100% /media/watership/fe4d8c32-5779-4104-b560-28e0655a95e3
/dev/sdb1      ext4      3.6T  3.4T   42G  99% /media/watership/36cb7c6c-19ed-4db0-af7b-94bd0a3a99dd
/dev/sdc1      ext4      3.6T  3.4T   36G  99% /media/watership/4tb ext4
/dev/sdd1      ext4      1.8T  1.7T   42G  98% /media/watership/2tb_ext4
/dev/sde1      ext4      2.7T  2.6T   40G  99% /media/watership/3tb ext4 drive
... drive isn't at 100%; 32gb free on sda1

sudo blkid
/dev/sda1: UUID="fe4d8c32-5779-4104-b560-28e0655a95e3" BLOCK_SIZE="4096" TYPE="ext4" PARTLABEL="MyBookNEW" PARTUUID="d6301d22-f8b6-41e6-8e00-79522e80f916"

sudo chown -R yourusername:yourusername /media/yourusername/UUID of drive/
sudo chown -R watership:watership /media/watership/fe4d8c32-5779-4104-b560-28e0655a95e3/
Big stream of filenames and @read-only file system after each one.

sudo chmod -R 644  /media/yourusername/UUID of drive/
sudo chmod -R 644 /media/watership/fe4d8c32-5779-4104-b560-28e0655a95e3/
Same stream of filenames etc.

tried saving backup txt file again ...
error opening *****: read-only file system ... the file on disk may now be truncated!

sudo chown -R watership:watership /home/watership
logged out; no change
sudo chown -Rc watership:watership /home/watership
logged out and back in ... worked, but, soon as try a different text file, error's back, and above command not working.

tested using caja/admin command, to try delete something/see if any messages ... didn't work
clicked on unmount, then clicked on drive to remount ... able to delete item
(not sure if issue with caja/admin that I installed?)

But 'truncated' issue continues when try to backup original text file.

Looked at Disks and have tried to modify ownership recursively, but error message.

It's fixed! Thought to try Disks, check filesystem ... damaged. Did repair and it's working now. Have done a reboot, and still working.  :)


[0] Message Index

Go to full version