[GTALUG] Can't rename files in Files

Aruna Hewapathirane aruna.hewapathirane at gmail.com
Sun Mar 7 09:09:18 EST 2021


Hello Chris,

> On 2021-02-19 7:24 a.m., Chris Aitken wrote:
>
> Now I can't access the folder contents. It seems by using a '?' in a file name, I've caused a problem. It was never an issue until now. I use this external SATA drive in USB docking station, and go back and forth >
> between ubuntu and W10 computers, to make backups.
>

Short Story:
1 - Find type of filesystem
2 - If EXT use fsck
3 - if FAT use dosfsck

Long Story:
First I would try to find out the type of file system you have on your
external SATA drive. Since you go back and forth with it between
Ubuntu and Win10 to make backups.

Typing df -Th into a shell will show you what you need. My system is
shown below. The second column 'Type' is what we want.

Filesystem     Type      Size  Used Avail Use% Mounted on
/dev/sda5      ext4       20G   15G  4.2G  78% /
udev           devtmpfs   10M     0   10M   0% /dev
tmpfs          tmpfs     1.6G  9.1M  1.5G   1% /run
tmpfs          tmpfs     3.8G  5.0M  3.8G   1% /dev/shm
tmpfs          tmpfs     5.0M  4.0K  5.0M   1% /run/lock
tmpfs          tmpfs     3.8G     0  3.8G   0% /sys/fs/cgroup
tmpfs          tmpfs     769M  8.0K  769M   1% /run/user/120
tmpfs          tmpfs     769M   24K  769M   1% /run/user/1000
/dev/sdb6      ext4      194G   29G  156G  16%
/media/aruna/200f9328-ae6b-4fe9-9d94-24ffd391bbe9
/dev/sdb5      ext3      201G   22G  169G  12%
/media/aruna/3c8fce17-5948-43e7-9662-921e65c7faa7
/dev/sdb3      ext4       17G   15G  1.6G  91% /media/aruna/back-up
/dev/sdb2      ext4      246G   41G  194G  18% /media/aruna/kernel-stuff
/dev/sdb1      ext4      246G   21G  213G   9% /media/aruna/Ubuntu 12.04.4 L
/dev/sda2      fuseblk   213G  188G   25G  89% /media/aruna/OS

If it is a ext3 or ext4 type filesystem you can try and use fsck to
repair any filesystem errors.

MAKE CERTAIN THE FILESYSTEM IS NOT MOUNTED WHEN YOU DO THIS. YOU CAN
CAUSE REAL AND SERIOUS DAMAGE
IF YOU RUN fsck WHILE YOUR DISK/PARTITION IS MOUNTED. Just be careful :-)

Sometimes more than one error can be found on a filesystem. In such
cases you may want fsck to automatically attempt to correct the
errors.
This can be done with:

# fsck -y /dev/sda ( I am using /dev/sda as a example please
substitute your details here )

Hopefully this will resolve and repair any file system errors.

If your filesystem says FAT32 or it is some FAT fiel system. Then we
have to use dosfsck as shown below.

sudo dosfsck -w -r -l -a -v -t /dev/sdc1 ( I am using /dev/sda5 as a
example please substitute your details here )

-w means write to disk immediately.
-r means to do disk check interactively (ask you what to do to when
encountering errors). On newer versions of dosfsck this is the
default.
-l means to list the filenames processed.
-a means automatically fix errors. Do not use it, if You want to have
more control over fixing possible errors.
-v means verbose mode. Generates slightly more output.
-t means mark unreadable clusters as bad.

If you want to be sure not to lose your data, create a backup of the
source device first.

Good Luck and happy trouble shooting :-)

Aruna



>
> On 2021-02-19 6:10 a.m., Chris Aitken wrote:
>
> Hi,
> I can't rename files on my external drive in Ubuntu. I've tried a few things that people have posted about Nautilus. But this is not Nautilus - the application is just called 'Files'.
> Chris
>
>


More information about the talk mailing list