Jump to content
derek500

confused about scheduling

Recommended Posts

Hi,

I'm having trouble setting up scheduled events the way I want. Instead of running events in the order I scheduled them it seems to have some arbitrary priority that doesn't pay any attention to what order past due events were scheduled in. (I believe it's actually based on 'oldest previous script occurance' instead of 'scheduled first' which really becomes seemingly random after a few waiting events start to stack up)

 

For example - Nightly I run 3 scheduled backup scripts, each one taking more time than I've separated the schedules by. The first one always starts first, but the 2nd and 3rd ones seemingly randomly choose which will start next. Not a big deal because it's nightly. However, I have a few weekly scripts like groom and transfer, and these really need to happen in the right order. Unfortunately they are usually stacked up behind some of my nightly schedules, and when these things run out of order it can really goof things up.

 

for example, I have a nightly scripts that full backup from client to a new tape set, then a disk groom and transfer from disk to tape. The disk to tape transfer will duplicate some of the data that happens with the nightly, so as long as the nightly backups complete before the transfer, the transfer isn't so large. Unfortunately, the schedules sit waiting for each other, and then the groom and transfer scripts run before some of the nightly tape scripts, because of the whacked out order of events.

 

Is there any way to make events happen in the order which I scheduled them, instead of the 'last occurance' priority? I want MY schedule to dictate the priorities.

 

Thanks

-Derek

  • Like 1

Share this post


Link to post
Share on other sites

This has been a problem for many years. Historically, scripts has been executed in alphabetical order (by script name) when scheduled simultaneously.

 

Scripts has to be scheduled with care to avoid running in the wrong order.

Each sequence of scripts should be assigned a specific "activity thread", say number 8. Another sequence of scripts to number 7 and so on.

Schedule the first script to the desired time. Say it runs for 2-4 hours.

Schedule the second script 2 hours later than the first.

Schedule the third script at least 4 hours after the first, so the first has finished and the second surely has started before the third (this) script is added to the queue.

  • Like 1

Share this post


Link to post
Share on other sites

Thanks Lennart,

 

I get it about scheduling things 2-4-6 hours apart. But sometimes I have a script that will run for 5 hours, and other times (to a new media set for example) for 2 days. It's when something runs for days that things get stacked up and then complete out of order that I'm having a problem with. And when I'm doing a new media set, it's important to me to have the backup scripts finish first, grooming next, and transfer last. But that's also the time when things have gotten stacked up, out of order.

 

I'll try renaming them to an alphanumeric naming scheme to see if that helps. Thanks for the suggestion.

 

-Derek

Share this post


Link to post
Share on other sites

Just a quick update - alphabetizing my script names definitely made a positive improvement. I'm not confident about all of it yet but many scripts started happening in the order I'm expecting.

 

Thanks a lot for the suggestion Lennart!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×