PC Review


Reply
Thread Tools Rate Thread

Run batch w/o log on

 
 
=?Utf-8?B?RGFubQ==?=
Guest
Posts: n/a
 
      14th Jul 2007
I have two simple batch files A & B. Both are scheduled to run at night
without anyone logged on. Both work when I am logged on as Administrator,
have the same permissions, and the same "Run as" parameters.

A simply runs an exe file (virus scan) and works well.
B contains a simple copy command to copy a file from C:\ to a network drive.
It does not run with administrator logged off. I have tried to reference
the network drive by its mapped letter and by its \\computername\share path.

The OS is Windows Server 2003

I hope there is something simple I am missing that someone can help me with.


 
Reply With Quote
 
 
 
 
Vanguard
Guest
Posts: n/a
 
      14th Jul 2007
"Danm" wrote in message
news:A9C0311D-74BC-4848-A9EE-(E-Mail Removed)...
>I have two simple batch files A & B. Both are scheduled to run at
>night
> without anyone logged on. Both work when I am logged on as
> Administrator,
> have the same permissions, and the same "Run as" parameters.
>
> A simply runs an exe file (virus scan) and works well.
> B contains a simple copy command to copy a file from C:\ to a network
> drive.
> It does not run with administrator logged off. I have tried to
> reference
> the network drive by its mapped letter and by its \\computername\share
> path.
>
> The OS is Windows Server 2003
>
> I hope there is something simple I am missing that someone can help me
> with.
>
>



Make sure of the following:

Run only when logged in = disabled
Enabled = enabled
Wake the computer to run this task = enabled

 
Reply With Quote
 
=?Utf-8?B?RGFubQ==?=
Guest
Posts: n/a
 
      14th Jul 2007
Thanks for the suggestion, Vanguard. The first two were in effect. I
enabled Wake the computer... But no joy.

"Vanguard" wrote:

> "Danm" wrote in message
> news:A9C0311D-74BC-4848-A9EE-(E-Mail Removed)...
> >I have two simple batch files A & B. Both are scheduled to run at
> >night
> > without anyone logged on. Both work when I am logged on as
> > Administrator,
> > have the same permissions, and the same "Run as" parameters.
> >
> > A simply runs an exe file (virus scan) and works well.
> > B contains a simple copy command to copy a file from C:\ to a network
> > drive.
> > It does not run with administrator logged off. I have tried to
> > reference
> > the network drive by its mapped letter and by its \\computername\share
> > path.
> >
> > The OS is Windows Server 2003
> >
> > I hope there is something simple I am missing that someone can help me
> > with.
> >
> >

>
>
> Make sure of the following:
>
> Run only when logged in = disabled
> Enabled = enabled
> Wake the computer to run this task = enabled
>
>

 
Reply With Quote
 
Vanguard
Guest
Posts: n/a
 
      14th Jul 2007
"Danm" <(E-Mail Removed)> wrote in message
news:41742D07-1FDA-4980-A8E9-(E-Mail Removed)...
> Thanks for the suggestion, Vanguard. The first two were in effect. I
> enabled Wake the computer... But no joy.
>
> "Vanguard" wrote:
>
>> "Danm" wrote in message
>> news:A9C0311D-74BC-4848-A9EE-(E-Mail Removed)...
>> >I have two simple batch files A & B. Both are scheduled to run at
>> >night
>> > without anyone logged on. Both work when I am logged on as
>> > Administrator,
>> > have the same permissions, and the same "Run as" parameters.
>> >
>> > A simply runs an exe file (virus scan) and works well.
>> > B contains a simple copy command to copy a file from C:\ to a
>> > network
>> > drive.
>> > It does not run with administrator logged off. I have tried to
>> > reference
>> > the network drive by its mapped letter and by its
>> > \\computername\share
>> > path.
>> >
>> > The OS is Windows Server 2003
>> >
>> > I hope there is something simple I am missing that someone can help
>> > me
>> > with.
>> >
>> >

>>
>>
>> Make sure of the following:
>>
>> Run only when logged in = disabled
>> Enabled = enabled
>> Wake the computer to run this task = enabled
>>
>>



All scheduled tasks run under an account. If you want to ensure the
script has the same permissions as Administrator then make sure you
specify the Administrator account and its correct login password in the
security for the scheduled task.

So what does the log show for that scheduled task? Advanced -> View Log
menu.

 
Reply With Quote
 
=?Utf-8?B?RGFubQ==?=
Guest
Posts: n/a
 
      14th Jul 2007


"Vanguard" wrote:

> "Danm" <(E-Mail Removed)> wrote in message
> news:41742D07-1FDA-4980-A8E9-(E-Mail Removed)...
> > Thanks for the suggestion, Vanguard. The first two were in effect. I
> > enabled Wake the computer... But no joy.
> >
> > "Vanguard" wrote:
> >
> >> "Danm" wrote in message
> >> news:A9C0311D-74BC-4848-A9EE-(E-Mail Removed)...
> >> >I have two simple batch files A & B. Both are scheduled to run at
> >> >night
> >> > without anyone logged on. Both work when I am logged on as
> >> > Administrator,
> >> > have the same permissions, and the same "Run as" parameters.
> >> >
> >> > A simply runs an exe file (virus scan) and works well.
> >> > B contains a simple copy command to copy a file from C:\ to a
> >> > network
> >> > drive.
> >> > It does not run with administrator logged off. I have tried to
> >> > reference
> >> > the network drive by its mapped letter and by its
> >> > \\computername\share
> >> > path.
> >> >
> >> > The OS is Windows Server 2003
> >> >
> >> > I hope there is something simple I am missing that someone can help
> >> > me
> >> > with.
> >> >
> >> >
> >>
> >>
> >> Make sure of the following:
> >>
> >> Run only when logged in = disabled
> >> Enabled = enabled
> >> Wake the computer to run this task = enabled
> >>
> >>

>
>
> All scheduled tasks run under an account. If you want to ensure the
> script has the same permissions as Administrator then make sure you
> specify the Administrator account and its correct login password in the
> security for the scheduled task.
>
> So what does the log show for that scheduled task? Advanced -> View Log
> menu.
>
> Joy! I looked at the log; there was no entry, apparently because I ran it the last time as a .cmd file - one of the changes I tried.

So, I changed it back to a .bat file and carefully rescheduled the run. It
worked!
Then I changed the network storage path back to the mapped letters. UNC is
supposed to be recognized, but it failed. Then I went back to the
\\networkname\.. path and it worked again.
Apparently it likes the "Wake the computer..." enabled and the non-UNC path.
To answer your question about the log, it is pasted below (0) is good; (1)
is not:
"ctest.job" (ctest.bat)
Finished 7/14/2007 2:45:00 PM
Result: The task completed with an exit code of (0).
Many thanks for your help.
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
A script/batch to kill a batch file from scheduled tasks? Bogdan Windows XP Configuration 1 31st Jul 2009 07:05 AM
batch file call from a macro - how ? and required batch format VB-rookie Microsoft Excel Programming 3 5th Sep 2008 11:33 PM
calling multiple batch files from within a batch file yawnmoth Windows XP General 3 26th May 2008 07:47 PM
Save batch window msgs to a file from the batch prog Stephen Rainey Windows XP General 3 10th Jan 2007 01:50 AM
Photo Editor Batch supporting batch compression JPG files 29150 Freeware 2 23rd Jun 2003 07:02 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 07:06 PM.