[Samba] Mac clients trouble with NFD accented characters on Samba share

MI mi.lists at alma.ch
Wed Dec 11 14:23:36 UTC 2019

File names on a Samba share with accented characters using the NFD form 
of UTF8 cannot be seen or used by Mac clients.

While tying to find a solution, I came across this old thread : 
("[Samba] Mount unix samba 4 share to osx client without mangled file 

A reply in that thread suggested:

>     >/Do I have to tell osx to simply use utf-8 nfc encoding for the samba />/share? Or is there some special samba server/client config? /
>     yes. vfs_fruit and
>        fruit:encoding = native

So I enabled vfs_fruit, but it doesn't seem to help for accented 
characters. Maybe it only solves a problem with illegal characters?

This is what I tried, but which didn't help:

Create the folders/files on the Samba server (Debian 9, smbd version 
4.5.16) :

    mkdir vélos_1                     # normal NFC dir
    mkdir "ve$(printf '\u301')los_2"  # NFD dir

    cd v*_1
    echo "NFC" >> vélo.txt

    cd ../v*_2
    echo "NFD" >> "ve$(printf '\u301')lo.txt"

This is my samba config:

    # testparm -s
    Load smb config files from /etc/samba/smb.conf
    rlimit_max: increasing rlimit_max (1024) to minimum Windows limit
    Processing section "[homes]"
    Processing section "[share]"
    Processing section "[temp]"
    Loaded services file OK.
    Server role: ROLE_STANDALONE

    # Global parameters
         os level = 255
         preferred master = Yes
         log file = /var/log/samba/%m.log
         max log size = 1000
         panic action = /usr/share/samba/panic-action %d
         usershare allow guests = Yes
         disable spoolss = Yes
         load printers = No
         show add printer wizard = No
         client signing = No
         map to guest = Bad User
         obey pam restrictions = Yes
         pam password change = Yes
         passwd chat = *Enter\snew\s*\spassword:* %n\n
    *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
         passwd program = /usr/bin/passwd %u
         security = USER
         server role = standalone server
         unix password sync = Yes
         dns proxy = No
         fruit:encoding = native
         fruit:locking = netatalk
         fruit:metadata = netatalk
         fruit:resource = file
         idmap config * : backend = tdb
         ea support = Yes
         smb encrypt = No
         vfs objects = catia fruit streams_xattr



         comment = on /home for tests, temp etc.
         path = /home/temp
         force user = alma
         guest ok = Yes
         read only = No

I could set up a cron job to rename all the problem files and folders 
every night using convmv.

But before doing that, I would like to make sure I'm not overlooking a 
simpler solution through the Samba configuration.

Thanks for any help,


More information about the samba mailing list