Fmstrat / samba-domain

Samba Active Directory Domain Controller for Docker
GNU General Public License v3.0
265 stars 124 forks source link

Your filesystem or build does not support posix ACLs #19

Open 0x4161726f6e opened 4 years ago

0x4161726f6e commented 4 years ago

Running on FreeNAS via Ubuntu VM

Storage is mounted from FreeNAS to Ubuntu via NFSv4 9 other containers are running smoothly

version: "3"

networks:
  extnet:
    external: true

services:
  samba:
    image: nowsci/samba-domain
    container_name: localdc
    volumes:
      - /etc/localtime:/etc/localtime:ro
      - /mnt/docker-configs/samba/data:/var/lib/samba
      - /mnt/docker-configs/samba/config/samba:/etc/samba/external
    environment:
      - DOMAIN=ad.domain.com
      - DOMAINPASS=supersecretsqurel
      - DNSFORWARDER=172.16.0.1
      - HOSTIP=172.16.0.5
    networks:
      - extnet
    ports:
      - 172.16.0.5:53:53
      - 172.16.0.5:53:53/udp
      - 172.16.0.5:88:88
      - 172.16.0.5:88:88/udp
      - 172.16.0.5:135:135
      - 172.16.0.5:137-138:137-138/udp
      - 172.16.0.5:139:139
      - 172.16.0.5:389:389
      - 172.16.0.5:389:389/udp
      - 172.16.0.5:445:445
      - 172.16.0.5:464:464
      - 172.16.0.5:464:464/udp
      - 172.16.0.5:636:636
      - 172.16.0.5:1024-1044:1024-1044
      - 172.16.0.5:3268-3269:3268-3269
    dns_search:
      - ad.domain.com
    dns:
      - 172.16.0.5
      - 172.16.0.1
    extra_hosts:
      - localdc.ad.domain.com:172.16.0.5
    hostname: localdc
    cap_add:
      - NET_ADMIN
    devices:
      - /dev/net/tun
    privileged: true
    restart: always
2020-04-05T22:54:27.482384289Z Looking up IPv6 addresses,
2020-04-05T22:58:08.192924735Z not using extended attributes to store ACLs and other metadata. If you intend to use this provision in production, rerun the script as root on a system supporting xattrs.,
2020-04-05T22:58:08.189109151Z You are not root or your system do not support xattr, using tdb backend for attributes. ,
2020-04-05T22:58:04.793532801Z     raise ProvisioningError("Your filesystem or build does not support posix ACLs, which s3fs requires.  ",
2020-04-05T22:54:27.482595740Z No IPv6 address will be assigned,
2020-04-05T22:54:27.858521695Z Setting up secrets.ldb,
2020-04-05T22:54:28.825475811Z Setting up the registry,
2020-04-05T22:54:30.495215801Z Setting up the privileges database,
2020-04-05T22:54:32.299744946Z Setting up idmap db,
2020-04-05T22:54:33.367522967Z Setting up SAM db,
2020-04-05T22:54:35.011906880Z Adding DomainDN: DC=ad,DC=scriptdoggy,DC=com,
2020-04-05T22:54:33.797877666Z Pre-loading the Samba 4 and AD schema,
2020-04-05T22:54:33.666377744Z Setting up sam.ldb partitions and settings,
2020-04-05T22:54:33.748136571Z Setting up sam.ldb rootDSE,
2020-04-05T22:54:35.621078722Z Adding configuration container,
2020-04-05T22:54:36.122883246Z Setting up sam.ldb schema,
2020-04-05T22:55:31.455888316Z Setting up sam.ldb configuration data,
2020-04-05T22:55:37.055392749Z Setting up display specifiers,
2020-04-05T22:56:14.052069535Z Modifying display specifiers,
2020-04-05T22:56:14.061273500Z Adding users container,
2020-04-05T22:56:14.082011478Z Modifying users container,
2020-04-05T22:56:14.104634382Z Adding computers container,
2020-04-05T22:56:14.134665358Z Modifying computers container,
2020-04-05T22:56:14.151476144Z Setting up sam.ldb data,
2020-04-05T22:56:18.574161924Z Setting up well known security principals,
2020-04-05T22:56:19.701122122Z Setting up sam.ldb users and groups,
2020-04-05T22:56:20.946305498Z Setting up self join,
2020-04-05T22:57:02.344858206Z load_usershare_service: stat of /var/lib/samba/usershares failed. No such file or directory,
2020-04-05T22:58:04.790231079Z ERROR(<class 'samba.provision.ProvisioningError'>): Provision failed - ProvisioningError: Your filesystem or build does not support posix ACLs, which s3fs requires.  Try the mounting the filesystem with the 'acl' option.,
2020-04-05T22:58:04.790296706Z   File "/usr/lib/python2.7/dist-packages/samba/netcmd/domain.py", line 442, in run,
2020-04-05T22:58:04.792381481Z     nosync=ldap_backend_nosync, ldap_dryrun_mode=ldap_dryrun_mode),
2020-04-05T22:58:04.792409172Z   File "/usr/lib/python2.7/dist-packages/samba/provision/__init__.py", line 2172, in provision,
2020-04-05T22:58:04.793482359Z     skip_sysvolacl=skip_sysvolacl),
2020-04-05T22:58:04.793503140Z   File "/usr/lib/python2.7/dist-packages/samba/provision/__init__.py", line 1806, in provision_fill,
2020-04-05T22:58:04.793513429Z     names.domaindn, lp, use_ntvfs),
2020-04-05T22:58:04.793522968Z   File "/usr/lib/python2.7/dist-packages/samba/provision/__init__.py", line 1558, in setsysvolacl
Fmstrat commented 4 years ago

This appears to be a Samba+FreeBSD issue:

https://forums.freebsd.org/threads/samba-4-4-nfsv4-acls-ad-provision-fail.56749/

What happens if you add --use-ntvfs to the provisioning command? (as per https://www.golinuxhub.com/2014/05/your-filesystem-or-build-does-not.html?m=1)

(These were the first two Google results for your error)

suityou01 commented 4 years ago

I changed line 53 of init .sh to read

samba-tool domain provision --use-rfc2307 --domain=${URDOMAIN} --realm=${UDOMAIN} --server-role=dc --dns-backend=SAMBA_INTERNAL --adminpass=${DOMAINPASS} ${HOSTIP_OPTION} --use-interactive --use-ntvfs

I get this error

ERROR(<class 'samba.provision.ProvisioningError'>): Provision failed - ProvisioningError: Your filesystem or build does not support posix ACLs, which s3fs requires.  Try the mounting the filesystem with the 'acl' option

Ubuntu 18.04 Docker version 19.03.6, build 369ce74a3c

Did I do something wrong?

dchicchon commented 2 years ago

Also getting this same issue, I tried the --use-ntvfs option to no avail

burnbabyburn commented 2 years ago

i think there is not much we can do about it, as long we're not building samba in a previous build stage. Since Samba 4.5 vxfs is not compiled by default. (--enable-vxfs) maybe i am wrong and one could use the new --with-ntvfs-fileserver parameter at provisioning.

Fmstrat commented 1 year ago

Could anyone give this a shot with the latest build (using Samba 4.7)?