Scheduled Tasks Doesn't Wait for Backup to Finish

  • Thread starter Frederick R. Hutchings
  • Start date
F

Frederick R. Hutchings

i have win xp sp3.

i'm backing up all the computers in my workgroup. when i run the backups,
they all try to run at once, but only one of them runs. the others get
errors because my backup program will only allow one instance of it running
at a time.

right now i have the individual backups running at specified times. it's
not very convenient. i don't know exactly how long they will take. it
wastes time.

i've looked at scheduled tasks, "at" commands, schtasks, and task scheduler.
i have not been able to find a way to start the next backup immediately
after the current one. is there a way?

please help.

thanks, fred
 
P

Pegasus [MVP]

Frederick R. Hutchings said:
i have win xp sp3.

i'm backing up all the computers in my workgroup. when i run the backups,
they all try to run at once, but only one of them runs. the others get
errors because my backup program will only allow one instance of it
running at a time.

right now i have the individual backups running at specified times. it's
not very convenient. i don't know exactly how long they will take. it
wastes time.

i've looked at scheduled tasks, "at" commands, schtasks, and task
scheduler. i have not been able to find a way to start the next backup
immediately after the current one. is there a way?

please help.

thanks, fred

Simple: Create a batch file, then copy the various ntbackup command lines
from the scheduled tasks into your batch file like so:
@echo off
ntbackup /.. /.. /..
ntbackup /.. /.. /..

Now create a single backup task that invokes your batch file. Get rid of the
rest.
 
F

Frederick R. Hutchings

the program i'm using is backup mypc 6. it doesn't use a command-line, but
it creates a job in Scheduled Tasks when it is scheduled. i can use
schtasks to run the job from a batch file, but schtasks comes back
immediately saying that it was successful and the batch file continues on
it's merry way while the backup job is still running. a nice feature when
you want it, but this time i want it to wait till the backup job finishes.
what's the best way of doing this?

another post just suggested ntbackup. what do you think of it?

thanks, fred
 
F

Frederick R. Hutchings

hmmm. ntbackup. it's right here in xp pro, and i haven't tried it lately.
so it has a command-line, huh? sounds like it's what i'm looking for.

are there options to run an existing job, or does it just run the backup
without Scheduled Tasks at all? i've never used ntbackup's command-line.

thanks, fred
 
P

Pegasus [MVP]

Frederick R. Hutchings said:
the program i'm using is backup mypc 6. it doesn't use a command-line,
but it creates a job in Scheduled Tasks when it is scheduled. i can use
schtasks to run the job from a batch file, but schtasks comes back
immediately saying that it was successful and the batch file continues on
it's merry way while the backup job is still running. a nice feature when
you want it, but this time i want it to wait till the backup job finishes.
what's the best way of doing this?

another post just suggested ntbackup. what do you think of it?

thanks, fred

You write "It doesn't use a command line". If it doesn't, what then is the
command you will see in each scheduled task? I bet it looks like a command
line that can be copied & pasted into a batch file! Whether the batch file
will execute just one line at a time is another question - we'll cross this
bridge after you've sorted out the command line riddle!

About using ntbackup: This is a legacy backup tool that is difficult to use.
If you're happy with "Backup MyPC" then continue using it.
 
F

Frederick R. Hutchings

all it puts in the job Run: field is: "C:\Program Files\StompSoft\Backup
MyPC 6\System\sbestart.exe". the name of the job in scheduled tasks is the
same as in backup mypc. maybe it uses the name of the job to get the rest
of the information? maybe the .job file has more in it than i realized.

fred
 
L

Lem

Frederick said:
all it puts in the job Run: field is: "C:\Program Files\StompSoft\Backup
MyPC 6\System\sbestart.exe". the name of the job in scheduled tasks is the
same as in backup mypc. maybe it uses the name of the job to get the rest
of the information? maybe the .job file has more in it than i realized.

fred

There "ought" to be a way to point the executable to a specified "job"
or "script" file. Try asking here (it seems to be the forum for Backup
My PC 6, among other Sonic apps taken over by Roxio):
http://forums.support.roxio.com/index.php?showforum=105

--
Lem -- MS-MVP

