I have one Debian 9 machine that I run as a home server, mostly serving files over the network through samba. I've installed Debian 10 in my desktop which I ran windows on before without any problem connecting to my files on my homeserver.
So when I try to mount the cifs shares on my homeserver in fstab on my desktop I just don't rights to do anything but read the files. I've been trying for a few weeks to figure out what's wrong, trying different mounting commands. When I connect to the shares in dolphin (I run KDE) there's no problem, I get full rights using the exact same credentials.
So what happens with the permissions when I connect through the fstab mounted volumes is that the permissions on the files (running ls -l) is root:root instead of userA (UID 1000) which exist only on the home server. I created a different username on my desktop, userB (UID 1000) and this is where I think the problem comes from. that they have the same UID but on two different machines with two different usernames, at least when it comes to fstab.
I'm very new at this, I only had help setting up my home server and I've been on Buster for a couple of weeks managing to fix one problem at a time but I just can't figure out how to mount my shares in fstab. If you answer, please take into consideration that I'm not well versed in the linux world.
Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230
cifs in fstab from debian to debian
- ruwolf
- Posts: 639
- Joined: 2008-02-18 05:04
- Location: Banovce nad Bebravou
- Has thanked: 40 times
- Been thanked: 28 times
Re: cifs in fstab from debian to debian
How do you mount it?
wiki.ubuntu.com: MountWindowsSharesPermanently
wiki.ubuntu.com: MountWindowsSharesPermanently
Re: cifs in fstab from debian to debian
I've tried a bunch of different ones.
I haven't even been able to mount the share manually in the command prompt with the right privileges. I've tried a couple of others but I don't have the command line anymore. I looked at the link you recommended and I didn't have an a-ha moment reading it.
Edit: Worth nothing is that if I try to sudo mount -t cifs the share to the folder in my /home/userA/mnt/alexandria folder it gives me an error saying that it can't find that in /etc/fstab like it can only mount network shares that are defined in /etc/fstab.
Code: Select all
//10.101.242.21/alexandria /media/share/alexandria cifs username=userA,uid=userA,gid=1000,password=pwd,iocharset=utf8,users
Code: Select all
//10.101.242.21/alexandria /home/userB/mnt/alexandria cifs username=userA,password=pwd,user 0 0
Code: Select all
//10.101.242.21/alexandria /media/share/alexandria cifs username=userA,uid=userA,gid=groupA,password=pwd,iocharset=utf8,users
Edit: Worth nothing is that if I try to sudo mount -t cifs the share to the folder in my /home/userA/mnt/alexandria folder it gives me an error saying that it can't find that in /etc/fstab like it can only mount network shares that are defined in /etc/fstab.
Re: cifs in fstab from debian to debian
I used the number for UID, I was just stating from what userruwolf wrote:The uid is always a number, probably 1000 as you have mentioned it...
- Head_on_a_Stick
- Posts: 14114
- Joined: 2014-06-01 17:46
- Location: London, England
- Has thanked: 81 times
- Been thanked: 133 times
Re: cifs in fstab from debian to debian
Try removing the user & users options, they shouldn't be needed.
And I think the password should be defined in a credentials file (declared in the options) with the x-systemd.automount option also added in.
Reference: https://wiki.debian.org/SAMBAClientSetup
And I think the password should be defined in a credentials file (declared in the options) with the x-systemd.automount option also added in.
Reference: https://wiki.debian.org/SAMBAClientSetup
deadbang