I get this error:
"reason: Error authenticating proxy domain\user, system error: Logon failure: unknown user name or bad password."
This happens when I start my SQL 2008 Agent job that I created.
The job is owned by my domain account, I have full sysadmin rights on the SQL 08 install.
This is running on my local machine (for dev/testing).
There is 1 step which runs a PowerShell script:
function Remove-OldFiles($folder, $logFile, $filter, $age)
{
Get-ChildItem $folder* -Include $filter -Exclude $logFile |
? { $_.LastWriteTime -le (Get-Date).AddMinutes(-$age) } |Remove-Item -verbose
}
Remove-OldFiles '\\server-name\c$\PSHtest\' 'DeleteLog.txt' *.txt, *.xml 3
It runs as a proxy account.
This proxy account is allowed to use the PowerShell subsystem only and as my domain account is part of sysadmin I have not assigned it to the proxy account principals list.
The proxy account uses a credential that is just my own domain account.
If I use the SQL Agent account to run the script the job does NOT fail, but the script itself cannot execute and returns the error:
"The error information returned by PowerShell is: 'An object at the specified path \servername\c$\PSHtest does not exist. "
Which is why I assigned a proxy to run, a proxy that has access to that part of the network for testing.
Suggestions on how I can correct this?
I've seen pages that say this error may be due to the service account not being enabled for delegation. Could that be the cause of this problem?
I am not familiar with the details of delegation so if that is the reason behind it a brief explanation would be greatly appreciated.
Thank you!