Scheduled task failing

  • Hello,

    We are trying to run a scheduled task to copy the .BAK files from a SQL 7.0 server to a failover SQL 7.0 server (both running on Windows NT boxes). The scheduled task kicks off a .bat file which contains the following:

    copy *.bak \\qrm\g$\mssql7\backup

    QRM is the fail-over box, and the G:\ is its drive that is mapped to an EMC SAN. The problem is, when the time comes for the scheduled task to run, it doesn't run and the message "Could not run" is displayed in the Status column of the Scheduled Tasks list.

    Any ideas?

    Thanks

  • The first thing to check is to ensure the user account under which SQL Server Agent is running has rights to access the G$ share. Typically drive shares like this are for administrator level accounts only.

    K. Brian Kelley

    bkelley@sqlservercentral.com

    http://www.truthsolutions.com/

    K. Brian Kelley
    @kbriankelley

  • Yes, the scheduled task is set to run under administrator rights, giving full read/write access to the G:\ drive.

  • Can you post the full text of what is contained in the job step history for the last job step to try and execute?

    K. Brian Kelley

    bkelley@sqlservercentral.com

    http://www.truthsolutions.com/

    K. Brian Kelley
    @kbriankelley

  • Check the schedlgu.txt file which is the log file for the scheduler. See if it's a login issue. If it is and If you're running ASP .NET framework on this server then the issue may be there.

    I changed my "local security policy" to allow for the ASPNET user to "log on as batch job" rights. When I did this it made it so the only user that had these rights were the ASPNET user. Even the local admin didn't have rights. My suggestion is to check your security policy. I tracked my problem down to every time the policy ran the scheduled tasks would quit working. If you've changed your security policy to allow a user to "log on as batch job" then all users that need this must have it (like domain/administrator) If you're using .NET and you've followed the instructions in the MSDN help to use this method so your ASP .NET pages will work, I suggest using the other method in the machine.config processModel section, setting user=SYSTEM.

    In Short..CHECK YOUR SECURITY POLICY!! if it has changed then this may be the issue!

    Petey

Viewing 5 posts - 1 through 4 (of 4 total)

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