Script to add computers to AD overwrites existing names???

Welcome Forums General PowerShell Q&A Script to add computers to AD overwrites existing names???

This topic contains 4 replies, has 2 voices, and was last updated by

 
Participant
1 year, 11 months ago.

  • Author
    Posts
  • #57218

    Participant
    Points: 0
    Rank: Member

    I've got a script that creates and then adds computers to AD based on certain characteristics of the user. It auto generates a name then checks AD to see if the name is available if not it generates an other name and so on until it finds a free name. At least that is what it is supposed to do. The last 2 times I've run it, its decided that a name already in use is ok to take. I didn't know it was even possible to add a name to AD that already existed.
    So, I'm not sure if this is a PowerShell thing or an AD thing. Anyone experienced this?

  • #57226

    Participant
    Points: 0
    Rank: Member

    So AD has 2 objects with the same name? How do you know it "took" the existing name?

    Code would probably help, too, btw...

  • #57229

    Participant
    Points: 0
    Rank: Member

    Ya so, um, the thing is this...apparently someone in my organization was going through and "cleaning out" old or apparently unused names. So if we could just pretend this never happened...

    • #57248

      Participant
      Points: 0
      Rank: Member

      "I know nothing! I see nothing! I hear nothing!" – Sgt. Schultz

  • #57262

    Participant
    Points: 0
    Rank: Member

    Thanks!
    I was going nuts trying to figure out how the heck a script could overwrite a name already in AD!!

    Someone isn't getting a Christmas card this year!

The topic ‘Script to add computers to AD overwrites existing names???’ is closed to new replies.