Project

General

Profile

Tâche #32064

Scénario #31997: dcDiag en erreur sur Seth/Scribe >= 2.7.2

ajout de "msDS-SDReferenceDomain" dans le LDAP

Added by Emmanuel GARETTE 6 months ago. Updated 5 months ago.

Status:
Fermé
Priority:
Normal
Assigned To:
Start date:
04/08/2021
Due date:
% Done:

100%

Remaining (hours):
0.0

Description

Exemple de script :

realm="etb3.lan" 
rootdn="DC=etb3,DC=lan" 
ldb="/var/lib/samba/private/sam.ldb" 
for obj in DomainDnsZones ForestDnsZones; do
    dn=$(ldbsearch -H "$ldb" --cross-ncs "(dnsroot=$obj.$realm)" dn|grep "^dn: "|awk '{print $2}')
    if ! $(ldbsearch -H "$ldb" -b "$dn" msDS-SDReferenceDomain|grep -q "^msDS-SDReferenceDomain: "); then
        cat >/tmp/referencedomain.ldif <<EOF
dn: $dn
changetype: modify
add: msDS-SDReferenceDomain
msDS-SDReferenceDomain: CN=Configuration,$rootdn
EOF
        ldbmodify -v -H /var/lib/samba/private/sam.ldb /tmp/referencedomain.ldif
       rm -f /tmp/referencedomain.ldif
    fi
done

Associated revisions

Revision 761b40f0 (diff)
Added by Emmanuel GARETTE 6 months ago

ajout de msDS-SDReferenceDomain dans l'annuaire (ref #32064)

Revision b01421c5 (diff)
Added by Emmanuel GARETTE 6 months ago

ajout de msDS-SDReferenceDomain dans l'annuaire (ref #32064)

History

#1 Updated by Emmanuel GARETTE 6 months ago

  • Status changed from Nouveau to En cours
  • Assigned To set to Emmanuel GARETTE

#2 Updated by Emmanuel GARETTE 6 months ago

  • Status changed from En cours to Résolu
  • % Done changed from 0 to 100

Avant mise à jour :

root@addc:~# ldbsearch  -H /var/lib/samba/private/sam.ldb  --cross-ncs  '(msDS-SDReferenceDomain=*)' msDS-SDReferenceDomain
# returned 0 records
# 0 entries
# 0 referrals

Après mise à jour et reconfigure :

root@addc:~# ldbsearch  -H /var/lib/samba/private/sam.ldb  --cross-ncs  '(msDS-SDReferenceDomain=*)' msDS-SDReferenceDomain
# record 1
dn: CN=75f57a29-18cc-47d7-b744-a0ab2e2d2d1e,CN=Partitions,CN=Configuration,DC=domscribe,DC=ac-test,DC=fr
msDS-SDReferenceDomain: CN=Configuration,DC=domscribe,DC=ac-test,DC=fr

# record 2
dn: CN=90534959-4334-461e-a4af-7f7a29c01e03,CN=Partitions,CN=Configuration,DC=domscribe,DC=ac-test,DC=fr
msDS-SDReferenceDomain: CN=Configuration,DC=domscribe,DC=ac-test,DC=fr

# returned 2 records
# 2 entries
# 0 referrals

#3 Updated by Fabrice Barconnière 5 months ago

  • Status changed from Résolu to Fermé
  • Remaining (hours) set to 0.0

Also available in: Atom PDF