Newsgroup: it.comp.os.linux.iniziare
Titolo: Automount pendrive e hd usb su linux ubuntu mate

E' possibile su ubuntu mate avere l'automount di pendrive e dischi hd
usb? Al loro collegamento sono sempre costretto a montarli
"manualmente". Grazie.


io ho mete "vedi firma" e l'automount è sempre stato attivo senza aver 
fatto nulla
 
 
 
-- 
Linux Mint 18.3 Sylvia  Kernel: 4.13.0-31-generic

 mete
 
mate :-D


quando inserisci l'usb,
eseguendo "dmesg", vedi dalle ultime righe degli errori?

eseguendo "dmesg", vedi dalle ultime righe degli errori?
 
[ 9378.787964] usb 3-2: new high-speed USB device number 6 using
xhci_hcd
[ 9378.929137] usb 3-2: New USB device found, idVendor=1234,
idProduct=5678
[ 9378.929144] usb 3-2: New USB device strings: Mfr=1, Product=2,
SerialNumber=3
[ 9378.929148] usb 3-2: Product: Disk 2.0
[ 9378.929151] usb 3-2: Manufacturer: USB
[ 9378.929154] usb 3-2: SerialNumber: 7209630763170212822
[ 9378.929840] usb-storage 3-2:1.0: USB Mass Storage device detected
[ 9378.930100] scsi host7: usb-storage 3-2:1.0
[ 9379.496376] usbcore: registered new interface driver usbtouchscreen
[ 9379.932615] scsi 7:0:0:0: Direct-Access     VendorCo ProductCode
2.00 PQ: 0 ANSI: 4
[ 9379.933945] sd 7:0:0:0: Attached scsi generic sg5 type 0
[ 9379.934171] sd 7:0:0:0: [sde] 1042504 512-byte logical blocks: (534
MB/509 MiB)
[ 9379.934467] sd 7:0:0:0: [sde] Write Protect is off
[ 9379.934484] sd 7:0:0:0: [sde] Mode Sense: 03 00 00 00
errori (rosso)
[ 9379.934752] sd 7:0:0:0: [sde] No Caching mode page found
[ 9379.934767] sd 7:0:0:0: [sde] Assuming drive cache: write through
stop errori (rosso)
[ 9379.937238]  sde: sde1
[ 9379.939317] sd 7:0:0:0: [sde] Attached SCSI removable disk
 
Ciao

fatto nulla
 
Provando la live in effetti č cosě. Ho modificato qualche file di
sistema "danneggiandolo".
Verifico. Ciao!

da dmesg non vedo errori...
 
controlla anche i log:
 
systemctl --failed
 
e
 
journalctl -b -p err
 
 
per cercare altri errori

facci sapere 
 
Ho provato a copiare
/usr/share/polkit-1/actions/org.freedesktop.udisks2.policy da quello
della live ma non ha sortito alcun effetto.
Qualcuno è in grado di aiutarmi?
Ciao


wrote:

 systemctl --failed
  UNIT                  LOAD   ACTIVE SUB    DESCRIPTION
? runmbbservice.service loaded failed failed LSB: runmbbservice daemon
providing cx
 
LOAD   = Reflects whether the unit definition was properly loaded.
ACTIVE = The high-level unit activation state, i.e. generalization of
SUB.
SUB    = The low-level unit activation state, values depend on unit
type.
 
1 loaded units listed. Pass --all to see loaded but inactive units,
too.
To show all installed unit files use 'systemctl list-unit-files'.
 
systemctl list-unit-files | grep ud
brltty-udev.service                        static  
initrd-udevadm-cleanup-db.service          static  
systemd-udev-settle.service                static  
systemd-udev-trigger.service               static  
systemd-udevd.service                      static  
udev-configure-printer@.service            static  
udev.service                               static  
udisks2.service                            disabled
systemd-journald-audit.socket              static  
systemd-udevd-control.socket               static  
systemd-udevd-kernel.socket                static  
 
