[PATCH] Check idmap config with testparm
jra at samba.org
Wed Dec 7 23:16:19 UTC 2016
On Wed, Dec 07, 2016 at 06:43:35PM +0100, Andreas Schneider wrote:
> you might know I work for a Distributor and fix winbind issues there every
> I see so many invalid idmap configurations, I think 70% of the configs are
> wrong or invalid. In addition our documentation for ID mapping really sucks!
> So I had a call with Marc and he started to improve it. See the User
> documentation in the Wiki.
> While trying to chase down a winbindd bug the last days I read all the changes
> last year and stumbled upon Volkers nice lp_wi_scan_global_parametrics()
> function again. So I decided it is time to check the idmap config in testparm.
> So here we go ...
> idmap config * : backend = rid
> idmap config * : range = 1000000-1999999
> # Winbind domain idmap
> idmap config EARTH : backend = rid
> idmap config EARTH : range = 100000000-199999999
> idmap config MARS : backend = rid
> idmap config MARS : range = 200000000-299999999
> idmap config VENUS : backend = rid
> idmap config VENUS : range = 150000000-399999999
> bin/testparm smb.conf.ads > /dev/null
> Load smb config files from smb.conf.ads
> ERROR: Do not use the 'rid' backend for the default backend (idmap config *)!
> ERROR: The idmap range for the domain MARS overlaps with the range of VENUS
> Server role: ROLE_DOMAIN_MEMBER
> Press enter to see a dump of your service definitions
> Review and push of the attached patchset is much appreciated!
Woo Hoo ! *Fantastic* work Andreas, thanks !
Would you consider squashing in the following patch on top,
to prevent a "ERROR:" message in the standalone server
case (where idmap config should be ignored) ?
With that : Reviewed-by: Jeremy Allison <jra at samba.org>
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 1337 bytes
Desc: not available
More information about the samba-technical