[Bug 36229] New: koha-run-backups should be first daily job
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 Bug ID: 36229 Summary: koha-run-backups should be first daily job Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: minor Priority: P5 - low Component: Architecture, internals, and plumbing Assignee: koha-bugs@lists.koha-community.org Reporter: dcook@prosentient.com.au QA Contact: testopia@bugs.koha-community.org There's a couple of reasons why koha-run-backups should be the first job in /etc/cron.daily/koha-common. 1. It takes a backup before running scripts that change database contents. If there is a problem with those scripts, you'll have a very recent backup on which to fallback. 2. It's a resource intensive job. If you have a lot of Koha instances, this means you're running your most intensive job at the end of the job run, which might be a lot later in the day than you anticipate. (Of course, you can update /etc/crontab to change when /etc/cron.daily is run, but this will help reduce impact in the meantime.) -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |CONFIRMED -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 Imani <imani.thomas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|CONFIRMED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 --- Comment #1 from Imani <imani.thomas@bywatersolutions.com> --- Created attachment 176230 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=176230&action=edit Bug 36229: Move koha-run-backups to the top of the cron test plan: 1. check run order of scripts in the cron 2. apply patch 3. koha-run-backups is now at the beginning of the cron -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #176230|0 |1 is obsolete| | --- Comment #2 from David Nind <david@davidnind.com> --- Created attachment 176284 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=176284&action=edit Bug 36229: Move koha-run-backups to the top of the cron test plan: 1. check run order of scripts in the cron 2. apply patch 3. koha-run-backups is now at the beginning of the cron Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |dcook@prosentient.com.au |ity.org | QA Contact|testopia@bugs.koha-communit |m.de.rooy@rijksmuseum.nl |y.org | CC| |m.de.rooy@rijksmuseum.nl -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA Patch complexity|--- |Trivial patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #176284|0 |1 is obsolete| | --- Comment #3 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Created attachment 176315 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=176315&action=edit Bug 36229: Move koha-run-backups to the top of the cron test plan: 1. check run order of scripts in the cron 2. apply patch 3. koha-run-backups is now at the beginning of the cron Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |25.05.00 released in| | Status|Passed QA |Pushed to main -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 --- Comment #4 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Pushed for 25.05! Well done everyone, thank you! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the| |This fixes the order of the release notes| |daily cron jobs | |(/etc/cron.daily/koha-commo | |n) so that koha-run-backups | |is run first. | | | |Reasons for | |this include: | | | |1. The | |koha-run-backups cron job | |takes a backup before | |running scripts that change | |database contents. If there | |is a problem with those | |scripts, you'll have a very | |recent backup on which to | |fallback. | | | |2. It's a | |resource intensive job. If | |you have a lot of Koha | |instances, this means | |you're running your most | |intensive job at the end of | |the job run, which might be | |a lot later in the day than | |you anticipate. (Of course, | |you can update /etc/crontab | |to change when | |/etc/cron.daily is run, but | |this will help reduce | |impact in the meantime.) CC| |david@davidnind.com --- Comment #5 from David Nind <david@davidnind.com> --- I've added a release note, but a quick question: Will this change only fix this for new installations? If it does, I'll add a note that this change will need to be made manually for existing installations. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 --- Comment #6 from David Cook <dcook@prosentient.com.au> --- (In reply to David Nind from comment #5)
I've added a release note, but a quick question: Will this change only fix this for new installations?
If it does, I'll add a note that this change will need to be made manually for existing installations.
It's complicated. It will seamlessly apply for new installations, it will seamlessly apply for existing installations where the crontab hasn't been previously manually modified. For existing installations where the crontab has been previously manually modified, sysadmins will be prompted to decide whether or not to apply the change. (Deployment tools like Ansible are often set to automatically accept changes, so automated deployments often will apply the change, but it will vary by individual implementation.) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the|This fixes the order of the |This fixes the order of the release notes|daily cron jobs |daily cron jobs |(/etc/cron.daily/koha-commo |(/etc/cron.daily/koha-commo |n) so that koha-run-backups |n) so that koha-run-backups |is run first. |is run first. | | |Reasons for |Reasons for |this include: |this include: | | |1. The |1. The |koha-run-backups cron job |koha-run-backups cron job |takes a backup before |takes a backup before |running scripts that change |running scripts that change |database contents. If there |database contents. If there |is a problem with those |is a problem with those |scripts, you'll have a very |scripts, you'll have a very |recent backup on which to |recent backup on which to |fallback. |fallback. | | |2. It's a |2. It's a |resource intensive job. If |resource intensive job. If |you have a lot of Koha |you have a lot of Koha |instances, this means |instances, this means |you're running your most |you're running your most |intensive job at the end of |intensive job at the end of |the job run, which might be |the job run, which might be |a lot later in the day than |a lot later in the day than |you anticipate. (Of course, |you anticipate. (Of course, |you can update /etc/crontab |you can update /etc/crontab |to change when |to change when |/etc/cron.daily is run, but |/etc/cron.daily is run, but |this will help reduce |this will help reduce |impact in the meantime.) |impact in the meantime.) | | | |Deployment of this change: | |- New installations: This | |change will seamlessly | |apply for new | |installations. | |- Existing | |installations: | | . You | |HAVEN'T manually modified | |the crontab: it will | |seamlessly apply. | | . You | |HAVE manually modified the | |crontab: you will be | |prompted, and will need to | |decide about applying the | |change. | | . Where | |deployment tools are used | |(such as Ansible): this | |will depend on what tools | |you use and how they are | |configured. --- Comment #7 from David Nind <david@davidnind.com> --- (In reply to David Cook from comment #6)
(In reply to David Nind from comment #5)
I've added a release note, but a quick question: Will this change only fix this for new installations?
If it does, I'll add a note that this change will need to be made manually for existing installations.
It's complicated.
It will seamlessly apply for new installations, it will seamlessly apply for existing installations where the crontab hasn't been previously manually modified.
For existing installations where the crontab has been previously manually modified, sysadmins will be prompted to decide whether or not to apply the change. (Deployment tools like Ansible are often set to automatically accept changes, so automated deployments often will apply the change, but it will vary by individual implementation.)
Thanks for the great explanation David! I've updated the release note to hopefully reflect this. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 Paul Derscheid <paul.derscheid@lmscloud.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to main |Pushed to stable Version(s)|25.05.00 |25.05.00,24.11.04 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 --- Comment #8 from Paul Derscheid <paul.derscheid@lmscloud.de> --- Nice work everyone! Pushed to 24.11.x for 24.11.04 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36229 Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to stable |Needs documenting CC| |wainuiwitikapark@catalyst.n | |et.nz --- Comment #9 from Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz> --- Not backporting to 22.11.x as it wasn't backported to 24.05.x -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org