To the moon and back with 2K words of RAM and 36K words of ROM.
http://en.wikipedia.org/wiki/Apollo_Guidance_Computer
http://history.nasa.gov/afj/compessay.htm
 
F

Frederick R. Hutchings

i checked it out a bit and i did find references to backup mypc. i'll try
to post this there. it's not exactly intuitive to me.

thanks, fred
 
P

Pegasus [MVP]

Let's have a closer look at your scheduled task: Attach the relevant .job
file to your newsgroup reply. You will find it in c:\Windows\tasks.
 
F

Frederick R. Hutchings

Here is a job that backup mypc created (DVD Differential). I also included
the batch file that I use to run the job which uses schtasks. Of course the
backup job can be run all by itself, but I want the next job to start
immediately after this one finishes. There's also the main batch file
(Backup Daily) that Scheduled Tasks runs. It runs several batch files, but
it doesn't work. The three backup jobs won't run at the same time or run
one after the other.

Backup Daily tries to run several backups, but as I said earlier, Backup
MyPC appears to not allow more than one instance running at the same time,
so one runs and the rest end in errors.

Don't hesitate to ask for any info that I can provide.

I looked at NTBackup. It would probably work. It seems like I've seen it
work both ways. Run two at once or sometimes it waits till the first one
finishes. I see what you mean about it, though. It seems finicky. It only
supports hardware compression. Can you put the backup file in a compressed
folder? It doesn't seem to support DVDs. They suggested sending the backup
file to a hard disk and then writing it to a DVD. That could work for me,
if I can figure out how to write to a DVD-RW in a batch file, except full
backups won't fit on one DVD. I don't know how to get around that one.
Well, now that I think of it, I guess I could split the full backup
appropriately so that the separate ones fit on one DVD. A lot more work
than it could be.

Is NTBackup included in Vista?
Will it be in Windows 7?
I am happy with Backup MyPC. I have had very few problems with it till now.
Maybe we can get it going.

Thanks for your help.
Fred
 
P

Pegasus [MVP]

The "Backup Daily.bat" does not tell me a great deal - it is only a master
module that invokes a bunch of individual submodules.

See what happens when you invoke one of the following batch files. Here is
what I would like to know:
- Does the batch file perform a backup?
- What is the contents of the log file c:\log.txt?
Use cut & paste when creating the batch files. Make sure to run them from a
Command Prompt, not from the Start/Run box.

@echo off
echo %date% %time% > c:\log.txt
cd /d "C:\Program Files\StompSoft\Backup MyPC 6\System"
sbestart.exe/SAGERUN:151C:
echo %date% %time% > c:\log.txt

@echo off
echo %date% %time% > c:\log.txt
cd /d "C:\Program Files\StompSoft\Backup MyPC 6\System"
sbestart.exe/SAGERUN:151C
echo %date% %time% > c:\log.txt
 
P

Pegasus [MVP]

The two batch files were different. The first one had this line:
sbestart.exe/SAGERUN:151C: (trailing colon)
and the second one this line:
sbestart.exe/SAGERUN:151C (no trailing colon)

When examining your job file closely I found that it includes a hidden
parameter that is probably used to identify the type of backup to be run. In
my previous post I had it slightly wrong, so here is the whole thing again:
- Run the batch file you see below.
- Does it perform a backup?
- What is the contents of the log file c:\log.txt?
Use cut & paste when creating the batch files. Make sure to run them from a
Command Prompt, not from the Start/Run box.

@echo off
echo %date% %time% > c:\log.txt
cd /d "C:\Program Files\StompSoft\Backup MyPC 6\System"
sbestart.exe/SAGERUN:15
echo %date% %time% >> c:\log.txt

The error you report does not shed a good light on your backup utility. It
means that it has internal problems that are not properly dealt with.
 
P

Pegasus [MVP]

*** See below.

