Go Back   TechArena Community > Technical Support > Computer Help > Windows Server > Windows Server Help
Become a Member!
Forgot your username/password?
Tags Active Topics RSS Search Mark Forums Read

Sponsored Links



Scheduled Task - Can Not Start

Windows Server Help


Reply
 
Thread Tools Search this Thread
  #1  
Old 06-06-2007
Matt Colegrove
 
Posts: n/a
Scheduled Task - Can Not Start

I have a Win2k3 server and I have 3 scheduled tasks. All three tasks are
configured to use the same local account that has ordinary user level priv.
Two of the tasks execute an EXE file run fine. The local account has Modify
permissions to the folder where the exe file resides.

The third task, which fails to run (Cannot run job), is configured to run a
..BAT file in the same local directory, from the same local account. If I
make the local account a member of the Admin group, the task will run. When
the local account has regular user level privs, it won't run. Log file says
error 80070005 - Access Denied.

The batch files contains the following commands (paraphrased)
------------------------------
echo logs stuff to a log file > log.txt
rem Change to folder
D:
CD \folder1\subfolder1
COPY file1 folder --makes backup copies of a couple of files
App.exe --runs the same .exe file as the other two tasks
--------------------------------

I really want to be able to run this third task without adding Admin privs
to the local account. Is there a way to configure this task to run from the
local account without adding admin priv?


Reply With Quote
  #2  
Old 06-06-2007
Jabez Gan [MVP]
 
Posts: n/a
Re: Scheduled Task - Can Not Start

Does this user has Read + Executable permission on the .BAT file?

--
Jabez Gan [MVP]
Microsoft MVP: Windows Server
http://www.blizhosting.com
MSBLOG: http://www.msblog.org

"Matt Colegrove" <MattColegrove@discussions.microsoft.com> wrote in message
news:98BF1EE1-E0D6-4C81-8914-1B7C81C6D16E@microsoft.com...
>I have a Win2k3 server and I have 3 scheduled tasks. All three tasks are
> configured to use the same local account that has ordinary user level
> priv.
> Two of the tasks execute an EXE file run fine. The local account has
> Modify
> permissions to the folder where the exe file resides.
>
> The third task, which fails to run (Cannot run job), is configured to run
> a
> .BAT file in the same local directory, from the same local account. If I
> make the local account a member of the Admin group, the task will run.
> When
> the local account has regular user level privs, it won't run. Log file
> says
> error 80070005 - Access Denied.
>
> The batch files contains the following commands (paraphrased)
> ------------------------------
> echo logs stuff to a log file > log.txt
> rem Change to folder
> D:
> CD \folder1\subfolder1
> COPY file1 folder --makes backup copies of a couple of files
> App.exe --runs the same .exe file as the other two tasks
> --------------------------------
>
> I really want to be able to run this third task without adding Admin privs
> to the local account. Is there a way to configure this task to run from
> the
> local account without adding admin priv?
>


Reply With Quote
  #3  
Old 08-06-2007
Matt Colegrove
 
Posts: n/a
Re: Scheduled Task - Can Not Start

Yes. The local account has read/execute on the batch file.

It turns out there is a knowledgebase article on this one, though I can't
recall the number. The fix is to go to the CMD.EXE file in \windows\system32
and give the local account read/execute permissions on the CMD.EXE file.
After that, the task scheduler will be able to launch the batch file under
the local account.

"Jabez Gan [MVP]" wrote:

> Does this user has Read + Executable permission on the .BAT file?
>
> --
> Jabez Gan [MVP]
> Microsoft MVP: Windows Server
> http://www.blizhosting.com
> MSBLOG: http://www.msblog.org
>
> "Matt Colegrove" <MattColegrove@discussions.microsoft.com> wrote in message
> news:98BF1EE1-E0D6-4C81-8914-1B7C81C6D16E@microsoft.com...
> >I have a Win2k3 server and I have 3 scheduled tasks. All three tasks are
> > configured to use the same local account that has ordinary user level
> > priv.
> > Two of the tasks execute an EXE file run fine. The local account has
> > Modify
> > permissions to the folder where the exe file resides.
> >
> > The third task, which fails to run (Cannot run job), is configured to run
> > a
> > .BAT file in the same local directory, from the same local account. If I
> > make the local account a member of the Admin group, the task will run.
> > When
> > the local account has regular user level privs, it won't run. Log file
> > says
> > error 80070005 - Access Denied.
> >
> > The batch files contains the following commands (paraphrased)
> > ------------------------------
> > echo logs stuff to a log file > log.txt
> > rem Change to folder
> > D:
> > CD \folder1\subfolder1
> > COPY file1 folder --makes backup copies of a couple of files
> > App.exe --runs the same .exe file as the other two tasks
> > --------------------------------
> >
> > I really want to be able to run this third task without adding Admin privs
> > to the local account. Is there a way to configure this task to run from
> > the
> > local account without adding admin priv?
> >

