PATCH: don't continue without domain info
Michael Wood
esiotrot at gmail.com
Mon Aug 15 09:05:49 MDT 2011
On 15 August 2011 16:31, Björn JACKE <bj at sernet.de> wrote:
> I've seen crazy broken setups due to flaky LDAP connection on startup twice
> now. IMHO we shouldn't start if we know that we have a broken setup. Any
> arguments agains the attached patch?
Sounds reasonable :)
> diff --git a/source3/passdb/pdb_ldap.c b/source3/passdb/pdb_ldap.c
> index f8da0ff..7c8a50c 100644
> --- a/source3/passdb/pdb_ldap.c
> +++ b/source3/passdb/pdb_ldap.c
> @@ -6599,13 +6599,10 @@ NTSTATUS pdb_init_ldapsam(struct pdb_methods **pdb_method, const char *location)
> ldap_state->domain_name, True);
>
> if ( !NT_STATUS_IS_OK(nt_status) ) {
> - DEBUG(2, ("pdb_init_ldapsam: WARNING: Could not get domain "
> - "info, nor add one to the domain\n"));
> - DEBUGADD(2, ("pdb_init_ldapsam: Continuing on regardless, "
> - "will be unable to allocate new users/groups, "
> - "and will risk BDCs having inconsistent SIDs\n"));
> - sid_copy(&ldap_state->domain_sid, get_global_sam_sid());
> - return NT_STATUS_OK;
> + DEBUG(0, ("pdb_init_ldapsam: WARNING: Could not get domain "
> + "info, nor add one to the domaian. "
There's a typo in "domaian".
> + "We cannot workreliably without.\n"));
Maybe: "We cannot work reliably without it."?
> + return NT_STATUS_UNSUCCESSFUL;
> }
>
> /* Given that the above might fail, everything below this must be
--
Michael Wood <esiotrot at gmail.com>
More information about the samba-technical
mailing list