Changing permission/owner to an external USB HDD

Asked by Alberto

Hello Techies,
first meet my system:
Lubuntu 16.04.2 LTS 32 bits from a Live session, daily updated.

I had the great idea of partitioning an external USB HDD (500GB). Its file system was ntfs. Before this I was the owner.
After partitioning 'msdos' and formatting to 'ext4' file system the unit became, and still is, owned by Mr root. So I can't write to it, as I don't have the right permission.

To solve this I got down with the Internet and I learnt (LinuxMint) there should be a way to launch File Manager (here PCManFM) as sudo, but I couldn't do it (sudo PCManFM?).
More, I learnt (itsFoss) there is a way to change the owner using the cli but I feel too newbie to dare do what suggested.
That's why I'm knocking at your door, once again.

How can I change the owner of my external USB HDD so that I can write to it?

Many thanks and regard
Alberto

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
Manfred Hampl
Solved:
Last query:
Last reply:
Revision history for this message
actionparsnip (andrew-woodhead666) said :
#1

What is the output of:

mount; lsb_release -a; uname -a

Thanks

Revision history for this message
Alberto (alby-the-baldy) said :
#2

And you...

mount
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=491120k,nr_inodes=122780,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=102260k,mode=755)
/dev/sda1 on / type ext4 (rw,relatime,errors=remount-ro,data=ordered)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/lib/systemd/systemd-cgroups-agent,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls,net_prio)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=23,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=12851)
fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
mqueue on /dev/mqueue type mqueue (rw,relatime)
/dev/sda3 on /home type ext4 (rw,relatime,data=ordered)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,relatime)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=102260k,mode=700,uid=1000,gid=1000)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)

lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.3 LTS
Release: 16.04
Codename: xenial

uname -a
Linux jalopy 4.10.0-38-generic #42~16.04.1-Ubuntu SMP Tue Oct 10 16:30:51 UTC 2017 i686 athlon i686 GNU/Linux

Regard

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#3

OK and what is the output of:

sudo fdisk -l

Thanks

Revision history for this message
Alberto (alby-the-baldy) said :
#4

Hello, it is:

Disk /dev/sda: 74.5 GiB, 80000000000 bytes, 156250000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x4e5b69f3

Device Boot Start End Sectors Size Id Type
/dev/sda1 * 63 86251519 86251457 41.1G 83 Linux
/dev/sda2 86251520 90451967 4200448 2G 82 Linux swap / Solaris
/dev/sda3 90451968 156248063 65796096 31.4G 83 Linux

Disk /dev/sdb: 465.8 GiB, 500107861504 bytes, 976773167 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x2bdd420e

Device Boot Start End Sectors Size Id Type
/dev/sdb1 2048 976773119 976771072 465.8G 83 Linux

Disk /dev/sdc: 3.6 GiB, 3880452096 bytes, 7579008 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x372141a4

Device Boot Start End Sectors Size Id Type
/dev/sdc1 * 8064 7579007 7570944 3.6G b W95 FAT32

Thanks

Revision history for this message
Alberto (alby-the-baldy) said :
#5

...well Andrew, I guess mine is a very serious problem...!

I tried and connected the USB external HDD to another machine, running Xubuntu but, as you can imagine, nothing happened.
Regard

Revision history for this message
Launchpad Janitor (janitor) said :
#6

This question was expired because it remained in the 'Open' state without activity for the last 15 days.

Revision history for this message
Alberto (alby-the-baldy) said :
#7

Hello actionparsnip (andrew-woodhead666),
I'm stiil having the problem.
I tried and formatted the unit once again but nothing changed.
Can you help me, please?
Thank you

Revision history for this message
Manfred Hampl (m-hampl) said :
#8

Is /dev/sdb (~500GB) the external hard disk with one single partition (/dev/sdb1) using the hard disk?

How do you access that disk?
Did you define a mount point for it?

Revision history for this message
Alberto (alby-the-baldy) said :
#9

