No tengo acceso a los USB

Asked by Harold Lloys on 2020-07-25

Hasta hace relativamente poco Ubuntu montaba los USB sin problema, aunque si cambiaba de usuario no tenia acceso, debía pincharlo con el otro usuario. Tengo un disco usb compartido al que accedo desde el televisor. Como tenia que iniciar sesión con mi usuario para que el disco se pudiera compartir, cambié el fstab para que el disco se montara automáticamente al iniciar el sistema, sin necesidad de iniciar sesión.
No se si fué a partir de ese momento que los usb ya no se montan solos. me aparecen en el Nautilus sin montar pero no me deja montarlos, ni siquiera manualmente con gnome-disks.
Quisiera que cualquier usuario del equipo pueda pinchar un usb normalmente y tener acceso total.
Gracias

Question information

Language:
Spanish Edit question
Status:
Answered
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Last query:
2020-08-10
Last reply:
2020-08-10
Harold Lloys (haroldllo) said : #1

Nota: para ver los usb recién pinchados tengo que entrar en gnome-disks con sudo y en opciones de montaje, añadirle users al final. De este modo mi usuario tiene acceso al USB, aunque tampoco tengo permisos para desmontarlo, debo hacerlo otra vez desde el gnome-disks con sudo.

Bernard Stafford (bernard010) said : #2

I don't have access to USB
Asked by Harold Lloys on 2020-07-25
Until relatively recently Ubuntu mounted the USB without problem, although if you changed users you did not have access, you had to click with the other user. I have a shared usb disk that I access from the TV. Since I had to log in with my user so that the disk could be shared, I changed the fstab so that the disk mounted automatically when starting the system, without the need to log in.
I do not know if it was from that moment that the usb no longer mount alone. they appear to me in the Nautilus without mounting but it doesn't let me mount them, not even manually with gnome-disks.
I want any user of the equipment to be able to click a usb normally and have full access.
Thank you

Note: to see the newly clicked usb I have to enter gnome-disks with sudo and mount options, add users at the end. In this way my user has access to the USB, although I do not have permissions to unmount it, I must do it again from the gnome-disks with sudo.

Text translated to English.

Bernard Stafford (bernard010) said : #4

¿Cuál es la versión de tu Ubuntu? 20.04?

Harold Lloys (haroldllo) said : #5

Mi ubuntu es el 18.04.
Gracias.

Manfred Hampl (m-hampl) said : #6

What is the output of the commands

uname -a
lsb_release -crid
cat -n /etc/fstab

Harold Lloys (haroldllo) said : #7

lluism@PC-LLUIS:~$ uname -a
Linux PC-LLUIS 4.15.0-112-generic #113-Ubuntu SMP Thu Jul 9 23:41:39 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux

lluism@PC-LLUIS:~$ lsb_release -crid
Distributor ID: Ubuntu
Description: Ubuntu 18.04.4 LTS
Release: 18.04
Codename: bionic

lluism@PC-LLUIS:~$ cat -n /etc/fstab
     1 # /etc/fstab: static file system information.
     2 #
     3 # Use 'blkid' to print the universally unique identifier for a
     4 # device; this may be used with UUID= as a more robust way to name devices
     5 # that works even if disks are added and removed. See fstab(5).
     6 #
     7 # <file system> <mount point> <type> <options> <dump> <pass>
     8 # / was on /dev/sda2 during installation
     9 UUID=f34d0813-891a-4000-b56c-374daa55e974 / btrfs defaults,subvol=@ 0 1
    10 # /boot was on /dev/sda1 during installation
    11 UUID=3377988b-f45e-45d2-a8d0-021a008a9fff /boot ext2 defaults 0 2
    12 # /home was on /dev/sdb7 during installation
    13 UUID=0d22d019-7062-4dbd-a5ac-34dcd09cc2c7 /home ext4 defaults 0 2
    14 # /tmp was on /dev/sdb5 during installation
    15 UUID=d53bfdec-d17d-4ab9-a5b7-7054125afaf1 /tmp ext4 defaults 0 2
    16 # /var was on /dev/sdb6 during installation
    17 UUID=3e28a96d-a402-4ad2-b79f-656ce65d97ac /var ext4 defaults 0 2
    18 # swap was on /dev/sdb1 during installation
    19 UUID=027db9db-3968-40be-8f05-761c581e9e60 none swap sw 0 0
    20 /dev/disk/by-id/usb-WD_My_Passport_0827_575832314136354438414A48-0:0-part1 /mnt/My_Passport auto nosuid,nodev,nofail,x-gvfs-show 0 0
    21 /dev/disk/by-id/wwn-0x5000c50035d8843d-part1 /mnt/wwn-0x5000c50035d8843d-part1 auto nosuid,nodev,nofail,x-gvfs-show 0 0
    22 /dev/disk/by-id/usb-WD_Elements_25A2_575838314133384E364A444B-0:0-part1 /mnt/usb-WD_Elements_25A2_575838314133384E364A444B-0:0-part1 auto nosuid,nodev,nofail,x-gvfs-show,users 0 0
    23 /dev/disk/by-id/usb-Seagate_Expansion+_NA8L7GW3-0:0-part1 /mnt/usb-Seagate_Expansion+_NA8L7GW3-0:0-part1 auto nosuid,nodev,nofail,x-gvfs-show,users 0 0
    24 /dev/disk/by-id/usb-TOSHIBA_TransMemory_C412F52D6CA2C03080051B8C-0:0-part1 /mnt/usb-TOSHIBA_TransMemory_C412F52D6CA2C03080051B8C-0:0-part1 auto nosuid,nodev,nofail,noauto,x-gvfs-show,user 0 0

