Commands via PowerShell working locally, but not via Automox.

  • 27 October 2021
  • 2 replies
  • 6 views

Have a few PowerShell scripts I’ve been testing and for some reason they will not work properly via an Automox policy, but if I run them locally they seem to work fine.


RDP Disable - Worklet


Set-ItemProperty -Path “HKLM:\System\CurrentControlSet\Control\Terminal Server” -Name “fDenyTSConnections” –Value 1


Teams Install - Required Software


Start-Process -FilePath “Teams_windows_x64.exe” -ArgumentList “-s” -Wait -PassThru


To my knowledge the Automox agent is supposed to run all the PowerShell commands as SYSTEM which should have elevated privileges. Was hoping to see if anyone else has run into this and what I can do to resolve it?


Thanks in advance.


2 replies

Maybe piping some user context and your output to a test log might help you to understand what’s happening behind the scenes? Something like


start-transcript C:\windows\temp\mytest.log

whoami / whatever

stop-transcript

My experience with Teams was that it tended to install as “user”, and seem to cause problems when trying to install as admin for all users. you might want to look as that aspect.

Reply