-- Logs begin at sab 2018-02-03 16:38:14 CET, end at sab 2018-02-03
17:06:25 CET. --
feb 03 16:38:14 mycomputer kernel: ACPI Error: Needed type
[Reference], found [Integer] ffff9a86a528e798 (20170531/exresop-103)
feb 03 16:38:14 mycomputer kernel: ACPI Exception:
AE_AML_OPERAND_TYPE, While resolving operands for [OpcodeName
unavailable] (20170531/dswexec-461)
feb 03 16:38:14 mycomputer kernel: ACPI Error: Method parse/execution
failed \_PR.CPU0._PDC, AE_AML_OPERAND_TYPE (20170531/psparse-550)
feb 03 16:38:14 mycomputer kernel: usb 3-1: device descriptor read/64,
error -71
feb 03 16:38:15 mycomputer kernel: sd 6:0:0:0: [sdc] No Caching mode
page found
feb 03 16:38:15 mycomputer kernel: sd 6:0:0:0: [sdc] Assuming drive
cache: write through
feb 03 16:38:15 mycomputer systemd-udevd[4087]: invalid key/value pair
in file /lib/udev/rules.d/40-usb_modeswitch.rules on line 1014,
starting at character 50 (',')
feb 03 16:38:15 mycomputer systemd-udevd[4087]: unknown key
'SYSFS{idVendor}' in
/etc/udev/rules.d/60-brother-libsane-type1.rules:17
feb 03 16:38:15 mycomputer systemd-udevd[4087]: invalid rule
'/etc/udev/rules.d/60-brother-libsane-type1.rules:17'
feb 03 16:38:15 mycomputer systemd-udevd[4087]: specified group
'pcscd' unknown
feb 03 16:38:17 mycomputer nvidia-persistenced[5024]: Failed to query
NVIDIA devices. Please ensure that the NVIDIA device files
(/dev/nvidia*) exist, and that user 110 has read and write permissions
for those files.
feb 03 16:38:20 mycomputer systemd[1]: Failed to start LSB:
runmbbservice  daemon providing cx.
feb 03 16:38:21 mycomputer NetworkManager[4869]:
nm_device_get_device_type: assertion 'NM_IS_DEVICE (self)' failed
feb 03 16:38:21 mycomputer wpa_supplicant[6855]: dbus:
wpa_dbus_get_object_properties: failed to get object properties:
(none) none
feb 03 16:38:21 mycomputer wpa_supplicant[6855]: dbus: Failed to
construct signal
feb 03 16:38:22 mycomputer bluetoothd[7408]: Failed to obtain handles
for "Service Changed" characteristic
feb 03 16:38:22 mycomputer bluetoothd[7408]: Not enough free handles
to register service
feb 03 16:38:22 mycomputer bluetoothd[7408]: Error adding Link Loss
service
feb 03 16:38:22 mycomputer bluetoothd[7408]: Not enough free handles
to register service
feb 03 16:38:22 mycomputer bluetoothd[7408]: Not enough free handles
to register service
feb 03 16:38:22 mycomputer bluetoothd[7408]: Not enough free handles
to register service
feb 03 16:38:22 mycomputer bluetoothd[7408]: Current Time Service
could not be registered
feb 03 16:38:22 mycomputer bluetoothd[7408]: gatt-time-server:
Input/output error (5)
feb 03 16:38:22 mycomputer bluetoothd[7408]: Not enough free handles
to register service
feb 03 16:38:22 mycomputer bluetoothd[7408]: Not enough free handles
to register service
feb 03 16:38:22 mycomputer bluetoothd[7408]: Sap driver initialization
failed.
feb 03 16:38:22 mycomputer bluetoothd[7408]: sap-server: Operation not
permitted (1)
feb 03 16:38:29 mycomputer pulseaudio[7985]: [pulseaudio]
backend-ofono.c: Failed to register as a handsfree audio agent with
ofono: org.freedesktop.DBus.Error.ServiceUnknown: The name org.ofono
was not provided by any .service files
feb 03 16:38:29 mycomputer pulseaudio[8158]: [pulseaudio] pid.c:
Daemon already running.
feb 03 16:38:29 mycomputer pulseaudio[8161]: [pulseaudio] pid.c:
Daemon already running.
feb 03 17:06:18 mycomputer kernel: sd 7:0:0:0: [sde] No Caching mode
page found
feb 03 17:06:18 mycomputer kernel: sd 7:0:0:0: [sde] Assuming drive
cache: write through


 
Sul mio sistema ho inserito un file in /etc/udev/rules.d per far 
l'automount delle pendrive.
 
Ciao
Giovanni
-- 
   A computer is like an air conditioner,
   it stops working when you open Windows.
   < 
http://giovanni.homelinux.net/
 >

Giovanni
 
Che sistema č?
puoi indicarmene il contenuto?
Grazie


 
Uso una slackware dove in KDE esiste già qualche programma, ma dato che 
io uso raramente l'ambiente grafico ho inserito lo script che segue.
 
Attenzione che alcune righe risultano spezzate perché troppo lunghe. 
Dove la linea termina con '\' devi ricomporla con quella che segue
 
 
##
##  @(#)media-by-label-auto-mount.rules
##
##  Auto mount memory sticks
 
##  Start at sdb to avoid system harddrive.
KERNEL!="sd[b-z][0-9]", GOTO="media_by_label_auto_mount_end"
 
