We are facing issue in “Scheduled Runbook”, please have a look on below detail…
- I have created a Runbook to restart services on target machine and scheduled it at 3:30AM and it was working fine.
- 2 days back I received request to change the scheduled time from 3:30AM to 4:00AM.
- Now this runbook being executed twice, one at 3:30AM and 2nd one is 4:00AM.
- Though we are able to see execution history on Octopus for 4:00AM only but services are being restarted at 3:00AM and 4:00AM.
Octopus might have created 2 different schedule for both the times.
Please help me with detail how Runbook works and what could be the issue here.
Thanks in advance.
Thanks for getting in touch!
If the trigger was running twice then it would appear in Octopus as two separate runs. Are you sure that the service is actually being restarted at 4am? When configuring the trigger you can set the timezone and I’m wondering if perhaps the wrong one has been selected causing it to run at 3am rather than 4am?
Thanks for prompt response.
Thats the wonder indeed, there is no any trace on Octopus for 2nd run. As per Octopus, its been executed at 4AM only.
But on target server, I can see services restarted twice at old scheduled time (3:30AM) and new time (4:00AM).
I think, there is no any role of Timezone, because if its timezone then also it should execute only once might be on different time.
I hope it will help you. Please let me know if more input required. Thanks
That is unusual indeed, I don’t see how Octopus could be running this without anything being logged. Is the runbook a simple script to restart a service? It doesn’t create a scheduled task within Windows Task Scheduler or anything similar?
I can see there are 5 triggers for that runbook, would you be able to send a quick screenshot of them?
Also, would it be possible to disable this trigger for a day as a test to see if the service still gets restarted at 3:30?
These are the 5 triggers which you’ve seen in the previous screenshot. These 5 triggers is for separate set of environments. Please have a look on screenshot below.
Yes, these runbook contains script to restart services.
I’ll check it with this task owner whether we can disable or not.
The other option would be to amend the runbook script so that it writes a timestamp to a logfile somewhere on the machine when it runs. This would require a bit more work though.
It’s mainly just a test to confirm that it is definitely this runbook and trigger that is causing the restart of the service at the wrong time.
I will implement timestamp to logfile thats ok.
Is there any other option as of now to dig into and verify this issue.
Again Thanks for your prompt response.
The only other thing I can think to check is the Tasks section in Octopus and filtering on Task Type: Runbook run to see if there are any around 3.30. This is on the off chance that the task isn’t appearing in the runbook section.
This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.