Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there a possibility to do this? I want to run a script that defines my network drivers and runs an .exe after it joined the domain.

share|improve this question

You can redirect the default container of computers in your AD, and then apply there a GPO that runs a startup script.

After that you should move the new computer object somewhere else.

If moving the computer is not an option, you could make the script leave a semaphore file behind, so next time you'll be able to recognize in the script whether it already ran once.

share|improve this answer
I found something usefull on that site, but do you if its possible to only run a logon script on the first time the user joins the domain. And not anymore afterwards that – joostmakaay Dec 11 '13 at 15:03
I assume you meant (computer) startup script and not (user) logon script. As I've mentioned above, the best way would be to move the new computer object from the default OU to another one. If that's not an option, the you could config the script, using a semaphore file, to run just once. – EliadTech Dec 12 '13 at 12:16

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.