Hello Manfred, nice to read you again!
The result of
ls /dev
is sdb, sdb1, because I made just one partition, sdb1 itself.

I access this disk via File Manager and what I see is the lost+found folder, and I can't even read its content: permission denied. I can't write to the unit, neither.

I don't know how to define a mount point for my external HDD, I didn't even know it was necessary.

More...!
I'm using GParted, following this procedure:
1. partition table, msdos
2. format to ext4
3. Apply
Period.

I tried and tried few times but I could not see the way to define the mount point.
Thank you

Revision history for this message
Manfred Hampl (m-hampl) said :
#10

Different from Windows, where each partition gets a new drive letter assigned, in Ubuntu (and other Linux/Unix systems) there is only one single directory tree.
You have to select a point in the directory tree, to which this additional partition is bound, usually it is something like /mnt/partitionname or /media/partitionname

I suggest that you read https://help.ubuntu.com/community/AutomaticallyMountPartitions

This should help you decide on the mount point.
If you need further help, don't hesitate to ask.

Revision history for this message
Alberto (alby-the-baldy) said :
#11

Well Manfred, one piece of information I can add is this:
before I had the good idea to format it it was correctly running, plugged to my system.
Its filesystem was ntfs (former Windows XP formatted) but something that now I don't remember was wrong with ntfs, some data were in some kind of danger. So I copied everything to the central HDD and formatted the external USB HDD unit to solve this problem, by the way to ext4.

More: a 4GB pen drive, formatted when I ran Windows XP, is currently plugged and unplugged to my machine and works properly. I did not determine any mount point myself. I guess Linux did know what to do with it when I plugged it. And with the 500GB external unit when it worked, a few weeks ago.

Is there, during the format procedure, a way to determine the mount point? Something similar to what happens installing the OS, when sda1 and sda3 partition mount points are defined by the user?
Or a way to tell the OS the unit that is being formatted is not going to be root owned but user owned?
Many many thanks

Revision history for this message
Manfred Hampl (m-hampl) said :
#12

What is the output of

cat /etc/fstab

Revision history for this message
Alberto (alby-the-baldy) said :
#13

Here I am.
The result is:

# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
# / was on /dev/sda1 during installation
UUID=7040ca29-cfdb-4ac4-9d9e-efc6671b2281 / ext4 errors=remount-ro 0 1
# /home was on /dev/sda3 during installation
UUID=720924ec-4d7f-4f90-802a-c74746ebfa77 /home ext4 defaults 0 2
# swap was on /dev/sda2 during installation
UUID=bba0b943-b6b3-452c-b591-04b03c958372 none swap sw 0 0
/dev/fd0 /media/floppy0 auto rw,user,noauto,exec,utf8 0 0

I had one idea: what if I start a Live session and try and format the external unit? Is it a chance?

Thanks

Revision history for this message
Manfred Hampl (m-hampl) said :
#14

Re-formatting the hard disk will not change the situation.
You have to decide where you want to mount the external hard disk, prepare the mount point for it and set the right file protection settings.

If you connect the hard disk and try accessing it from nautilus (the file explorer program) and then issue the command

mount | grep "/dev"

what output do you get?

Revision history for this message
Alberto (alby-the-baldy) said :
#15

I hope I got correctly what you asked me!

Where is it correct to put the mount point of an external drive? To me, in this moment the mount point is:
/media/alberto
because if I open Terminal into the 500GB external HDD the prompt is:
alberto@jalopy:/media/alberto/fca77b66-19ca-4f85-9ebe-d90717335ae7$
And if I type:
alberto@jalopy:/media/alberto$ ls
the result is:
E273-ADCA fca77b66-19ca-4f85-9ebe-d90717335ae7
where E273-ADCA is a 4GB USB FAT32 pen drive that I often plug and unplug as I told you;
and:
fca77b66-19ca-4f85-9ebe-d90717335ae7
is my 500GB external HDD.
According to this, and if I understood a bit about Linux, the mount point of both 4GB pen drive and 500GB external HDD should be:
/media/alberto

