Running powershell in System Context

Hi Team,

Kindly help me running powershell in system context i.e. using NT AUTHORITY\SYSTEM without using psexec tool.
I have to run dsregcmd /debug command, kindly suggest any alternative.

Thanks,

you could call your script from a scheduled task running as system

Thanks a lot Simon for quick response. I’ll try running it as task scheduler, but in case if task scheduler is not a option, do we have any other alternative?

Another option you may try from this blog, I know it is for cmd.exe but should still work for powershell

https://www.interfacett.com/blogs/two-ways-to-launch-a-windows-command-prompt-as-user-system/