• Re: Scheduled task with a UNC path

    Author
    Topic
    #402330

    This is related to a problem I’ve posted in W2000, but is on a NT server machine..
    When a batch file is being run by the scheduler on myserver I get the following message:

    pushd myserverpath
    Access is denied

    I’m sure this is easy to fix but don’t know quite what setting to change. When I look in services >Task Scheduler> “Log on as System” is selected and greyed out, and so I can’t change it to log on using any other account (but the help suggests that the scheduler is one service that is often configured to log on as a a different account!)
    Any suggestions most welcome.
    Marty

    Viewing 1 reply thread
    Author
    Replies
    • #799653

      If you look in Control Panel => Services, do you find “Schedule” or “Task Scheduler”?

      • #800081

        In Control Panel > Services, it says “Task Scheduler”.
        The machine is NT4 server sp6a IE6.0, and from a microsoft KB I expected to find the service “Scheduler” which it is not.

        Marty

        • #800245

          Somewhere around IE4.01 or IE5 Microsoft included the replacement of Schedule by Task Scheduler as part of the installation of the new IE. You can still use the AT commands, but they get subsumed into Task Scheduler tasks/jobs.

          Have a look at Control Panel => Scheduled Tasks => Advanced => AT service account and you can probably change things there. Alternatively, asso in Scheduled Tasks, highlight the Task you want to play with, right click for Propertiesand change the Run As account (or have you already been here?!).

          • #800591

            I’d read about the replacement etc but the only place I see it is in services. I don’t have Control Panel > Scheduled Tasks for some reason (sanity check: administrator). So unfortunately, I haven’t “been there” because I can’t find “there”! Would a reapplication of sp6 and / or IE6 be indicated here?
            One issue will be that tasks are being created by a batch file (which is itself scheduled), and these new tasks will need to have network access as well. Hopefully I can give all tasks a useful Run As default.

            • #800613

              I think you can see the tasks with Windows Explorer in %windir%tasks

              Joe

              --Joe

            • #801391

              Joe,

              I can see the task in this location. When I look at the properties it says the task will run as MachineNameAdministrator. This isn’t the same as “log on as system” which I see in the services properties. The machine is a server but we don’t have a domain (no, don’t ask..). I presume that the machine administrator on the server has network access. I appreciate this is not true in the world of domains.
              I am loath to use the properties interface as I understand this precludes use of the command line for further control.
              Also, I presume I can’t use this method to set the defaults for the scheduled tasks that are created on the fly (and will be long gone by the time I come to see them).

              Martin

            • #801731

              Martin, Is there a local account named ‘administrator’? If so, in what groups does it belong? Does it have access to the path you want?

              Joe

              --Joe

            • #802500

              Joe,
              All appears well with the administrator account (happily, a member of the administrators group) and the following comes from the command prompt (machine name changed to MyServer)

              COMPUTERNAME=MyServer
              LOGONSERVER=MyServer
              USERDOMAIN=MyServer
              USERNAME=administrator
              c:>pushd MyServerAppsPath
              z:>pushd OtherServerDataPath
              y:>popd
              z:>popd
              c:>

              So it has the network access as required. I still think that the schedule is running as local system and I think I need a way to change that globally for all schedules, rather than on a one by one basis.
              Martin

            • #802501

              Joe,
              All appears well with the administrator account (happily, a member of the administrators group) and the following comes from the command prompt (machine name changed to MyServer)

              COMPUTERNAME=MyServer
              LOGONSERVER=MyServer
              USERDOMAIN=MyServer
              USERNAME=administrator
              c:>pushd MyServerAppsPath
              z:>pushd OtherServerDataPath
              y:>popd
              z:>popd
              c:>

              So it has the network access as required. I still think that the schedule is running as local system and I think I need a way to change that globally for all schedules, rather than on a one by one basis.
              Martin

            • #801732

              Martin, Is there a local account named ‘administrator’? If so, in what groups does it belong? Does it have access to the path you want?

              Joe

              --Joe

            • #801392

              Joe,

              I can see the task in this location. When I look at the properties it says the task will run as MachineNameAdministrator. This isn’t the same as “log on as system” which I see in the services properties. The machine is a server but we don’t have a domain (no, don’t ask..). I presume that the machine administrator on the server has network access. I appreciate this is not true in the world of domains.
              I am loath to use the properties interface as I understand this precludes use of the command line for further control.
              Also, I presume I can’t use this method to set the defaults for the scheduled tasks that are created on the fly (and will be long gone by the time I come to see them).

              Martin

            • #800614

              I think you can see the tasks with Windows Explorer in %windir%tasks

              Joe

              --Joe

          • #800592

            I’d read about the replacement etc but the only place I see it is in services. I don’t have Control Panel > Scheduled Tasks for some reason (sanity check: administrator). So unfortunately, I haven’t “been there” because I can’t find “there”! Would a reapplication of sp6 and / or IE6 be indicated here?
            One issue will be that tasks are being created by a batch file (which is itself scheduled), and these new tasks will need to have network access as well. Hopefully I can give all tasks a useful Run As default.

        • #800246

          Somewhere around IE4.01 or IE5 Microsoft included the replacement of Schedule by Task Scheduler as part of the installation of the new IE. You can still use the AT commands, but they get subsumed into Task Scheduler tasks/jobs.

          Have a look at Control Panel => Scheduled Tasks => Advanced => AT service account and you can probably change things there. Alternatively, asso in Scheduled Tasks, highlight the Task you want to play with, right click for Propertiesand change the Run As account (or have you already been here?!).

      • #800082

        In Control Panel > Services, it says “Task Scheduler”.
        The machine is NT4 server sp6a IE6.0, and from a microsoft KB I expected to find the service “Scheduler” which it is not.

        Marty

    • #799654

      If you look in Control Panel => Services, do you find “Schedule” or “Task Scheduler”?

    Viewing 1 reply thread
    Reply To: Re: Scheduled task with a UNC path

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: