When creating a Program for a Package, there are essentially two Environment options for how the Program run – with the user’s rights, or with administrative rights. Using administrative rights will cause the program to run the command line under system context (svchost).
I recently needed to test an install (when running under system context and when running from the SCCM server) as I was unable to visually see the behavior first hand (e.g. errors). To do this type of testing, follow these simple instructions.
- Log in to Windows with an account that has admin privileges
- Launch cmd.exe
- Enter “time” and get the value.
- Enter “at time+1min /i cmd” – this will open another command prompt at that time
For example, if the time is 14:18, the value time+1min will be 14:19 - Once the next command prompt opens, you’ll notice that process listed in the title bar is ”svchost.exe”
- Enter “net use z: \\servername\share”
- Enter credentials that have access to the share, such as your own
- Then change to new driver letter and then to the directory. From there you can launch whatever .exe, .msi, script, etc, that you need visually see.
I used this process to confirm that executables and .msi files were being blocked with an Open File – Security Warning when running from a server share.


#1 by Nicolas Moseley on August 25, 2010 - 10:32 am
John Marcum has an easier alternative to testing in system context (using PSExec.) Check it out! – http://myitforum.com/cs2/blogs/jmarcum/archive/2010/08/25/150872.aspx