Run New-PSSession as Scheduled Task

An internal error occurred. PSInvalidOperationException + FullyQualifiedErrorId : CreateRemoteRunspaceFailed After literally 2 hours bashing my head why a scheduled task would not run as a service account. But worked fine with normal account. Granting the ‘Allow log on as batch job’, ‘Allow log on locally’, and even adding the account to the Local Administrators group […]

Continue Reading

Shadow RDS Session PS Script for Helpdesk Staff

I wrote this PowerShell script so that our Helpdesk staff were able to view the Remote Desktop Sessions on our 2012 RDS Hosts and shadow them. https://github.com/Nostalgiac/Scripts/blob/master/Shadow-RDSSession.ps1 The script queries the RDS farm with Get-RDUserSession by invoking this command on your Mangement Server (that has the RDS Tools installed), then starts mstsc with the appropriate session ID […]

Continue Reading