PS-Remoting Access Denied to Exchange

I have a lot of scripts which remotely connect to exchange using new-pssession and import-pssession This works on all but one machine. The ‘host’ exchange server must not have any restrictions apart from secure credentials either, because none of the other machines have specifically been given access So its definitely a problem on this one […]

Start-Job Assistance

Trying to experiment with Start-Job – i am not sure why this is not working $ScriptCode = { If (Test-Connection -ComputerName $ComputerName -Count 1) { Write-Host “$ComputerName – Pingable” } Else { Write-Host “$ComptuerName – Offline” } } ForEach ($Record in $File) { $ComputerName = $[Record.Computer](https://Record.Computer) Start-Job -ScriptBlock $ScriptCode -Name $ComputerName -ArgumentList $ComputerName } submitted […]

Help my script won’t start the spooler

$service = get-service -computername SERVER1 -name spooler get-date if ($service.status -eq ‘running’){write-host “Spooler currently running”} while ($service.status -ne ‘running’){ set-Service spooler -status running -passthru -computername SERVER1 write-host “current status =”$service.Status start-sleep -seconds 10 } submitted by /u/Wizard419 [link] [comments]