BatchPatch Forums Home › Forums › BatchPatch Support Forum › Wait for a different host to come online
- This topic has 4 replies, 2 voices, and was last updated 3 years, 1 month ago by doug.
-
AuthorPosts
-
November 12, 2021 at 11:00 am #13163mkrautlerParticipant
I have read numerous posts about multi row job sequencing with Batchpatch but I haven’t found one where the process verifies that a different host comes back online before the next host begins its rebooting process. How can I have server groups A, B & C run Windows updates simultaneously, then the server group A will reboot and once they all come back online then server group B will reboot? Once all the servers in server group B comes back online then server group C will start their rebooting process. I have multiple groups of computers that need to be rebooted in a specific order before the next group starts rebooting (SQL 1st, App 2nd, Web 3rd, etc…)
Any ste-by-step tutorial would be amazing, but if not then a point in the right direction might be helpful as well. I’m sorry if I missed a post that already covered that, I checked the forums but couldn’t find anything specific.
November 12, 2021 at 11:55 am #13164dougModeratorWe have a handful of tutorials on the website:
https://batchpatch.com/advanced-multi-row-queue-sequence-video-tutorial
https://batchpatch.com/advanced-multi-row-queue-sequence
https://batchpatch.com/virtual-machine-guest-host-update-and-reboot-sequence-automation
https://batchpatch.com/patch-and-update-automation-with-multiple-dependent-systemsThe process works as follows:
1. First you must choose the action(s) that will be executed on each host/row when the sequence runs. The actions are assigned by using the regular job queue
configuration screen for each row that you want to include in the sequence. For this process you’ll select ‘Actions > Job Queue > Create/modify job queue.’ In
the Job Queue window you’ll choose your desired queue, and then finally you’ll click ‘Apply queue to row(s) without executing.’2. For all rows that you want to be part of a sequence, you’ll need to choose a sequence name. You’ll apply a particular sequence name to each host that is
included in a given sequence. With the sequence name you’ll also apply a sequence position number. Multiple hosts can have the same position number, if desired.
So, if you need to have one host execute an action, and then when it completes you need five hosts to all execute actions simultaneously, and then when they all
complete you need three other hosts to all execute actions simultaneously, you can do that by applying the following sequence position numbers:host1 YourSequenceName:PositionNumber1
host2 YourSequenceName:PositionNumber2
host3 YourSequenceName:PositionNumber2
host4 YourSequenceName:PositionNumber2
host5 YourSequenceName:PositionNumber2
host6 YourSequenceName:PositionNumber2
host7 YourSequenceName:PositionNumber3
host8 YourSequenceName:PositionNumber3
host9 YourSequenceName:PositionNumber33. For each sequence name you must create a sequence execution row. This is a special row that is designated for launching a particular sequence.
hostX YourSequenceName:ExecutionRow
4. When you’re ready to execute a sequence, highlight the execution row for the sequence you want to execute, and then choose ‘Actions > Job Queue > Execute
advanced multi-row job queue sequence.’ BatchPatch will find all rows that have the same sequence name as the execution row, and then BatchPatch will launch
the job queue for all rows set to position number 1. When all position 1 rows have completed their queues, all position 2 job queues will be executed. When
all position 2 rows have completed their queues, all position 3 job queues will be executed. And so on.————————————-
In your case you asked to make sure that the groups finish rebooting and come back online before the next group begins, so you could configure your job queue something like this:
Download and install updates + reboot always Wait 10 minutes Wait for host to be detected online
In the screenshot above the SQL group will perform its update/reboot/wait actions, followed by the APP group, followed by the WEB group.
————————————-
However, you actually asked specifically about having *only* the reboot portion be staggered, in which case you’d have to actually add all computers to the grid twice, then you’d have to apply two separate job queues, and then you’d have to combine them all into a single sequence, as shown in the screenshot below. However, I would recommend doing what I’ve described above, not what you described (below). That’s because if your goal is to prevent services from being affected and only having certain machines offline at the same time, then you probably should not install updates at the same time on all groups either because there are times where during the update installation process services could be taken offline by Windows. To be safe you should instead install updates on a single group and reboot that single group, then install updates on the next group and reboot the next group, then install updates on the last group and reboot the last group.
Anyway though… if you still want to perform the update on all machines simultaneously followed by staggered reboots, you can do it. For this you’d have two separate job queues. The queue for updating, which occurs in sequence position 1 is simply:
Download and install updates
The queue for rebooting and waiting, which occurs in sequence position 2, 3, and 4 is:
Reboot (force, if required) Wait 10 minutes Wait for host to be detected online
November 12, 2021 at 12:55 pm #13165mkrautlerParticipantThank you @Doug , I was the wait for host online but I guess it didn’t register to me until you explained it. I will test out the scenario to see how best it works for us. Thanks again, you were a great help!!
November 16, 2021 at 3:52 pm #13170mkrautlerParticipantOne last thing, if I have multiple sequences setup, do I have to create an execution row for each sequence and if so, are there ways to have them automatically execute once the previous execution row has completed? If I need to create a new post, please let me know. Thank you in advance.
November 16, 2021 at 4:11 pm #13171dougModeratorEach sequence must have its own execution row. There is not currently a way to trigger one sequence to start when another has completed, but you can certainly just set it up as a single larger sequence that encompasses both of the smaller ones. If you want the completion of one sequence to trigger the start of another sequence, then it seems to me that’s what you really want anyway… I mean you really just want one larger sequence that encompasses the two individual smaller sequences. Why would you split it into two smaller sequences if the goal would be to have completion of one sequence would trigger the start of the other sequence? How is this different or better than just having a single larger sequence?
-
AuthorPosts
- You must be logged in to reply to this topic.