configuration-templates – Blame information for rev 185
?pathlinks?
Rev | Author | Line No. | Line |
---|---|---|---|
81 | office | 1 | ########################################################################### |
2 | ## Copyright (C) Wizardry and Steamworks 2017 - License: GNU GPLv3 ## |
||
3 | ## Please see: http://www.gnu.org/licenses/gpl.html for legal details, ## |
||
4 | ## rights of fair usage, the disclaimer and warranty conditions. ## |
||
5 | ########################################################################### |
||
6 | ## Optimized standalone configuration template for Samba servers. ## |
||
7 | ## ## |
||
8 | ## Ideal for: ## |
||
9 | ## * Virtual machine file sharing ## |
||
10 | ## ## |
||
11 | ## Requirements: ## |
||
86 | office | 12 | ## * Samba 4.x ## |
81 | office | 13 | ## ## |
14 | ## File placement layout: ## |
||
15 | ## / ## |
||
16 | ## `-- etc ## |
||
17 | ## `-- samba ## |
||
18 | ## |-- smb.conf ## |
||
19 | ## |-- smb.conf.local ## |
||
95 | office | 20 | ## |-- smb.conf.share ## |
21 | ## `-- smb.conf.ldap ## |
||
81 | office | 22 | ## ## |
23 | ## Files Description: ## |
||
24 | ## * /etc/samba/smb.conf (this file) ## |
||
25 | ## * /etc/samba/smb.conf.local (local server-site settings) ## |
||
26 | ## * /etc/samba/smb.conf.share (samba shares go here) ## |
||
95 | office | 27 | ## * /etc/samba/smb.conf.ldap (optional ldab configuration) ## |
81 | office | 28 | ## ## |
29 | ########################################################################### |
||
30 | |||
31 | [global] |
||
32 | name resolve order = lmhosts host wins bcast |
||
33 | |||
34 | # Standalone. |
||
162 | office | 35 | local master = no |
36 | domain master = no |
||
37 | preferred master = no |
||
93 | office | 38 | security = user |
81 | office | 39 | # For compatibility with scripts. |
40 | passdb backend = smbpasswd |
||
183 | office | 41 | add user script = /usr/sbin/useradd -d /nonexistent -s /usr/sbin/nologin %u |
165 | office | 42 | map to guest = Bad User |
94 | office | 43 | guest account = nobody |
165 | office | 44 | # Allow some variable expansions to work. |
45 | #%M |
||
46 | hostname lookups = yes |
||
47 | #%m |
||
48 | #smb ports = 139 |
||
162 | office | 49 | # Extended attributes on files. |
50 | ea support = yes |
||
51 | map acl inherit = yes |
||
52 | store dos attributes = yes |
||
81 | office | 53 | |
165 | office | 54 | # Samba version support (support legacy clients). |
55 | min protocol = NT1 |
||
56 | |||
85 | office | 57 | # Samba modules. |
165 | office | 58 | # vfs objects = shadow_copy2 catia fruit streams_xattr acl_xattr recycle crossrename io_uring aio_pthread |
59 | vfs objects = shadow_copy2 catia fruit streams_xattr acl_xattr recycle crossrename aio_pthread |
||
162 | office | 60 | shadow: snapdir = .zfs/snapshot |
61 | shadow: sort = desc |
||
62 | shadow: format = zfs-auto-snap_%S-%Y-%m-%d-%H%M |
||
63 | shadow:localtime = no |
||
64 | recycle:repository = .recycle/%U |
||
65 | recycle:keeptree = yes |
||
66 | recycle:versions = yes |
||
67 | recycle:touch = yes |
||
68 | recycle:directory_mode = 0777 |
||
69 | recycle:subdir_mode = 0700 |
||
70 | fruit:resource = file |
||
71 | fruit:metadata = netatalk |
||
72 | fruit:locking = netatalk |
||
85 | office | 73 | fruit:encoding = native |
162 | office | 74 | fruit:resource = xattr |
75 | fruit:time machine = no |
||
76 | fruit:metadata = stream |
||
85 | office | 77 | fruit:locking = none |
162 | office | 78 | fruit:encoding = native |
79 | fruit:veto_appledouble = yes |
||
80 | fruit:posix_rename = yes |
||
81 | readdir_attr:aapl_finder_info = yes |
||
82 | readdir_attr:aapl_max_access = yes |
||
83 | readdir_attr:aapl_rsize = yes |
||
84 | streams_xattr:store_stream_type = yes |
||
165 | office | 85 | crossrename:sizelimit = 50 |
86 | io_uring:num_entries = 128 |
||
87 | io_uring:sqpoll = no |
||
85 | office | 88 | aio_linux:aio num events = 256 |
162 | office | 89 | aio_pthread:aio open = true |
83 | office | 90 | |
85 | office | 91 | ### Tweaks |
92 | # Don't tweak Linux buffers: SO_RCVBUF=131072 SO_SNDBUF=131072 |
||
162 | office | 93 | socket options=TCP_NODELAY IPTOS_LOWDELAY |
94 | # No extent-based allocation: ZFS |
||
95 | strict allocate = no |
||
96 | # No sendfile on: ZFS |
||
97 | use sendfile = no |
||
165 | office | 98 | # Requires aio_pthread as last module in vfs_objects |
162 | office | 99 | aio read size = 1 |
100 | aio write size = 1 |
||
165 | office | 101 | # Enable raw rights and reads. |
83 | office | 102 | read raw = yes |
103 | write raw = yes |
||
162 | office | 104 | |
81 | office | 105 | # Logging |
85 | office | 106 | # 0 -> LOG_ERR, 1 -> LOG_WARNING, 2 -> LOG_NOTICE, 3 -> LOG_DEBUG |
94 | office | 107 | log level = 1 |
81 | office | 108 | |
95 | office | 109 | # Include LDAP configuration. |
184 | office | 110 | #include = /etc/samba/smb.conf.ldap |
165 | office | 111 | |
112 | # Include DFS. |
||
184 | office | 113 | #include = /etc/samba/smb.conf.dfs |
95 | office | 114 | |
81 | office | 115 | # Include local settings. |
185 | office | 116 | #include = /etc/samba/smb.conf.local |
81 | office | 117 | |
118 | # Include shares. |
||
184 | office | 119 | include = /etc/samba/smb.conf.share |