Re: MS Scheduled Task
- From: "Wojo" <wojcik87@xxxxxxxxx>
- Date: 30 Nov 2006 15:30:25 -0800
Pegasus,
I do get the following test.log after moving the bat file to my C
drive. As I mentioned earlier a test.log
is not created when the bat file is located on the network:
Thu 11/30/2006 17:11:24.58 Start of task
User=nbkr9hh,
Path=\\neon\binlib\dll\sql11.1.1\bin;\\neon\binlib\dll\sql11.1.1\dll;;C:\WINNT;C:\WINNT\System32;\\radon\binlib\dll\sql12\OCS-12_0\dll;\\radon\binlib\dll\sql12\OCS-12_0\bin;C:\WINNT\System32\Wbem;C:\Program
Files\Microsoft SQL Server\80\Tools\BINN;c:\lim\vbapi;c:\Program
Files\Rational\Common\;c:\Program Files\Common Files\Crystal
Decisions\2.5\bin\
Thu 11/30/2006 17:11:24.72 End of task
Wojo wrote:
Pegasus,
Here's my version of the bat file:
@echo off
echo %date% %time% Start of task > c:\test.log
echo User=%UserName%, Path=%path% >> c:\test.log
copy \\chiprddat\murexmxgro\xfer\MurexGFX_UserAccess.txt
"\\crprdndfs01\ds_dfs\GCIB Admin\TSISAuditExtracts\ADV"
copy \\chiprddat\murexmxgro\xfer\MurexGFX_GroupDesc.txt
"\\crprdndfs01\ds_dfs\GCIB Admin\TSISAuditExtracts\ADV"
echo %date% %time% End of task >> c:\test.log
A test.log does not get created when I run it via the scheduler. Here
are the contents of the log file when I run it manually:
Thu 11/30/2006 16:38:44.58 Start of task
User=nbkr9hh,
Path=C:\WINNT\System32;\\neon\binlib\dll\sql11.1.1\bin;\\neon\binlib\dll\sql11.1.1\dll;;C:\WINNT;C:\WINNT\System32;\\radon\binlib\dll\sql12\OCS-12_0\dll;\\radon\binlib\dll\sql12\OCS-12_0\bin;C:\WINNT\System32\Wbem;C:\Program
Files\Microsoft SQL Server\80\Tools\BINN;c:\lim\vbapi;c:\Program
Files\Rational\Common\;c:\Program Files\Common Files\Crystal
Decisions\2.5\bin\
Thu 11/30/2006 16:38:44.70 End of task
Pegasus (MVP) wrote:
Time to get serious. Modify your batch file like so:
@echo off
echo %date% %time% Start of task > c:\test.log
echo User=%UserName%, Path=%path% >> c:\test.log
[put your own lines of code here]
echo %date% %time% End of task >> c:\test.log
Now do this:
1. Run the job manually.
2. Examine c:\test.log.
3. Schedule the job.
4. Examine c:\test.log.
5. Post your version of the batch file here.
6. Post the contents of c:\test.log here.
"Wojo" <wojcik87@xxxxxxxxx> wrote in message
news:1164901816.749910.82580@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Pegasus,
I received the same result as before. When I run it manually it works
fine, however,
when I run it via the scheduler the Command Prompt window opens then
closes before
running the bat file. I did include the server name in the Run field
this time around as follows but still no luck:
"\\chicago\doblib\Tech&Ops\Scheduled Tasks\Report Output\MurexGFX.bat"
Pegasus (MVP) wrote:
"Wojo" <wojcik87@xxxxxxxxx> wrote in message
news:1164731157.300759.321950@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
I'm having a problem with MS Scheduled Task. I'm trying to run a
simple batch file via the scheduler but the DOS (Command Line) window
opens then quickly closes without running the bat file. When I run the
batch file manually it runs successfully. The batch file is a simple
copy command and it is set up as follows:
copy \\chicago\murexmxgro\xfer\MurexGFX_UserAccess.txt
"\\newyork\ds_dfs\GCIB Admin\TSISAuditExtracts\MurexGFX"
I have the following set up in the Run field found in the Scheduled
Task:
"P:\Tech&Ops\Scheduled Tasks\Report Output\MurexGFX.bat"
Not sure what I'm missing?
An often used alternative to inserting "pause" statements is to run
the the batch file from a Command Prompt:
- Click Start / Run / cmd
- Type "P:\Tech&Ops\Scheduled Tasks\Report Output\MurexGFX.bat"
Note that mapped drives are often either visible under scheduled tasks
or are inaccessible because of permission issues.
.
- Follow-Ups:
- Re: MS Scheduled Task
- From: Pegasus \(MVP\)
- Re: MS Scheduled Task
- References:
- MS Scheduled Task
- From: Wojo
- Re: MS Scheduled Task
- From: Pegasus \(MVP\)
- Re: MS Scheduled Task
- From: Wojo
- Re: MS Scheduled Task
- From: Pegasus \(MVP\)
- Re: MS Scheduled Task
- From: Wojo
- MS Scheduled Task
- Prev by Date: Re: DVD's
- Next by Date: Re: very slow working
- Previous by thread: Re: MS Scheduled Task
- Next by thread: Re: MS Scheduled Task
- Index(es):
Relevant Pages
|