Add-ADSubnet (ADSI Function)

This function allow you to add a subnet object in your active directory using ADSI

 
 
 
 
 
5 Star
(5)
5,203 times
Add to favorites
Active Directory
6/15/2015
E-mail Twitter del.icio.us Digg Facebook
  • Why do I keep a violation error?
    5 Posts | Last post May 25, 2016
    • VERBOSE: 10.x.x.x/24 - Creating the subnet object...
      WARNING: An error happened while creating the subnet: 10.x.x.x/24
      Exception calling "setinfo" with "0" argument(s): "A constraint violation occurred.
    • The subnet file I was using was a dump from a previous AD, I just discovered that some of the sites where misspelled. The function could not find the "Site4" since it was written "Siite4". That caused the violation error.
      Thank you for your script, imported aprox. 400 subnets with ease.
    • Hi! Thanks for your comment :-)
      Nice to hear that you resolved your issue!
      
      FX
    • It helps to have the Sites (FX2, FX3, MTL1) created before running the script 
    • Yes, your sites need to exist prior to run the script.
  • A litle fix
    2 Posts | Last post June 15, 2015
    • Hi François!
      
      Just change the picture to reflect the correct function name: Add-ADSubnet and not Add-ADSISubnet.
      
      A good point too is refeer to load the ps1 using Dot Sourcing
      
      Thanks!
    • Thanks for your comment Caio!
      I updated the post, I hope this is more clear ;-)
      
      Thanks again