##  Import FS infos
IMPORT{program}="/sbin/blkid -o udev -p %N"
 
##  Get a label if present, otherwise specify one
ENV{ID_FS_LABEL}!="", ENV{dir_name}="%E{ID_FS_LABEL}"
ENV{ID_FS_LABEL}=="", ENV{dir_name}="usbhd-%k"
 
##  Global mount options
ACTION=="add", ENV{mount_options}="owner,noexec,relatime"
##  Filesystem-specific mount options
ACTION=="add", ENV{ID_FS_TYPE}=="vfat|ntfs", \ 
ENV{mount_options}="$env{mount_options},gid=100,umask=0002,fmask=0113"
 
##  Mount the device
ACTION=="add", RUN+="/bin/mkdir -p /media/%E{dir_name}", \
RUN+="/bin/mount -o $env{mount_options} /dev/%k /media/%E{dir_name}
 
##  Clean up after removal
ACTION=="remove", ENV{dir_name}!="", \
RUN+="/bin/umount -l /media/%E{dir_name}", \
RUN+="/bin/rmdir /media/%E{dir_name}"
 
##  Exit
LABEL="media_by_label_auto_mount_end"
 
##  done


 Ciao
 
forse perche' e' disabilitato il serivio
udisks2.service  disabled
 
?

?
 
Non saprei. Cosa devo fare?
Ciao!

> 

Ho trovato qualche riferimento su internet.
Ho eseguito l'avvio del servizio ma continua a non funzionare:
 
