Active Directory
Author
Discussion

nickfrp

Original Poster:

5,156 posts

266 months

Monday 5th February 2007
quotequote all
Can i export the data in AD in to a test domain "import it". i want to simulate the power of group policys and organizational units which we havent implemented yet into our working enviroment

Thanks
Nick

BliarOut

72,863 posts

270 months

Monday 5th February 2007
quotequote all
Yes. Ldifde is your friend.

http://support.microsoft.com/kb/23767


You can also use a text editor to find and replace instances of a string in between the export and the import process, for example if the domain names or OU's are slightly different.

nickfrp

Original Poster:

5,156 posts

266 months

Monday 5th February 2007
quotequote all
Thanks

so am i right in thinking i can run this command:

LDIFDE –f ADdump.ldf –s ATL-DC01

and it wil copy and not disrupt the exsisting AD in the domain?

BliarOut

72,863 posts

270 months

Monday 5th February 2007
quotequote all
nickfrp said:
Thanks

so am i right in thinking i can run this command:

LDIFDE –f ADdump.ldf –s ATL-DC01

and it wil copy and not disrupt the exsisting AD in the domain?

Yup, although this will restrict the export to just users

ldifde -f ADdump.ldf -s ATL-DC01 -d "dc=Export,dc=com" -p subtree -r "(&(objectCategory=person)(objectClass=User)(givenname=*))" -l "cn,givenName,objectclass,samAccountName"

Substitute your domain details in this bit as that command is for a domain called export.com

"dc=Export,dc=com"


Avoid the -i flag on your live domain as that sets it to import mode.

nickfrp

Original Poster:

5,156 posts

266 months

Monday 5th February 2007
quotequote all
im trying to import my LDF file.

but using this comand
ldifde -i -f addump.ldf -s DOMAIN

"domain" is my test domain

it says:

loading entries
add error on line 2: unwilling to perform
the server side error is "the specified instance type not valid


any ideas?

nickfrp

Original Poster:

5,156 posts

266 months

Monday 5th February 2007
quotequote all
is the problem because domain 1 is called white.com and domain 2 is called black.com for example.
is this problems because the 2 domain are completely differnt

BliarOut

72,863 posts

270 months

Monday 5th February 2007
quotequote all
-s is the parameter for the server name to bind to, not the domain name.

snowy

542 posts

312 months

Monday 5th February 2007
quotequote all
other useful tools are csvde, plus adfind/admod are powerful ad tools.... can be found here www.joeware.net