You are not logged in.

#1 2016-12-27 13:03:00

Richard Stockworth
Member
Registered: 2016-12-26
Posts: 13

LDM (Lightweight Device Mounter) permissions

Hi,

I'm trying to get LDM working: https://aur.archlinux.org/packages/ldm/
I executed this command like explained in the man page:

sudo ldm -d -u user -m rwxrwxrwx

With this my usb hard drive is automatically mounted but when I try to access it with a cd command I get the message:

bash: cd: 38DC00D7DC009174/: Permission denied

When I use root I can access the files but can't modify them.
I would like to have automatically read and write access to the files as user when the disk is mounted.

Does anyone know how LDM works?

Last edited by Richard Stockworth (2016-12-27 13:06:41)

Offline

#2 2016-12-27 13:27:10

Docbroke
Member
From: India
Registered: 2015-06-13
Posts: 1,433

Re: LDM (Lightweight Device Mounter) permissions

did you replace "user" with your username?
what is the output of

ls -l "mounted folder"

ldm also supplied systemd service (as per github description), are you using that? if so post "/etc/ldm.conf"

Offline

#3 2016-12-27 17:05:01

Richard Stockworth
Member
Registered: 2016-12-26
Posts: 13

Re: LDM (Lightweight Device Mounter) permissions

Yes I replaced user with my username.

The output is :

d--------- 1 user user 16384 Dec 26 22:32 38DC00D7DC009174

I think it should be drwxrwxrwx, as I have written in my command.

I put this in "/etc/ldm.conf":

MOUNT_OWNER=user
BASE_MOUNTPOINT=/mnt/

(With "user" replaced with my username)

Last edited by Richard Stockworth (2016-12-27 17:05:20)

Offline

#4 2016-12-28 02:49:02

Docbroke
Member
From: India
Registered: 2015-06-13
Posts: 1,433

Re: LDM (Lightweight Device Mounter) permissions

try using octal mask inplace of rwxrwxrwx(probably not supported)  something like, "-m 0755,0644"

Offline

#5 2016-12-28 10:21:28

Richard Stockworth
Member
Registered: 2016-12-26
Posts: 13

Re: LDM (Lightweight Device Mounter) permissions

Now the output is:

d--x--x--x 1 user user 16384 Dec 26 22:32 38DC00D7DC009174

I can access it with the cd command without root now but still can't do anything.

Last edited by Richard Stockworth (2016-12-28 10:22:08)

Offline

#6 2016-12-28 12:39:40

Docbroke
Member
From: India
Registered: 2015-06-13
Posts: 1,433

Re: LDM (Lightweight Device Mounter) permissions

all right, let's try with umask, in place of octal code with

 m -0022

Offline

#7 2016-12-28 15:46:39

Richard Stockworth
Member
Registered: 2016-12-26
Posts: 13

Re: LDM (Lightweight Device Mounter) permissions

I tried with -0022, it says invalid mask, but with just 0022 it's better, it gives me this:

dr-xr-xr-x 1 user user 16384 Dec 26 22:32 38DC00D7DC009174

I think 0022 is supposed to give me rw-r--r--, no?

Last edited by Richard Stockworth (2016-12-28 15:47:28)

Offline

#8 2016-12-28 17:09:22

Docbroke
Member
From: India
Registered: 2015-06-13
Posts: 1,433

Re: LDM (Lightweight Device Mounter) permissions

"m -0022" was typo, I intended to write "-m 0022"
0022 should have given you 755 for dictionary and 644 for files, I don't understand why it gives you 555 (r_xr_xr_x)

Offline

Board footer

Powered by FluxBB