SQL Server 2025 Jobs

  • Hello

    SQL Server 2022 16.0.4212.1 running on a Windows Server 2025 Std,V 24H2, SO OS build 26100.6584.

    SQL Agent service account: NT Service\SQLSERVERAGENT

    I have a series of jobs whose steps call SP of the same database.

    One of them scheduled to run at a specific time fails: "Job failed. The job was invoked by Schedule 9 (06:00 xxxxx). The last step to execute was step 0 (no steps ran)."

    Job steps: exec SP_01

    GO

    EXEC SP_02

    But if I run it manually, it runs without problems. Can anyone help me?

    Thank in advanced

  • Check the job history. That'll probably tell you what's wrong. BUT as a guess, does your SQL Agent service account have permission to run that SP?

    I would recommend changing the service account to be a domain account so it can access domain resources. Plus better password management and easier to debug issues and assign permissions to resources. On top of that, if you need to migrate to a new server, there should be no need to adjust permissions or anything - the domain account can retain the same SID when you migrate (if you do it right) whereas anything local to that machine will need to get a new SID and thus the user-login mapping will break and need to be recreated.

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply