Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I need to create a startup script on a server that is live in production, so unfortunately I don't have the luxury of trial and error.

I need to start an application upon server bootup that is run as a particular service account. I need the same instance of that application to be accessible when I manually log into the server later using that same account. If I use 'runas' or something else (suggestions?) will the application be running in that profile, or just running in the background as a process I can see in task manager?

If the latter, what options do I have to set the app to run automatically upon startup and be available when I log in? Logging that service account in as part of the startup process is fine if needed.

share|improve this question
5  
This is a site for IT Professionals, who tend to have the ability to test scripts etc. on non-production systems, as that's one of the things that differentiates being a professional - try harder to have offline testing capabilities or don't come here. –  Chopper3 Jul 10 '13 at 13:28
2  
Your test environment doesn't need to be a replicated datacenter. Get a VM or an old PC on the network and test a few things out. And, "Logging that service account in as part of the startup process is fine if needed." is never a good idea if you can avoid it. –  TheCleaner Jul 10 '13 at 13:41

1 Answer 1

You can't run a program outside of a session and then "import" it into a session. You have to create a session (auto-login or similar) and then run the application inside it. Once that is done you can login to that session and see the application. You'll either want to force one session per user (Group Policy setting) or the tscon command to switch into the session.

share|improve this answer

Your Answer

 
discard

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.