summaryrefslogtreecommitdiff
path: root/source4/scripting/devel/drs/unvampire_ad.sh
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2009-10-06 10:59:36 +1100
committerAndrew Bartlett <abartlet@samba.org>2009-10-06 11:10:33 +1100
commit40b09f689bea23eaa6dbaa3e29b0a91adcd06a53 (patch)
tree23ad85c69063fb7d08f2b71e78c3100672271542 /source4/scripting/devel/drs/unvampire_ad.sh
parenta474ebf924b86b102891116d49659d7438de26e2 (diff)
downloadsamba-40b09f689bea23eaa6dbaa3e29b0a91adcd06a53.tar.gz
samba-40b09f689bea23eaa6dbaa3e29b0a91adcd06a53.tar.bz2
samba-40b09f689bea23eaa6dbaa3e29b0a91adcd06a53.zip
s4:drs-development Scripts to assist testing of DRS replication with AD
These scripts, originally by tridge, allow developers to easily reproduce the same domain join senerio time after time. They need documentation, and the template named.conf and zone files for hosting an AD domain are not provided. However, I hope to have the provision script provide these shortly. They assume a local 'bind' set up to read PREFIX/private/named.conf (as per the provision instructions). Ensure you edit the 'vars' file to match your local setup. Andrew Bartlett
Diffstat (limited to 'source4/scripting/devel/drs/unvampire_ad.sh')
-rwxr-xr-xsource4/scripting/devel/drs/unvampire_ad.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/source4/scripting/devel/drs/unvampire_ad.sh b/source4/scripting/devel/drs/unvampire_ad.sh
new file mode 100755
index 0000000000..f44edafee7
--- /dev/null
+++ b/source4/scripting/devel/drs/unvampire_ad.sh
@@ -0,0 +1,12 @@
+#!/bin/bash
+
+set -x
+
+. `dirname $0`/vars
+
+
+$PREFIX/bin/ldbdel -H ldap://$server.$DNSDOMAIN -U$workgroup/administrator%$pass "CN=$machine,CN=Computers,$dn"
+$PREFIX/bin/ldbdel -H ldap://$server.$DNSDOMAIN -U$workgroup/administrator%$pass "CN=$machine,OU=Domain Controllers,$dn"
+$PREFIX/bin/ldbdel -H ldap://$server.$DNSDOMAIN -U$workgroup/administrator%$pass "CN=NTDS Settings,CN=$machine,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,$dn"
+$PREFIX/bin/ldbdel -H ldap://$server.$DNSDOMAIN -U$workgroup/administrator%$pass "CN=$machine,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,$dn"
+rm -f $PREFIX/private/*.ldb