The Samba-Bugzilla – Bug 12759
smbd: files and directories created by admin users are owned by root if inherit acls is disabled
Last modified: 2017-04-28 11:48:50 UTC
A user can be defined as an admin user on the share (listed in "admin users" or member of a group listed there). When serving an admin user, smbd runs as root.
That means when files / directories are created, the kernel creates them as owned by root, and that has to be fixed to prevent confusion.
If "inherit acls" is enabled (happens automatically when acl_xattr module is loaded), the Windows ACL inheritance mechanism causes new files and directories to have the correct POSIX owner, and that takes care of things also for the "root" case.
However, if "inherit acls" is disabled, there's no existing mechanism to fix the ownership, and the owner ends up being root.