Scheduling an advertisement runs program immediately.

Scheduling an advertisement runs program immediately.

Post by jonathon.o » Sun, 23 Dec 2007 01:21:34


I want to set a defrag to run, and re-run on the same machines.

I created a new package/program and then a new adverti *** t. I
picked the adverti *** t to run on a schedule, even though I didn't
immediately specify the schedule.

Then I placed machines in the appropriate collection, and then went
and scheduled a time for the defrag to take place in its
adverti *** t. I do not want a specific reoccuring schedule (like
every 30 days), so I just set a specific date/time and that is it.

What ends up happening is that the program runs on the computers
immediately (when the machines pickup the adverti *** t), as if i
picked ASAP or selected re-run adverti *** t. And then the program
runs AGAIN on the computers at the time I specified in the
adverti *** t, so it ends up running twice!

I press the yellow star for mandatory assignments to create another
scheduled adverti *** t, then choose 'Assign to the Following
Schedule', and then I pick a date/time and make sure that recurrence
pattern is none. Yet the program runs immediately, and then at the
time I specify.

Then I go through the same steps to add another date/time to add
another scheduled one time occurence of the adverti *** t, and again
it runs twice: immediately and the time I specify. Within the
Adverti *** t Properties, under Mandatory Assignments, ASAP is NOT
listed among the date/times I have selected in the past.

What am I doing wrong?

Thanks,

Jon
 
 
 

Scheduling an advertisement runs program immediately.

Post by U2hlcnJ5IE » Sun, 23 Dec 2007 07:01:01

(resubmit, I don't think my reply went through the last time, if this is a
duplicate message, I apologize)

It sounds like you have multiple entries in the mandatory section? Are any
of them, any at all, set with a date/time in the past? If so, any new client
will pick up that policy, determine it "missed" a run time, and will run as
soon as possible; and then wait for the next scheduled time, and run again.
--
Standarize. Simplify. Automate.

 
 
 

Scheduling an advertisement runs program immediately.

Post by jonathon.o » Sun, 23 Dec 2007 07:40:04

I do have prior entries in the mandatory section. When I create a new
program and corresponding adverti *** t, and then select my first non-
recurring time, the program is run at the scheduled time correctly.
The problem seems to happen on subsequent occurences that I add
manually.

The steps I took were from a older Google group posting, where it told
me to NOT delete the old entries in the Mandatory section. Here I
have paraphrased some of what they said in that post:

"If you want to force all 20 clients to run the adverti *** t again:
**Add a second TIME-BASED assignment to the existing adverti *** t. Do
not
delete the first assignment, the second assignment causes the
adverti *** t
to be treated by clients as a recurring assignment. Note: Event-based
assignments do not support rescheduling. Recurring assignments are
always
run on their schedule regardless of any previous execution status,
this will
force all 20 clients to re-run the adverti *** t on the second
schedule, thus
ADDING ANOTHER time based schedule will cause this adverti *** t to re-
run
on the machine.
1 - Create a package, program and adverti *** t -- make sure that the
adverti *** t has a one shot time based schedule.
2 - Wait for client to run it successfully.
3 - Once client has run the program successfully, add another one-shot
time
based schedule to the same adverti *** t.
4 - Wait for client to get the updated policy and you will see that
client
will run the program again."

When step #4 kept trying to run the program twice (once immediately,
and once at the specified time), I then tried deleting the prior
mandatory entry, so that only my single future entry existed; however,
when the program was about to run, it gave me the error that the
computer has already run the adverti *** t so it won't run again. So
I did try deleting old scheduled entries to no avail, because then it
won't run again on the machines.

FYI: I am running SMS 2003 SP2.

Thanks,

Jon
 
 
 

Scheduling an advertisement runs program immediately.

Post by jonathon.o » Sun, 23 Dec 2007 08:42:41

One question.... I just ran across something. It seems to work if I
leave the machines in the collection. My idea was to remove the
machines after the defrag, because I wrote scripts to obtain what
computer names I wanted and it adds them each time to the collection
when I run a 'maintenance cycle'. (I actually thought I left machines
in the collections, as well as removing and re-adding them, but
apparently not because it seems to work like that now).

If a computer leaves the collection, and then re-enters 15 minutes
later (as in my testing), it will behave as if it were never in the
collection and run prior scheduled mandatory entries? If there are 4
old scheduled mandatory entries, will it run the program 4 times in a
row immediately, plus the one future scheduled entry? Will I be able
to ever delete the old entries without the program saying that it has
already been run on the machine?

Thanks for your help,

Jon
 
 
 

Scheduling an advertisement runs program immediately.

Post by U2hlcnJ5IE » Wed, 26 Dec 2007 05:50:00

I don't believe I can best answer that question. I've personally never set
multiple mandatory times. If I want something to re-run, I either use Roger
Zander's SMS client Center to trigger a re-run manually per-machine; or the
single mandatory entry is for "run every 3 days" or something like that--and
I want every machine in the collection to re-run if it ran before.

This might be a bit late; it sounds like you've already designed it, but
have you checked out http://www.yqcomputer.com/ , Jase Wolfe's
Windows Defrag Scripts & reports? Click on the gear (you might need to
create an account) to download defragAnalysis.zip.
--
Standarize. Simplify. Automate.