sudo service udev start
sudo service udev status
? systemd-udevd.service - udev Kernel Device Manager
   Loaded: loaded (/lib/systemd/system/systemd-udevd.service; static;
vendor pre
   Active: active (running) since dom 2018-02-04 15:02:52 CET; 12min
ago
     Docs: man:systemd-udevd.service(8)
           man:udev(7)
 Main PID: 4093 (systemd-udevd)
   Status: "Processing..."
   CGroup: /system.slice/systemd-udevd.service
           +-4093 /lib/systemd/systemd-udevd
 
feb 04 15:02:51 mycomputer systemd[1]: Starting udev Kernel Device
Manage
feb 04 15:02:52 mycomputer systemd-udevd[4093]: invalid key/value pair
in
feb 04 15:02:52 mycomputer systemd-udevd[4093]: unknown key
'SYSFS{idVend
feb 04 15:02:52 mycomputer systemd-udevd[4093]: invalid rule
'/etc/udev/r
feb 04 15:02:52 mycomputer systemd-udevd[4093]: specified group
'pcscd' u
feb 04 15:02:52 mycomputer systemd[1]: Started udev Kernel Device
Manager
feb 04 15:02:56 mycomputer mtp-probe[6088]: checking bus 3, device 4:
"/s
feb 04 15:14:24 mycomputer systemd[1]: Started udev Kernel Device
Manager
feb 04 15:14:35 mycomputer mtp-probe[10415]: checking bus 3, device 6:
"/
lines 1-19/19 (END)...skipping...
? systemd-udevd.service - udev Kernel Device Manager
   Loaded: loaded (/lib/systemd/system/systemd-udevd.service; static;
vendor preset: enabled)
   Active: active (running) since dom 2018-02-04 15:02:52 CET; 12min
ago
     Docs: man:systemd-udevd.service(8)
           man:udev(7)
 Main PID: 4093 (systemd-udevd)
   Status: "Processing..."
   CGroup: /system.slice/systemd-udevd.service
           +-4093 /lib/systemd/systemd-udevd
 
feb 04 15:02:51 mycomputer systemd[1]: Starting udev Kernel Device
Manager...
feb 04 15:02:52 mycomputer systemd-udevd[4093]: invalid key/value pair
in file /lib/udev/rules.d/40-usb_modeswitch.
feb 04 15:02:52 mycomputer systemd-udevd[4093]: unknown key
'SYSFS{idVendor}' in /etc/udev/rules.d/60-brother-libsa
feb 04 15:02:52 mycomputer systemd-udevd[4093]: invalid rule
'/etc/udev/rules.d/60-brother-libsane-type1.rules:17'
feb 04 15:02:52 mycomputer systemd-udevd[4093]: specified group
'pcscd' unknown
feb 04 15:02:52 mycomputer systemd[1]: Started udev Kernel Device
Manager.
feb 04 15:02:56 mycomputer mtp-probe[6088]: checking bus 3, device 4:
"/sys/devices/pci0000:00/0000:00:14.0/usb3/3-
feb 04 15:14:24 mycomputer systemd[1]: Started udev Kernel Device
Manager.
feb 04 15:14:35 mycomputer mtp-probe[10415]: checking bus 3, device 6:
"/sys/devices/pci0000:00/0000:00:14.0/usb3/3

 "manualmente". Grazie.
 
Qualche mese fa' ho avuto lo stesso problema con Ubuntu.
Questi sono gli appunti che mi sono preso all'epoca, su come avevo 
risolto il problema:
 
Se l’automount non funziona, per prima cosa:
- entrare in synaptic
- fare un filtro con “udisk”
- per tutti quelli che risultano già installati, reinstallarli
- se non ancora installato, installare “udiskie” ed “udisks2”
- riavviare il PC
- verificare che sia installato e funzionante (da gestione attività) il 
programma “udiskie”.
 
Ciao, Mario
 
 

se ho capito bene... dal live funziona... 
 
guarda se il servizio udisks2 e' avviato 
( e o quali altri servizi sono avviati)
 
vedi lo stato dei servizi con:
 
 
sudo systemctl list-unit-files
 


wrote:

$ sudo systemctl list-unit-files | grep udev
brltty-udev.service                        static  
initrd-udevadm-cleanup-db.service          static  
systemd-udev-settle.service                static  
systemd-udev-trigger.service               static  
systemd-udevd.service                      static  
udev-configure-printer@.service            static  
udev.service                               static  
systemd-udevd-control.socket               static  
systemd-udevd-kernel.socket                static 

sono dal live?
 
dal live c'e' avviato udisks2?

 Ciao, Mario
 
Ho installato e reinstallato i pacchetti ma udiskie non funziona.
Da riga di comando:
 
$ sudo service udiskie status
● udiskie.service
   Loaded: not-found (Reason: No such file or directory)
   Active: inactive (dead)
$ sudo service udiskie start
Failed to start udiskie.service: Unit udiskie.service not found.
 
Infine cos'è "gestione attività" non lo trovo nei pannelli dei menù.
Ciao!
 

o per usare systemd
 
 
sudo systemctl start ...servizio...

 sudo systemctl start ...servizio...
 
:~$ sudo systemctl start udiskie
[sudo] password di computer64bit: 
Failed to start udiskie.service: Unit udiskie.service not found.
 
:~$ sudo systemctl start udisk
Failed to start udisk.service: Unit udisk.service not found
 

 dal live c'e' avviato udisks2?
 
ubuntu-mate@ubuntu-mate:~$ sudo service udisks2 status
● udisks2.service - Disk Manager
   Loaded: loaded (/lib/systemd/system/udisks2.service; disabled; vendor preset:
   Active: active (running) since gio 2018-02-08 14:09:42 UTC; 8min ago
     Docs: man:udisks(8)
 Main PID: 1562 (udisksd)
   CGroup: /system.slice/udisks2.service
           └─1562 /usr/lib/udisks2/udisksd --no-debug
 
feb 08 14:09:42 ubuntu-mate systemd[1]: Starting Disk Manager...
feb 08 14:09:42 ubuntu-mate udisksd[1562]: udisks daemon version 2.1.7 starting
feb 08 14:09:42 ubuntu-mate systemd[1]: Started Disk Manager.
feb 08 14:09:42 ubuntu-mate udisksd[1562]: Acquired the name org.freedesktop.UDi
feb 08 14:16:00 ubuntu-mate udisksd[1562]: Adding read ACL for uid 999 to `/medi
feb 08 14:16:01 ubuntu-mate udisksd[1562]: Mounted /dev/sda1 at /media/ubuntu-ma
feb 08 14:16:30 ubuntu-mate udisksd[1562]: Cleaning up mount point /media/ubuntu
feb 08 14:16:56 ubuntu-mate udisksd[1562]: Mounted /dev/sda1 at /media/ubuntu-ma
ubuntu-mate@ubuntu-mate:~$ sudo service udisks status
● udisks.service
   Loaded: not-found (Reason: No such file or directory)
   Active: inactive (dead)
ubuntu-mate@ubuntu-mate:~$ sudo service udisk status
● udisk.service
   Loaded: not-found (Reason: No such file or directory)
   Active: inactive (dead)
ubuntu-mate@ubuntu-mate:~$ sudo service udiskie status
● udiskie.service
   Loaded: not-found (Reason: No such file or directory)
   Active: inactive (dead)
ubuntu-mate@ubuntu-mate:~$ 
 
 

 
quindi c'e' soltanto udisks2 ?
 
ma sei dal live?

 ma sei dal live?
 
No, non sempre. La uso per le prove.
 

 ma sei dal live?
 
Per la prova si.
 

per quanto riguarda i servizi *udev* e *udisk*
li devi avere abilitati e avviati nel sistema installato come li hai nel sistema live
 
e poi rifare la prova
e vedere gli ultimi messaggi di: dmesg