Frederick R. Hutchings said:
This one runs the batch file you provided with no errors! It seems to be
running the DVD Differential job, but it is not shown running in Scheduled
Tasks. Task Manager shows 2 processes running, SBEStart and SBEWin32. I
don't remember if this normal. I do remember that the original job runs
SBEStart. It backs up and verifies as per the original job.
*** What about the contents of the log file c:\log.txt?
Sorry I missed noticing the trailing colon.
*** No problem.
I'm sorry to hear I may have problems. As you know better than I, losing
data that is important to you is not acceptable. Backup MyPC has never
given me any problems before.
*** You don't really have a problem. All I meant to say is that Backup MyPC
*** has a quality control problem when it comes to handling parameters.
*** This won't affect its overall operation.
I can't remember any files not verifying. I
get a bad DVD once in a while, but Backup MyPC tells me. All the files
that
I have ever restored have worked. I have reformatted and reinstalled my
data several times. I have XP SP3 Pro, but I did see once, a few years
back, that Microsoft said that it wouldn't run in Vista. After checking
more recently, it said to un- and re-install it and try it again,
apparently
implying it might work. I do not want a backup product that is in any way
marginal, however. If a new program is in order, I want one that is
certified for Win 7/Vista.
*** Go on using Backup MyPC!
I only have one license for Backup MyPC, so I only run it on 1 machine. I
have to back up the other machine from it. After fooling with NTBackup
(it
is either really flaky or I'm having trouble with VSS. A restart
sometimes
corrects it), it hangs while doing the shadow copy a lot. When it does
work, it backs up every file, while Backup MyPC can't get access to a lot
of
files. I've started backing up computers in the workgroup to others using
the file option.

Please advise me on my options. Is it best for me to get another backup
solution or is the success today a good sign? I'm including a shot of it
running and Backup MyPC's log.
*** To get an answer your original question, you must post the log
*** file c:\log.txt.
 
F

Frederick R. Hutchings

Thanks again for all your help. I attached c:\log.txt, backup is
running!.jpg, and DVD Differential.txt in my last post. I'll be more than
happy to resend them. Let me know. log.txt doesn't have much in it. DVD
Differential.txt is Backup MyPC's log.

So there may be a way for Backup MyPC (or Scheduled Tasks?) to wait until
the current Backup MyPC program is finished? That would be great!

Thanks again,
Fred
 
P

Pegasus [MVP]

Frederick R. Hutchings said:
Thanks again for all your help. I attached c:\log.txt, backup is
running!.jpg, and DVD Differential.txt in my last post. I'll be more than
happy to resend them. Let me know. log.txt doesn't have much in it. DVD
Differential.txt is Backup MyPC's log.

So there may be a way for Backup MyPC (or Scheduled Tasks?) to wait until
the current Backup MyPC program is finished? That would be great!

Thanks again,
Fred
 
P

Pegasus [MVP]

Sorry, I found no attached file. Since c:\log.txt is a text file, you should
open it with notepad.exe, then copy & paste its contents into your respons.
 
P

Pegasus [MVP]

OK, the log file tells me that your batch file will run one backup command
at the time. I understand that this is exactly what you wanted. Here is what
you need to do next:

1. Create a batch file of the form
@echo off
cd /d "C:\Program Files\StompSoft\Backup MyPC 6\System"
sbestart.exe/SAGERUN:xx
sbestart.exe/SAGERUN:yy
sbestart.exe/SAGERUN:zz

2. Determine the job identifiers xx, yy and zz. Here are three methods to do
this:
a) I suspect that there is a file, perhaps a .ini file in the "Backup MyPC"
folder that contains the details for this identifier. The job you just had
used an identifier /SAGERUN:15. Can you see something that relates to it? If
you can't, create a new schedueld backup job, then find out which file(s) in
the "Backup MyPC" folder have a current date/time stamp.
b) Use debug.exe or some other binary viewer to examine the scheduled task
file, e.g. c:\windows\tasks\Backup.job. You will find the word "/SAGERUN",
interspersed with $00, followed by the identifier, followed by $00 $00.
c) Post again if this is beyond your level of experience and I'll write you
some script that extracts the identifier.

Enjoy!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Scheduled Backups 12
Can't Find Backup File 11
Scheduled tasks don't end 18
Scheduled tasks in sequence (nested) 7
scheduled tasks not starting 2
Scheduled tasks 5
Running Scheduled Tasks 7
Scheduled Tasks problem 5

Top