Testing Code Segments in a Non-Critical Environment

   

Testing Code Segments in a Non-Critical Environment

Establishing a test environment is critical to the successful development of large-scale ADSI operations that invoke the SetInfo method of the IADs interface. It is far too risky to develop ADSI code that can affect the entire scope of your administrative rights within a production environment.

If you have access to a test environment, you will want to make sure that you test your code segments there before attempting to use your code in a production domain. You wield an incredible amount of power with ADSI and Visual Basic ”a small coding error can yield potentially catastrophic results reaching to the farthest extent of your administrative privileges in the enterprise. A loop operation to delete all accounts in the user domain may take only a few moments to execute, but could create many hours of work for the disaster recovery team if performed accidently.

Although the underlying APIs still enforce the rules within each namespace, Windows NT depends largely on the administrative tool user interfaces to prevent unexpected results. A malformed ADSI statement could potentially create an object in the namespace that you are unable to delete or access using the GUI tools. This makes an even more compelling case for maintaining a disparate testing and development environment.

If you do not have a formal test environment, set up an isolated PDC that you do not mind re-staging if you corrupt the namespace with a malformed procedure. The only way to reduce the risk of making catastrophic mistakes in a production environment is to assure that your code works as expected in a testing environment.

Warning

Take time now to establish a proper development and test environment before continuing with the following exercises.



   
Top


Windows NT. 2000 ADSI Scripting for System Administration
Windows NT/2000 ADSI Scripting for System Administration
ISBN: 1578702194
EAN: 2147483647
Year: 2000
Pages: 194
Authors: Thomas Eck

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net