[SOLVED] USB HardDrive automount permission set drwx --- ---

Quick to answer questions about finding your way around Linux Mint as a new user.
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions use the other forums in the support section.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
PortUnion

[SOLVED] USB HardDrive automount permission set drwx --- ---

Post by PortUnion »

Hi,

I am new Linux Mint guy here, I love Linux Mint, every runs just fine!
Just have a quick question please:

my LaCie 500G USB Ext HardDrive can be auto-mounted to the /media/LaCie

The permission is like this:
portunion@desktop /media $ ls -l
total 192
lrwxrwxrwx 1 root root 6 2010-04-10 14:56 cdrom -> cdrom0/
drwxr-xr-x 2 root root 4096 2010-04-10 14:56 cdrom0/
drwx------ 1 ping ping 28672 2010-04-03 21:49 LaCie/

so that when I share the LaCie directory through SAMBA, it can only be seen, I can not go into the dir - says not authorized.
I wish I could change the permission to 755, but I tried chmod or chgrp, did not work.
Anybody can help me out of this issue?

Thank you!


*****************************
seems solved by:

manually umount the device,
create a directory in /media, put new item in fstab,
mount -a.

the permission is correct now.

BUT, not sure if I turn off the USB External HDD then turn it on, what the system will do. will it try to mount a new device? or just skip it - I already have it mounted.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
altair4
Level 20
Level 20
Posts: 11460
Joined: Tue Feb 03, 2009 10:27 am

Re: [SOLVED] USB HardDrive automount permission set drwx ---

Post by altair4 »

BUT, not sure if I turn off the USB External HDD then turn it on, what the system will do. will it try to mount a new device? or just skip it - I already have it mounted.
All depends on how you mounted it in fstab and how you formatted it.

There is another way out of this problem and it uses samba itself:
drwx------ 1 ping ping 28672 2010-04-03 21:49 LaCie/
You can allow the external HDD to automount the way it used to before you added the fstab line and add a line to smb.conf itself.

You never stated what method of samba sharing you are using ( there are 2 ) so I'm going to assume it's Nautilus-share ( Nautilus > Right Click > Sharing Options ):

Open Terminal
Type gksu gedit /etc/samba/smb.conf

Add the following line in the [global] sections of smb.conf:
force user = ping
Save the file, exit gedit, and back in the Terminal type: sudo service samba restart

When the remote user, either as guest or as an authorized user, gains access it will be converted to "ping" as far as that share is concerned.

If you're using Classic-share then instead of adding it to the [global] section you would add it to the share definition itself in smb.conf.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
Locked

Return to “Beginner Questions”