>
>

Reply With Quote
  #4  
Old 08-06-2007
Jabez Gan [MVP]
 
Posts: n/a
Re: Scheduled Task - Can Not Start

Thanks for the update Matt!

--
Jabez Gan [MVP]
Microsoft MVP: Windows Server
http://www.blizhosting.com
MSBLOG: http://www.msblog.org

"Matt Colegrove" <MattColegrove@discussions.microsoft.com> wrote in message
news:F14BF727-E34B-423D-B510-961808ED2283@microsoft.com...
> Yes. The local account has read/execute on the batch file.
>
> It turns out there is a knowledgebase article on this one, though I can't
> recall the number. The fix is to go to the CMD.EXE file in
> \windows\system32
> and give the local account read/execute permissions on the CMD.EXE file.
> After that, the task scheduler will be able to launch the batch file under
> the local account.
>
> "Jabez Gan [MVP]" wrote:
>
>> Does this user has Read + Executable permission on the .BAT file?
>>
>> --
>> Jabez Gan [MVP]
>> Microsoft MVP: Windows Server
>> http://www.blizhosting.com
>> MSBLOG: http://www.msblog.org
>>
>> "Matt Colegrove" <MattColegrove@discussions.microsoft.com> wrote in
>> message
>> news:98BF1EE1-E0D6-4C81-8914-1B7C81C6D16E@microsoft.com...
>> >I have a Win2k3 server and I have 3 scheduled tasks. All three tasks
>> >are
>> > configured to use the same local account that has ordinary user level
>> > priv.
>> > Two of the tasks execute an EXE file run fine. The local account has
>> > Modify
>> > permissions to the folder where the exe file resides.
>> >
>> > The third task, which fails to run (Cannot run job), is configured to
>> > run
>> > a
>> > .BAT file in the same local directory, from the same local account. If
>> > I
>> > make the local account a member of the Admin group, the task will run.
>> > When
>> > the local account has regular user level privs, it won't run. Log file
>> > says
>> > error 80070005 - Access Denied.
>> >
>> > The batch files contains the following commands (paraphrased)
>> > ------------------------------
>> > echo logs stuff to a log file > log.txt
>> > rem Change to folder
>> > D:
>> > CD \folder1\subfolder1
>> > COPY file1 folder --makes backup copies of a couple of files
>> > App.exe --runs the same .exe file as the other two tasks
>> > --------------------------------
>> >
>> > I really want to be able to run this third task without adding Admin
>> > privs
>> > to the local account. Is there a way to configure this task to run
>> > from
>> > the
>> > local account without adding admin priv?
>> >

>>
>>


Reply With Quote
Reply

  TechArena Community > Technical Support > Computer Help > Windows Server > Windows Server Help
Tags:



Thread Tools Search this Thread
Search this Thread:

Advanced Search


Similar Threads for: "Scheduled Task - Can Not Start"
Thread Thread Starter Forum Replies Last Post
Windows Scheduled Task: Unable to start task. 0x80070005: Access is denied. BCU_AJones Windows Software 3 17-01-2014 10:37 AM
Scheduled Task does not run coreymac1222 Windows XP Support 3 06-03-2009 02:06 AM
Can't run scheduled task alicorn2 Windows Server Help 8 22-04-2008 05:07 AM
Unable to start scheduled task after creating it with Schtasks Flea# Windows Server Help 7 09-03-2008 05:56 AM
Scheduled Task error code:The task completed with an exit code of Teo Chee Yang Windows Server Help 7 26-02-2007 06:01 PM


All times are GMT +5.5. The time now is 05:27 AM.