Windows 2008R2 server/computer or Windows 7 computers we can add to the domain without having any of the connectivity of the server(DNS or ActiveDirectory).
For this case we do not to raise any of the functional leval.(Forest or domain).This method is very much usefull when we are reinstalling the operating systems of the pcs on a separate location(Branch Office).Therefore we can use DJOIN.exe tool
We can get the help of the DJOIN command using typing djoin /help
from the server machine now we can run djoin command with required parameters
DJOIN /PROVISION /DOMAIN mydomain.lk /MACHINE MYPC1 /SAVE c:\mypc.txt
*domain name should be changed according to the your requirement
*machine name should be changed according to the you computers host name
*File exporting(Saving) location can be changed.
*This will creating computer objects in the computers container
now we should copy this file in to the client computer.
Now from the client computer we can run the djoin command with required parameters.
Now this computer is in the domain.