0

I have a SQL Server Agent job that is set to run as a domain user. It runs a node command and had been working with no issues for months.

Now every few days it fails to run with the following error

'The term 'node' is not recognized as the name of a cmdlet, function, script file, or operable program.'

It appears that it is failing to execute as the domain user. We can jump on and manually kick the job off and everytime that works.

@@VERSION: Microsoft SQL Server 2019 (RTM-CU22-GDR) (KB5029378) - 15.0.4326.1 (X64) Aug 18 2023 14:05:15 Copyright (C) 2019 Microsoft Corporation Standard Edition (64-bit) on Windows Server 2016 Standard 10.0 (Build 14393: ) (Hypervisor)

Any ideas on what the solution could be?

4
  • Who is the owner of the job?
    – J. Mini
    Commented Jan 24 at 8:19
  • I am. I've created the job and set the step to operating cmd and set the run as user of that to myself. Commented Jan 24 at 9:57
  • Does the account that owns the job have permissions on the node? It may not be the same account as the one that you use when you try to do the task manually.
    – J. Mini
    Commented Jan 24 at 10:56
  • Same account, I only have one login for the server so I've tied everything to that. Commented Jan 24 at 11:40

1 Answer 1

0

to my mind, the network token fails to renew, logging on to the server refreshes the token, and after it expires, it fails. Has your domain user got Login as a Service permissions? https://learn.microsoft.com/en-us/windows/security/threat-protection/security-policy-settings/log-on-as-a-service

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.