Scheduled Task Error 0x10

Iccz

Distinguished Member
Joined
Apr 29, 2008
Messages
24,138
Reaction score
6,646
Points
4,395
Age
38
Location
Keystone City
Basically i'm trying to use Robocopy on a W2K server to copy files from a mapped network drive (Z:\) to a drive on the local machine (X:\).

I've made a batch file with the following:

Robocopy Z:\Folder X:\Folder

Obviously the actual folder names differ.

Either way, this command works perfect via CMD, so I put the batch file up for a scheduled daily task, made a text file in Z:\Folder and ran the scheduled task, nothing. Nothing except the error code 0x10.

After the scheduled task failed I ran the batch file again, and the text file was copied over, I deleted it then tried the task again, nothing.

Googling around a little shows some people with a similar problem when using Robocopy, but I can't find a solution to it anywhere.

Anyone got any suggestions as to what I can try to fix this scheduled task as i'm a bit baffled now...

Cheers
:thumbsup:
 
Also for what it's worth all the log shows is:

Result: The task completed with an exit code of (10).

Net Helpmsg 16 (0x10)
Brings:

The directory cannot be removed.

Not much use as i'm not trying to move/remove a directory :thumbsdow


I must also add it is being run using Administrator with the correct password.
 
Last edited:
Permissions? Does robocopy.exe have the correct permissions to have unrestricted access? It may be worth editing the shares so that 'EVERYONE' is listed in the security permissions.
 
Permissions? Does robocopy.exe have the correct permissions to have unrestricted access? It may be worth editing the shares so that 'EVERYONE' is listed in the security permissions.

Will check that out tomorrow and let you know, as obvious as it is, the thought never passed my mind!
 
This sounds a bit like a situation I had where the batch file wouldn't run as a scheduled task because the account used to execute the scheduled task didn't have the permissions to read/execute the CMD.EXE program which thence executes the batch file.

Or maybe your UID/PW needs "rights" to "logon as a batch job."

Come to think of it, I can't remember whether TS let you "run" a .BAT file directly from TS, or whether you have to set up the task to execute CMD.EXE /C YOURBATFILE.BAT

MS boxes can be a bit "funny" about what they'll let the Administrator acct do - it's not always as "all powerful" as you might expect.


Incidently, I wouldn't use "Administrator" to do anything like this unless it was very temporary. Seen it happen where the Admin p/w gets changed subsequently, then months later some vital funtion that used Administrator credentials is discovered to have "stopped working" for reasons no one can figure out. I'd set up a new acct dedicated to this copy task with only the permissions required to complete the batch process.
 
This sounds a bit like a situation I had where the batch file wouldn't run as a scheduled task because the account used to execute the scheduled task didn't have the permissions to read/execute the CMD.EXE program which thence executes the batch file.

Or maybe your UID/PW needs "rights" to "logon as a batch job."

Come to think of it, I can't remember whether TS let you "run" a .BAT file directly from TS, or whether you have to set up the task to execute CMD.EXE /C YOURBATFILE.BAT

MS boxes can be a bit "funny" about what they'll let the Administrator acct do - it's not always as "all powerful" as you might expect.


Incidently, I wouldn't use "Administrator" to do anything like this unless it was very temporary. Seen it happen where the Admin p/w gets changed subsequently, then months later some vital funtion that used Administrator credentials is discovered to have "stopped working" for reasons no one can figure out. I'd set up a new acct dedicated to this copy task with only the permissions required to complete the batch process.

Yeah I was running it as admin as the user I tried first didn't work so I thought i'd give "god" a chance to see what happened then, was kinda hoping that the admin account would be okay with it.

Anyways it was a permission related problem, simply solved it by going into Properties for the batch file, going into compatability and checking the tick box for "Allow non-administrators to run this program" and changed my user on the task back to what it was, now it works perfectly, not sure what the problem was but still it's solved. Can't believe it was something so simple.

Cheers for the input :thumbsup:
 

The latest video from AVForums

Is 4K Blu-ray Worth It?
Subscribe to our YouTube channel
Back
Top Bottom