OSX CIFS : unable to open some files ?

Status
Not open for further replies.

Martintamare

Cadet
Joined
Oct 15, 2014
Messages
7
Hello there,

We recently migrated to freenas, so far so good :)
The only remaining issue is kind of tricky, I'll try to make it clear.

We have a parc of both PC and Mac using CIFS share.
For PC users, everything is OK.
For Mac users, we encountered an issue that I'm unable to resolve cleanly.

The issue is the following, users are able to open some files with Photoshop but not all of them.

Permissions are correct for both OK and KO files
ACL are correct for both OK and KO files
The only things changing are extattr :

Code:
lsextattr user OK.JPG
OK.JPG DOSATTRIB DosStream.AFP_AfpInfo:$DATA

2 attributes here, ok
vs
Code:
lsextattr user KO.JPG
KO.JPG DosStream.AFP_AfpInfo:$DATA DOSATTRIB DosStream.AFP_Resource:$DATA
lsextattr user KO2.jpg
KO2.jpg DOSATTRIB DosStream.AFP_AfpInfo:$DATA DosStream.AFP_Resource:$DATA

3 attributes here, seems to be the cause of the problem.

Coping the file remove the attributes and fix the problem. When user from mac open the file, it is saved with the same two attributes.

I'm still unable to understand where the third attributes comes from.

Questions :
- Where does the 'faulty' attributes comes from ?
- How can we solve the problem forever ?

Behind the smb.conf and some logs happening during the opening of a KO file

Code:
[global]
    server max protocol = SMB3_00
    encrypt passwords = yes
    dns proxy = no
    strict locking = no
    oplocks = yes
    deadtime = 15
    max log size = 51200
    max open files = 11070
    syslog only = yes
    syslog = 1
    load printers = no
    printing = bsd
    printcap name = /dev/null
    disable spoolss = yes
    getwd cache = yes
    guest account = nobody
    map to guest = Bad User
    obey pam restrictions = Yes
    directory name cache size = 0
    kernel change notify = no
    panic action = /usr/local/libexec/samba/samba-backtrace
    ea support = yes
    store dos attributes = yes
    acl allow execute always = true
    local master = yes
    idmap config *:backend = tdb
    idmap config *:range = 90000000-100000000
    server role = member server
    security = user
    passdb backend = ldapsam:ldaps://192.168.0.253
    ldap admin dn = cn=admin2,dc=toto
    ldap suffix = dc=toto
    ldap user suffix = ou=people
    ldap group suffix = ou=groups
    ldap machine suffix = ou=computers
    ldap ssl = off
    ldap replication sleep = 1000
    ldap passwd sync = yes
    ldapsam:trusted = yes
    idmap uid = 10000-39999
    idmap gid = 10000-39999
    netbios name = NAS0
    workgroup = TOTO
    pid directory = /var/run/samba
    smb passwd file = /var/etc/private/smbpasswd
    private dir = /var/etc/private
    create mask = 0666
    directory mask = 0777
    client ntlmv2 auth = yes
    dos charset = CP437
    unix charset = UTF-8
    log level = 10
    syslog only = no
    max log size = 5000
    log file = /var/log/tmp_smbd.log
    log level = 2

[_02Fichiers]
    path = /mnt/data/redac/_02Fichiers
    printable = no
    veto files = /.snap/.windows/.zfs/
    comment = NAS
    writeable = yes
    browseable = yes
    recycle:repository = .recycle/%U
    recycle:keeptree = yes
    recycle:versions = yes
    recycle:touch = yes
    recycle:directory_mode = 0777
    recycle:subdir_mode = 0700
    shadow:snapdir = .zfs/snapshot
    shadow:sort = desc
    shadow:localtime = yes
    shadow:format = auto-%Y%m%d.%H%M-2w
    vfs objects = shadow_copy2 zfsacl streams_xattr aio_pthread
    hide dot files = yes
    guest ok = no
    nfs4:mode = special
    nfs4:acedup = merge
    nfs4:chown = yes
    zfsacl:acesort = dontcare



Code:
 u.user opened file KO.jpg read=No write=No (numopen=45)
[2015/03/12 16:47:57.498968,  2] ../source3/smbd/close.c:780(close_normal_file)
  u.user closed file KO.jpg (numopen=44) NT_STATUS_OK
[2015/03/12 16:47:57.499863,  2] ../source3/smbd/open.c:975(open_file)

going on and on until the app timeout ....

Thank for reading until here :)
 
Last edited:
Status
Not open for further replies.
Top