1 |
Michael wrote: |
2 |
> On Wednesday, 10 June 2020 07:59:19 BST Dale wrote: |
3 |
>> Howdy, |
4 |
>> |
5 |
>> Same topic just new question. I use KDE and am wanting to have it so |
6 |
>> the Device Notifier will allow me to mount the drive when I turn it on. |
7 |
> I probably missed in earlier threads, but is this is an externally powered USB |
8 |
> device? |
9 |
> |
10 |
|
11 |
Not USB but eSATA. |
12 |
|
13 |
>> So far, I got it set up and when I turn the drive on and click for it to |
14 |
>> mount it, it asks me for a password. |
15 |
> Where do you "click for it"? |
16 |
|
17 |
The Device Notifier in the KDE panel thingy. I use it to access my |
18 |
cameras, SD cards put in my card reader and even my cell phone. |
19 |
|
20 |
|
21 |
> |
22 |
> |
23 |
>> I type in the password but it mounts it to the wrong place. |
24 |
> Please define "wrong place". |
25 |
> |
26 |
|
27 |
It mounts under /run. I want it mounted under /home. |
28 |
|
29 |
|
30 |
>> If I do it on the command line, it works as expected. |
31 |
> What is expected? |
32 |
> |
33 |
|
34 |
I was expecting it to mount from the Device Notifier just like it does |
35 |
from the command line. |
36 |
|
37 |
>> I have it set up in dmcrypt and fstab. So, command line |
38 |
>> works, KDE's Device Notifier doesn't. |
39 |
> For the avoidance of doubt: |
40 |
> |
41 |
> "command line" = /bin/mount |
42 |
> |
43 |
> "KDE's Device Notifier" = /usr/bin/udisksctl |
44 |
> |
45 |
> There is a difference between the two: |
46 |
> |
47 |
> $ ls -la /bin/mount |
48 |
> -rws--x--x 1 root root 56360 May 11 00:25 /bin/mount |
49 |
> |
50 |
> $ ls -la /usr/bin/udisksctl |
51 |
> -rwxr-xr-x 1 root root 60496 Nov 23 2019 /usr/bin/udisksctl |
52 |
> |
53 |
> |
54 |
> You run mount as root with temporarily elevated privileges and operate on |
55 |
> devices directly via the kernel, but can only mount such block devices if they |
56 |
> have a corresponding /etc/fstab entry - unless you are root. |
57 |
> |
58 |
> You run udisksctl as plain user - it is a userspace command which operates on |
59 |
> the udisks daemon to manipulate mountable devices via D-Bus. The default |
60 |
> mountpoint by udisksctl is under /run/media/<user_name>/LABEL |
61 |
> |
62 |
|
63 |
True but since I'm wanting to mount it under the same /home directory as |
64 |
the user doing the mounting, it shouldn't require any additional |
65 |
privileges. |
66 |
|
67 |
|
68 |
>> It tells me I don't have |
69 |
>> permission to access but it also mounts it in the wrong place. I |
70 |
>> suspect it mounting it in the wrong place leads to the permissions |
71 |
>> error. It mounts under /run. I want it mounted under /home. |
72 |
> You may be able to achieve this via udev rules for the specific UUID of the |
73 |
> disk, or perhaps via a symlink from /home to the /run mountpoint. I haven't |
74 |
> tested this, but you could give it a spin and see what you get. |
75 |
> |
76 |
> PS. You can ignore my earlier questions, no need to answer them. The |
77 |
> structure of your message was perhaps back to front to assist my |
78 |
> understanding. :-) |
79 |
|
80 |
|
81 |
No problem. Sometimes when anyone is writing, it's assumed that |
82 |
everyone else knows the steps that are taken. Usually that is not the |
83 |
case. It's why we always ask for error messages, commands used etc etc |
84 |
etc. ;-) |
85 |
|
86 |
Based on everything I've found with google, I think the Device Notifier |
87 |
is badly limited. It can get to a certain point but it can't go any |
88 |
further. It seems we need a better tool or the current tool needs a |
89 |
little extra programming. I was wanting to avoid the command line part |
90 |
in case something happened to me and someone needed to access a |
91 |
encrypted device. Victor seems to confirm that with his reply. |
92 |
|
93 |
Thanks. |
94 |
|
95 |
Dale |
96 |
|
97 |
:-) :-) |