SMB copy of file >2GB fails

  • Version : LibreELEC 8.2.5

    HW : WeTek Play 2

    Copy of file >2GB over SMB to external HD attached to Wetek Play USB port fails with following error message (/var/log/log.smbd).

    [2018/05/22 19:40:58.453154, 0] ../source3/locking/posix.c:270(posix_fcntl_getlock) posix_fcntl_getlock: WARNING: lock request at offset 2147155976, length 65534 returned an Invalid argument error. This can happen when using 64 bit lock offsets on 32 bit NFS mounted file systems.

    External HD file system is EXT4, file copy from PC with Fedora 28

    Problem could be solved by adding following line to /storage/.config/samba.conf

    strict locking = no

    Similar problem described here : hints.macworld.com

    Hope it helps fix the problem :)

  • Do you have the same error or just same problem? ssh and type "nano /var/log/log.smbd", search for Warnings/Errors.

    If it's the same error, did you restart device (or samba service)? Where exactly did you add the strict locking line?

    Btw. what device are you running LE on and what filesystem is the external hd using?

    Edited once, last by rastobil (July 21, 2018 at 12:02 PM).

  • Adding vers=1.0 to the options of cifs mount script solves the issue for me. And min and max version for samba is selected as smb1 at LE settings>services.

    Code
    Options=username=user,password=pass,rw,vers=1.0
  • Adding vers=1.0 to the options of cifs mount script solves the issue for me. And min and max version for samba is selected as smb1 at LE settings>services.

    Code
    Options=username=user,password=pass,rw,vers=1.0

    Thanks very much for posting this.

    I was having a problem when recording with the recording stopping when it reached a size of 2GB. I was recording to a network windows share (mounted by cifs or nfs) and i'd get a "message write failed - file too large" when it reached 2148mb which would be around 30 minutes for a HD recording. This didn't make sense as it was writing to NTFS.

    Simply changing the version as you described sorted it for me.