samba write problems

Questions about networking.
In the Original Post please also include the output of inxi -FNzxx
belgiumsolydk
Posts: 73
Joined: 06 Mar 2014 12:17
Location: Erpe-Mere Belgium

samba write problems

Postby belgiumsolydk » 21 Jul 2015 13:47

Hi all,

I am having a strange problem with my NAS.
I have an NFS-share on the NAS. When I mount this on my SolydK 64 I have serious lock-ups of the computer.(all seem to
freeze for a few seconds, and this almost continuously)
With my wired desktop computer I have no problems with this NAS and with NFS.
I have had the same with other distros and other laptops. When I add the "soft" option these lock-ups disappear.
However with this option you are not 100% sure of data-integrity.
The connection to the NAS is with wifi. Mounting is done by the command⁻line. I tried with autofs. Problems were the same.
I just think NFS is not made to be used over wifi.
So today I got sick of it and started using samba. I can mount the share just fine but I can't write to SOME directories on it.
I mount with :
sudo mount -t cifs -o username=xxx,passord=xxx,uid=xxx //ip-address/data /mnt/data
when I type mount I get this info :
//ip-address/data on /mnt/data type cifs (rw,relatime,vers=1.0,cache=strict,username=xxx,domain=xxx,uid=1000,forceuid,gid=0,noforcegid,addr=ip-address,file_mode=0755,dir_mode=0755,nounix,serverino,rsize=61440,wsize=65536,actimeo=1)
let's say the share has following directories
films
film1
film2
films DVD
fotos
vacation
hobby
all are directories.
I can't write to films, or its sub-directories film1 and film2
I can write to films DVD
I can't write to fotos, but I can write to vacation or hobby
NAS : QNAP TS-121
laptop : i7

I checked all info about the directories but they all seem to be the same (checked with stat-commando and with properties through dolphin)

Can't find similar problems with google

Any ideas?

User avatar
Zill
Posts: 1850
Joined: 13 Aug 2013 14:28
Location: Lincolnshire, UK

Re: samba write problems

Postby Zill » 21 Jul 2015 15:05

belgiumsolydk wrote:... The connection to the NAS is with wifi. Mounting is done by the command⁻line. I tried with autofs. Problems were the same.
I just think NFS is not made to be used over wifi...
As I only run Linux systems, I have no use for samba. However, I have used NFS, autofs and wifi on my LAN for years without any problems. If you wish to debug any of this then please post your relevant config files.

User avatar
Arjen Balfoort
Site Admin
Posts: 9283
Joined: 26 Jan 2013 19:36
Location: Netherlands
Contact:

Re: samba write problems

Postby Arjen Balfoort » 21 Jul 2015 15:06

In my /etc/fstab I have this to mount my NAS:

Code: Select all

//192.168.1.1/<shared_mount_point>   /media/<mount_point>   cifs credentials=/root/.media-<mount_point>.credentials,uid=1000,gid=100,workgroup=WORKGROUP,noauto,x-systemd.automount,iocharset=utf8,_netdev 0 0
The file /root/.media-EXTHD.credentials contains:

Code: Select all

username=<my_nas_username>
password=<my_nas_password>
Mounts perfectly on all my wireless systems. I haven't solved hang on shutdown, though. It takes 90 seconds until time-out. I learned to live with that...

Also compare ownership and permission of directories that you can write to and directories you cannot write to.

For reference:
autofs mount: http://forums.solydxk.nl/viewtopic.php?f=9&t=4512
systemd mount: http://forums.solydxk.nl/viewtopic.php?f=9&t=4358


SolydXK needs you!
Development | Testing | Translations

belgiumsolydk
Posts: 73
Joined: 06 Mar 2014 12:17
Location: Erpe-Mere Belgium

Re: samba write problems

Postby belgiumsolydk » 22 Jul 2015 18:46

Zill,
I also have only Linux-systems at home that is why I always used nfs. As I said, wired all is fine. I have wired connections
on my desktop and Raspberry Pi.
I mount the cifs or nfs share through command line so according to me I don't have any config files.

Schoelje,
I don't like the hanging with shutdown but maybe I need to mount in the media directory as you do instead of an directory
in the mnt folder
I try that and get back.

I triple checked all ownership and permissions but they are all the same!

User avatar
Zill
Posts: 1850
Joined: 13 Aug 2013 14:28
Location: Lincolnshire, UK

Re: samba write problems

Postby Zill » 22 Jul 2015 19:32

belgiumsolydk: As far as NFS goes, my client/server machines have the following config files in /etc:

Code: Select all

exports
hosts
hosts.allow
hosts.deny
I now use Autofs to avoid any shutdown delays and so I also have the following two config files in /etc:

Code: Select all

auto.master
auto.misc
Automounting NFS exported files works well with this system, even with the machines using a wifi connection.

CIFS is, like SMB, a Microsoft protocol and so I would expect samba to have trouble trying to mount NFS exports.


Return to “Networking”

Who is online

Users browsing this forum: No registered users and 0 guests