To answer your question I opened Terminal in the external unit, so:
fca77b66-19ca-4f85-9ebe-d90717335ae7
is my 500GB USB HD external Drive.
The result follows:

alberto@jalopy:/media/alberto/fca77b66-19ca-4f85-9ebe-d90717335ae7$ mount | grep "/dev"
udev on /dev type devtmpfs (rw,nosuid,relatime,size=491456k,nr_inodes=122864,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
/dev/sda1 on / type ext4 (rw,relatime,errors=remount-ro,data=ordered)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
mqueue on /dev/mqueue type mqueue (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
/dev/sda3 on /home type ext4 (rw,relatime,data=ordered)
/dev/sdc1 on /media/alberto/E273-ADCA type vfat (rw,nosuid,nodev,relatime,uid=1000,gid=1000,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,showexec,utf8,flush,errors=remount-ro,uhelper=udisks2)
/dev/sdb1 on /media/alberto/fca77b66-19ca-4f85-9ebe-d90717335ae7 type ext4 (rw,nosuid,nodev,relatime,data=ordered,uhelper=udisks2)

Thanks a lot

Revision history for this message
Manfred Hampl (m-hampl) said :
#16

/media/alberto/hex-code... is used as the mount point when using automatic mount.

Due to the fact that using such name is somewhat inconvenient, it is recommended to use something else if you plan to mount a device periodically.

What do you plan as main purpose for that external hard disk?
If you want to store your music there (for playing on this computer), then a name like /mnt/music could be appropriate. Or something like /mnt/videos for your film collection, or /mnt/backup as basis for creating a backup of all your files to that device.

You have to device on the mount point, create an empty directory with this name, set the file protection on the directory to allow full access to you and finally create an entry in the /etc/fstab file that creates the link from the external disk partition to that mount point.
Eventually you have to correct the access rights settings to the external partition after its first mounting.

Revision history for this message
Alberto (alby-the-baldy) said :
#17

Well, those are good pieces of information, I appreciate!
The main purpose for my 500GB external HDD is backups.
So, using Terminal I put in:
alberto@jalopy:/mnt$
right?
Then:
alberto@jalopy:/mnt$mkdir Buffalo
mkdir: cannot create directory ‘Buffalo’: Permission denied

I must have done some mistake somewhere. I guess I have to log as super user. And how?

Thank you

Revision history for this message
Manfred Hampl (m-hampl) said :
#18

Most of the activities can only be performed with administrative powers, until the admin has defined everything in a way that also non-admin users can do this.

If you want to create a directory below /mnt you need to temporarily gain administrative power, and that is done with the sudo command prefix.

sudo mkdir /mnt/directory_name

You have to be aware that Ubuntu is case sensitive, and so the names /mnt/Buffalo and /mnt/buffalo are not the same.

In the next step you have to adapt the access rights settings on that new directory.
The easiest (although not most secure) way is just setting "sudo chmod 777 /mnt/directory_name"

Finally you have to add an entry for the partition in the config file /etc/fstab

sudo gedit /etc/fstab

and add a line, with suitable contents, maybe something like

UUID=fca77b66-19ca-4f85-9ebe-d90717335ae7 /mnt/your_directory_name ext4 defaults,nofail 0 2

see https://help.ubuntu.com/community/AutomaticallyMountPartitions for some additional options that might be useful (e.g. noauto or user)

Revision history for this message
Alberto (alby-the-baldy) said :
#19

...mumbling...

Revision history for this message
Alberto (alby-the-baldy) said :
#20

Mumbled!
Well I'm learning something new that makes me feel like a techie, despite being a newbie.

I performed, using Terminal:
1. sudo mkdir /mnt/Buffalo
 Buffalo (capital letter) is a new folder.
Buffalo contains lost+found folder.

2. sudo chmod 777 /mnt/Buffalo
Its ower and group are root.

3. sudo nano /etc/fstab, I added the line you suggested:
UUID=fca77b66-19ca-4f85-9ebe-d90717335ae7 /mnt/Buffalo ext4 defaults,nofail 0 2

(I don't have gedit, so I used nano)

[By the way, I'm upset by this: if I use File Manager to get to /etc I can open fstab with Leafpad even if root sudo timeout (I changed it to 2 minutes) has expired!!!]

Now I don't see my 500GB external HDD (Buffalo) anymore. I mean: I can see it in File Manager>Device listed as ST9500325AS but I can't open it.
If I try the result is:
The specified directory 'computer:///ST9500325AS.drive' is not valid.
Buffalo is not listed in File Manager>Places.
I can see it in GParted as /dev/sdb and /dev/sdb1, mounted to /mnt/Buffalo. The column Mount Point eventually appeared, but before the actions I just performed it was not listed in the box.

I still need some help!

Many thanks

Revision history for this message
Alberto (alby-the-baldy) said :
#21

...I tried and unplugged the 500GB Buffalo and now the lost+found folder contained by /mnt/Buffalo is not there anymore.
I tried and switched off and on the system but Buffalo is still alone, unreachable...!

Thanks and byes!

Revision history for this message
Manfred Hampl (m-hampl) said :
#22

1. The file protection settings allow read access for everybody to /etc/fstab, and so you can open it in read-only mode with leafpad in any case, but you will not be able to save any changes.

2. If you boot the computer without the Buffalo drive connected, what is the output of
ls -la /mnt/Buffalo

If you then plug the Buffalo drive into the system, what happens?
What is the output of
ls -la /mnt/Buffalo
then?

And if you reboot the system with the Buffalo drive connected, what output do you get for
ls -la /mnt/Buffalo
?

Revision history for this message
Alberto (alby-the-baldy) said :
#23

Well,
I got the reason of sudo in the string gedit /etc/fstab is that the file has to be chenged. Without sudo it can just be read. Ok!

The result of plugging/unplugging/booting/plugging you suggested follows.

 Before suggested boot, Buffalo plugged, the result is:
alberto@jalopy:~$ ls -la /mnt/Buffalo
total 24
drwxr-xr-x 3 root root 4096 Nov 18 23:18 .
drwxr-xr-x 3 root root 4096 Nov 23 17:27 ..
drwx------ 2 root root 16384 Nov 18 23:18 lost+found

Before suggested boot, Buffalo unplugged, the result is:
alberto@jalopy:~$ ls -la /mnt/Buffalo
total 8
drwxrwxrwx 2 root root 4096 Nov 23 17:27 .
drwxr-xr-x 3 root root 4096 Nov 23 17:27 ..

After suggested boot, Buffalo unplugged, the result is:
alberto@jalopy:~$ ls -la /mnt/Buffalo
total 8
drwxrwxrwx 2 root root 4096 Nov 23 17:27 .
drwxr-xr-x 3 root root 4096 Nov 23 17:27 ..

After suggested boot, Buffalo plugged, the result is:
alberto@jalopy:~$ ls -la /mnt/Buffalo
total 24
drwxr-xr-x 3 root root 4096 Nov 18 23:18 .
drwxr-xr-x 3 root root 4096 Nov 23 17:27 ..
drwx------ 2 root root 16384 Nov 18 23:18 lost+found

Regard

Revision history for this message
Manfred Hampl (m-hampl) said :
#24

ok, just one last step:

with the Buffalo connected issue the command

sucho chown alberto:alberto /mnt/Buffalo

Revision history for this message
Manfred Hampl (m-hampl) said :
#25

Oops, typo error, should of course be

sudo chown alberto:alberto /mnt/Buffalo

Revision history for this message
Alberto (alby-the-baldy) said :
#26

Well, after sudo chown alberto:alberto /mnt/Buffalo I looked for my 500GB external HDD.
1. Using File Manager (PCManFM 1.2.4) I can't see it and I can't see my 4GB USB pen drive, neither.
I can see my two USB drives only in Device, but I cant't open them, The 500GB HDD is listed as ST9500325AS and the result of opening it is:
The specified directory 'computer:///ST9500325AS.drive' is not valid.
The same happens if I try and open the 4GB pen drive.
Mind you, I did not change anything to the pen drive (the pen should be out of my question even if it looks affected by the changes).
(By the way: I've set File Manager to 'mount mountable volumes automatically on program startup'. I don't want to set 'mount removable media automatically when they are inserted' because I want to do this myself.)

2. Using GParted 0.25.0 I can see my two USB drives. The 500GB one (sdb) looks mounted to /mnt/Buffalo. It is possible to unmount.
The pen drive (sdc) looks unmounted and it is not possible to mount it as 'mount' option is shadowed.

3. Using Disks (gnome-disk-utility 3.18.3.1) I can see both devices. The 500GB HDD looks mounted to /mnt/Buffalo and to unmount it
root permission is needed.
The pen drive is unmounted and is mountable. If I mount it (to /media/alberto) I can see it using File Manager and this is the only possible way to see it in File Manager.
I guess this didn't happen before I changed my 500GB HDD's owner.
I think both drives should be listed in File Manager even if unmounted.
I tried to unplug both drives and boot the system, then to plug them back but nothing changed.
To sum up the 500GB external HDD is never available, openable, viewable.

Regard

Revision history for this message
Manfred Hampl (m-hampl) said :
#27

I do not know how you want to "see" the 500 GB drive.
If plugged in it "is" now the /mnt/Buffalo directory.

Revision history for this message
Alberto (alby-the-baldy) said :
#28

Well...
To see means to see the device listed in File Manager/Places, if it is mounted and if it is unmounted.
To see means to see the unit icon on the desktop when the unit is mounted.
Actually I can get to Buffalo only via /mnt/Buffalo, because I know it is there.
(And the pen drive once unmounted is not mountable anymore. GParted does not list it (it should be sdc) and Disks lists it but it states No media, so that I can't open it. And it had disappeared from its mount point, /media/alberto.)
Thank you

Revision history for this message
Manfred Hampl (m-hampl) said :
#29

Gnome makes a difference between mount points /mnt/label and /media/label

If you want to have an extra icon on your desktop, then you have to use /media/Buffalo as mount point instead of /mnt/Buffalo.
Tis has nothing to do with ownership.

I suggest that you
Create a directory /media/Buffalo
edit /etc/fstab and change the mount point from /mnt/Buffalo to /media/Buffalo
and reboot.

Finally check:
Do you then see the extra icon?
Can you write to the USB disk?

Revision history for this message
Alberto (alby-the-baldy) said :
#30

I'll do it soon! Thanks

Revision history for this message
Alberto (alby-the-baldy) said :
#31

Hello Manfred, things get better!
What I have done on nov. 28th, Tue and the following days:
sudo mkdir media/alberto/Buffalo
I changed fstab using nano, replacing the old line with the following one:
UUID=fca77b66-19ca-4f85-9ebe-d90717335ae7 /media/alberto/Buffalo ext4 defaults,nofail 0 2
I removed folder /mnt/Buffalo typing, in /mnt:
sudo rmdir /Buffalo
.
After a few days and some startups:
Buffalo icon is on the desktop.
500 GB Volume is listed as place in File Manager>Places
File properties:
Name---> Buffalo
owner---> alberto
group---> alberto
view content---> Anyone
change content---> only owner
access content---> Anyone
The folder /media/alberto contains, yes, the new folder Buffalo I made, and it also contains folder
fca77b66-19ca-4f85-9ebe-d90717335ae7
that I did not create but I guess Linux has made.
Double click on Buffalo: empty.
Double click on fca77b66-19ca-4f85-9ebe-d90717335ae7: the 500GB HDD starts to be seen.
Once I unmount and mount again the 500GB Volume its name on desktop changes from
Buffalo to
fca77b66-19ca-4f85-9ebe-d90717335ae7.
Yes, I can read it and write to the 500GB Volume, but to me there still is something wrong as the folder /media/Buffalo looks unused by the system.
.
More: after startups the icon of my 4GB pen drive is on the desktop (4GB Volume) and is listed as place in File Manager
But if I unmount it I lose it. It disappeares, it stops to be seen.
Before these last changes I performed to the 500GB unit the pen drive icon was on the desktop (4GB volume) and it was listed in File Manager.
To me it looks like the 500GB unit took the place of 4GB pen drive (this behavior makes me think there is only one place for them in /media/alberto.)
The pen drive was formerly mounted to /media/alberto as folder E273-ADCA.
Disks (gnome-disk-utility 3.18.3.1) lists the pen drive as:
Drive, USB Disk 2.0, /dev/sdc
If I select Mount options a box says the mount point is:
/mnt/usb-_USB_DISK_2.0_19F2896E2F1C-0:0.
But the folder /mnt/usb-_USB_DISK_2.0_19F2896E2F1C-0:0 does not exit. I've set File Manager to show hidden files, you never know.
No sdc1 is listed: but the partition does exist.
GParted 0.25.0 does not list the unit. The only devices it lists are sda (the internal HDD) and sdb (the external USB 500GB HDD).
.
In order to mount and open the pen drive I have to unplug it and then plug it again.
It appears as /media/alberto/E273-ADCA (just the same as before).
Once I unmount it it disappears and so on.
Many thanks!

Revision history for this message
Alberto (alby-the-baldy) said :
#32

Well, I told you what affects my pen drive, which is out of the present question, because while we are trying to solve the problem another problem pops up, and I think they are connected.
Should I open a new question for the pen drive?
Thanks and regard

Revision history for this message
Alberto (alby-the-baldy) said :
#33

Hello Manfred, I hope you didn't give up helping me to solve the remaining part of the problem.
I have one little new piece of information for you.
I plugged my 500GB USB HDD to my second machine (it runs Xubuntu 16.04.2 LTS, daily updated) and I realised that when I use File Manager Thunar 1.6.11 to unmount the unit this does not change its name on the desktop.
The unit is mounted to /media/alberto as
fca77b66-19ca-4f85-9ebe-d90717335ae7
as on the other system.
.
The file /etc/fstab does not mention any unit called
fca77b66-19ca-4f85-9ebe-d90717335ae7
.
(By the way: what gnome-disk-utility 3.18.3.1 says about the mount point is weird...)

Can this help you?
Thank a lot

Revision history for this message
Manfred Hampl (m-hampl) said :
#34

What is now there in your fstab for the USB devices?

Revision history for this message
Alberto (alby-the-baldy) said :
#35

Nice to read you again, Manfred!
Well, the core part of the fstab file of my system running Lubuntu follows:
.
# <file system> <mount point> <type> <options> <dump> <pass>
# / was on /dev/sda1 during installation
UUID=7040ca29-cfdb-4ac4-9d9e-efc6671b2281 / ext4 errors=remount-ro 0 1
# /home was on /dev/sda3 during installation
UUID=720924ec-4d7f-4f90-802a-c74746ebfa77 /home ext4 defaults 0 2
# swap was on /dev/sda2 during installation
UUID=bba0b943-b6b3-452c-b591-04b03c958372 none swap sw 0 0
/dev/fd0 /media/floppy0 auto rw,user,noauto,exec,utf8 0 0
.
To me there is nothing about USB devices. Only floppy is mentioned, isn't it?
.
Do you think the fstab of the system running Xubuntu could help you? In case please do not hesitate to aks.
Regard

Revision history for this message
Manfred Hampl (m-hampl) said :
#36

Sorry, but I am lost what your problem now is.
I thought that you are already able to access the USB hard disk?
And in comment #31 you wrote about changing a line in fstab, but now that entry is no more there?

Revision history for this message
Alberto (alby-the-baldy) said :
#37

Hello Manfred,
Yes, I am already able to access my USB hard disk. I can write to it. That's why in comment #31 I wrote that things are getting better.
I must have made some mess, though, as in fstab file (I quoted it saturday 9th in comment #35) there was not the last line I thought I had added before:
UUID=fca77b66-19ca-4f85-9ebe-d90717335ae7 /media/alberto/Buffalo ext4 defaults,nofail 0 2
.
I apologize for making this mistake, I was sure I had added the line but actually it wasn't there.
I just added the line and rebooted the system.
.
The remaining (small) problem now is:
1. to unmount the 500 GB USB HDD I need to be root as the unit was mounted by another user (dialogue box states).
This happens the very first time I unmount the unit after I plugged it. The following time I unmount the unit authorization is not needed anymore.
I want to solve this, now. Before the change I made to the mount point I did not need to be root to unmount the unit.
2. the pen drive changes its name on desktop the first time I open File Manager, and when I unmount it it disappears. At startup the system does not mount it even if File Manager is set to do so. This did not happen before. But to solve it I'm opening a new question soon.
Many thanks for your help and patience!

Revision history for this message
Manfred Hampl (m-hampl) said :
#38

Try adding "user" to the options part of the related line in the fstab file, changing it from

UUID=fca77b66-19ca-4f85-9ebe-d90717335ae7 /media/alberto/Buffalo ext4 defaults,nofail 0 2

into

UUID=fca77b66-19ca-4f85-9ebe-d90717335ae7 /media/alberto/Buffalo ext4 defaults,user,nofail 0 2

Can you then unmount the disk with user rights?

Revision history for this message
Alberto (alby-the-baldy) said :
#39

Hello Manfred,
I changed the fstab as you suggested but unfortunately I'm still asked to log as root to unmount the 500GB USB unit.
But I got an interesting (and weird) hint!
Looking for a solution I tried and:
1. unmounted the unit as root,
2. unplugged the unit,
3. rebooted the system. And I got surprised, because the system blocked to the part of the power on self test in which it tests the memory.
The POST displayed:
1. Bios (ok)
2. Motherboard (ok)
3. Main processor (ok, it's an old machine)
4. Memory test. No numbers, nothing happens! I tried and rebooted pushing the button, nothing, the system stopped to memory test.
So I plugged the 500GB USB unit, pushed the button and the POST was preformed properly.
I tried this procedure 3 o 4 times to be sure there is a connection between the fact that the unit is plugged and the POST. The result was the same: unit unplugged the POST stops, unit plugged the POST is preformed properly and I can access the USB unit.
I have never happened something like this!
Thanks

Revision history for this message
Manfred Hampl (m-hampl) said :
#40

This is strange, and to me this indicates a hardware or BIOS problem.

Revision history for this message
Alberto (alby-the-baldy) said :
#41

Hello! This was yesterday. Today everything works properly and I don't know why.
There still is the problem that the first time in a session I unmount the 500GB USB volume I am asked the password. The following times this does not happen anymore.
Thanks

Revision history for this message
Manfred Hampl (m-hampl) said :
#42

Do you usually have the USB disk connected when booting the computer, or do you usually plug it in only later?

Revision history for this message
Alberto (alby-the-baldy) said :
#43

Well, the unit is usually plugged to the machine. I unplug it when the Lubuntu machine is off and plug it to the Xubuntu one. And viceversa.
The machine starts up with the unit already plugged.

Revision history for this message
Best Manfred Hampl (m-hampl) said :
#44

Well, that is quite clear then.
During boot time you are not logged in, and the USB disk consequently is mounted with root rights and not your user rights.
Only if you (re-)plug it later when you are logged in, the system can know that you should own it.

Revision history for this message
Alberto (alby-the-baldy) said :
#45

Ok Manfred I guess this solves my problem.
Many many thanks

Revision history for this message
Alberto (alby-the-baldy) said :
#46

Thanks Manfred Hampl, that solved my question.