[Samba] Problem file server with microsoft office temp files

Gabriel Franca gabriel.franca at gmail.com
Wed Jul 6 14:37:43 UTC 2022


Good morning people,

I have a problem on my file server with samba in version 4.15.5 with office
files (excel, word etc..).
When someone saves a file in the domain, an 8-character file with the
extension .tmp appears. The server already has hundreds of TMP files that
are not deleted by themselves.

Before it was with centos 8.1 and I migrated it to Rockylinux 8.6 and with
that the samba was updated and the problem appeared.
I installed and configured Almalinux 9 and the same problem happens.

Do you know if there is any configuration I need to do in my smb.conf to
solve this problem?

I'm putting my smb.conf below to see if I'm using something I shouldn't, or
if I'm missing something.
Thank you very much in advance!

      [global]

        security = ADS
        workgroup = XXXX
        realm = XXXX.LOCAL
        log file = /var/log/samba/%m.log
        log level = 1
        username map = /etc/samba/user.map
        min domain uid = 0

        # Herda permissoes do windows
        map acl inherit = yes

        #Permite permissões ACL
        vfs objects = recycle,acl_xattr,acl_tdb

        #Usuários podem se autenticar sem necessidade de interaçao humana

        dedicated keytab file = /etc/krb5.keytab
        kerberos method = secrets and keytab
        winbind refresh tickets = yes

        # Faz mapeamento do RID ( Windows ) como UID ( linux)

        idmap config * : backend = tdb
        idmap config * : range = 3000-7999
        idmap config XXXX:backend = rid
        idmap config XXXX:schema_mode = rfc2307
        idmap config XXXX:range = 10000-9999999
        idmap config XXXX: unix_nss_info = yes

        winbind use default domain = yes

        winbind enum users = yes
        winbind enum groups = yes

        sync always = yes
        strict sync = yes

        recycle:keeptree = yes
        recycle:versions = yes
        recycle:repository = /dados/trash/%U
        recycle:exclude = *.tmp, *.log, *.obj, ~*.*, *.bak, *.iso
        recycle:exclude_dir = tmp, cache


        [dpto]
        comment = Pasta Departamental
        path = /dados/dpto
        read only = No
        browseable = yes
        #Bloqueio de extensoes de midia no samba
        veto files = /*.mp3/*.nws/*.{*}/*.avi/*.mpeg/*.mpg/*.wma/*.wmv/*.exe
        hide unreadable = yes
        hide unwriteable files = yes


More information about the samba mailing list