Quantcast
Channel: Active questions tagged windows - Super User
Viewing all articles
Browse latest Browse all 9673

Initialize user session at Windows Server startup

$
0
0

My company uses Windows Server 2019 Datacenter. I have a scheduled task that runs a Jekyll reporting server, which keeps the command prompt open to output any error messages. I also have a service account that anyone on the IT team can log into to view errors when errors occur.

The scheduled task will only display the command prompt if the service account is already logged in when the task executes. If I choose "Run whether user is logged on or not" then cmd doesn't display for the service account.

Is there a way to write a script or Powershell command to automate logging into the server as the service account?

The idea is to create the session so that the scheduled task can be changed to run on the service account and have the cmd window appear. The service account is not a default account, and I'd rather not change registry settings to make it so. Wanted to figure out an easy way before editing Jekyll code and dumping errors to error logs.


Viewing all articles
Browse latest Browse all 9673

Trending Articles