Manfred Hampl (m-hampl) said : #8

What is the output of the command

ls -la /mnt

Harold Lloys (haroldllo) said : #9

ls -la /mnt

total 8
drwxr-xr-x 1 root root 386 de ju 26 08:20 .
drwxr-xr-x 1 root root 308 de ju 29 12:29 ..
drwxrwxrwx 1 root root 4096 de ge 11 2018 My_Passport
drwxr-xr-x 1 root root 0 de ju 25 18:08 usb-Seagate_Expansion+_NA8L7GW3-0:0-part1
drwxr-xr-x 1 root root 0 de ju 26 08:20 usb-TOSHIBA_TransMemory_C412F52D6CA2C03080051B8C-0:0-part1
drwxr-xr-x 1 root root 0 de ju 25 07:57 usb-WD_Elements_25A2_575838314133384E364A444B-0:0-part1
drwxrwxrwx 1 root root 4096 de ju 12 2018 wwn-0x5000c50035d8843d-part1

Harold Lloys (haroldllo) said : #10

Ahora mismo sólo estan pinchados (y montados correctamente) My_Passport y usb-Seagate_Expansion.
Muchas gracias.

Manfred Hampl (m-hampl) said : #11

You can try two things:

1. Change file access rights in the mount points:
sudo chmod a+w /mnt/*

2. I assume that the parameters in /etc/fstab are not correct, there should be "user" instead of "users" in line 22 and 23, and that parameter is missing in line 20 and 21

And remark: You could have selected shorter names for the mount points. (But they have to be the same in the directory names and in /etc/fstab)

Harold Lloys (haroldllo) said : #12

Hola,
he quitado las tres ultimas lineas del fstab, ya que no se utilizaban, y he borrado las respectivas carpetas en /mnt.
cat -n /etc/fstab
     1 # /etc/fstab: static file system information.
     2 #
     3 # Use 'blkid' to print the universally unique identifier for a
     4 # device; this may be used with UUID= as a more robust way to name devices
     5 # that works even if disks are added and removed. See fstab(5).
     6 #
     7 # <file system> <mount point> <type> <options> <dump> <pass>
     8 # / was on /dev/sda2 during installation
     9 UUID=f34d0813-891a-4000-b56c-374daa55e974 / btrfs defaults,subvol=@ 0 1
    10 # /boot was on /dev/sda1 during installation
    11 UUID=3377988b-f45e-45d2-a8d0-021a008a9fff /boot ext2 defaults 0 2
    12 # /home was on /dev/sdb7 during installation
    13 UUID=0d22d019-7062-4dbd-a5ac-34dcd09cc2c7 /home ext4 defaults 0 2
    14 # /tmp was on /dev/sdb5 during installation
    15 UUID=d53bfdec-d17d-4ab9-a5b7-7054125afaf1 /tmp ext4 defaults 0 2
    16 # /var was on /dev/sdb6 during installation
    17 UUID=3e28a96d-a402-4ad2-b79f-656ce65d97ac /var ext4 defaults 0 2
    18 # swap was on /dev/sdb1 during installation
    19 UUID=027db9db-3968-40be-8f05-761c581e9e60 none swap sw 0 0
    20 /dev/disk/by-id/usb-WD_My_Passport_0827_575832314136354438414A48-0:0-part1 /mnt/My_Passport auto nosuid,nodev,nofail,x-gvfs-show 0 0
    21 /dev/disk/by-id/wwn-0x5000c50035d8843d-part1 /mnt/wwn-0x5000c50035d8843d-part1 auto nosuid,nodev,nofail,x-gvfs-show 0 0

Despues de reiniciar, todo sigue igual, es decir, los dos HDD externos funcionan a la perfección para todos los usuarios, pero no puedo pinchar otro usb. Se monta pero dice que no tengo permisos.

Voy a probar con la opción 1.
Muchas gracias.
Lluis.

Harold Lloys (haroldllo) said : #13

He probado con sudo chmod a+w /mnt/* y sudo chmod a+w /mnt y sigue sin funcionar.

/$ ls -l
drwxrwxrwx 1 root root 78 d’ag. 11 12:50 mnt

/mnt$ ls -l
total 8
drwxrwxrwx 1 root root 4096 de ge 11 2018 My_Passport
drwxrwxrwx 1 root root 4096 de ju 12 2018 wwn-0x5000c50035d8843d-part1

Harold Lloys (haroldllo) said : #14

Hola,
son correctos los permisos sobre fstab?

-rw-r--r-- 1 root root 1393 d’ag. 11 12:43 fstab
-rw-r--r-- 1 root root 1869 d’ag. 11 12:43 fstab.save

Gracias.

Can you help with this problem?

Provide an answer of your own, or ask Harold Lloys for more information if necessary.

To post a message you must log in.