Datto RMM: How Do I Log In as a Local System User to Test Scripts?



How do I log in as a system user to test scripts locally?


  • Datto RMM


To verify that custom scripts can run outside the Datto RMM environment, you must run them as a local system user. Running scripts as a regular user will not give accurate results.


1. Go to Run and type cmd to open a command window. Open the first command prompt using the Run As option, and choose Run as administrator.

Figure 1: The command prompt (click to enlarge)

2. Navigate to the directory where you downloaded PsExec:

cd Desktop\PsTools

9272d12ec58dad88c3a11aa56193c4a93d9aa36ffd9fa19c2738824845abfab2.pngFigure 2: The PsTools directory (click to enlarge)

3. Run the PsExec tool to invoke a new command prompt as the local system user. Commands typed in this window will be on the local system user level.

psexec.exe -hsi cmd.exe

f3277cf4c5777e61d1fe66a87425fb81df67c2ec18953de577f958a2fb0d2ac3.pngFigure 3: The local system command prompt (click to enlarge)

4. In the new command window, type whoami to verify you are running as the local system user. You can now test the script. 

Additional resources

Was this article helpful?

0 out of 0 found this helpful

You must sign in before voting on this article.

Want to talk about it? Have a feature request?

Head on over to our Datto Community Forum or the Datto Community Online.

For more Business Management resources, see the Datto RMM Online Help and the Autotask PSA Online Help .

Still have questions? Get live help.

Datto Homepage