[Bug 10782] New: Add a koha-mysqlcheck script
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 Bug ID: 10782 Summary: Add a koha-mysqlcheck script Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Command-line Utilities Assignee: magnus@enger.priv.no Reporter: magnus@enger.priv.no QA Contact: testopia@bugs.koha-community.org I'm creating this for myself anyway, so I thought I'd see if there is any interest in getting it into Koha... The idea is to add a script similar to koha-mysql, but instead of running the "mysql" command, it would run the "mysqlcheck" command: http://dev.mysql.com/doc/refman/5.0/en/mysqlcheck.html This will make it very easy to check the database of a given instance for errors. There will be command line options for what kind of checks to perform (quick, fast, changed, medium, extended) and verbosity (silent, verbose). If this sounds like a stupid idea, please feel free to mark this bug as "RESOLVED WONTFIX" or similar -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 Magnus Enger <magnus@enger.priv.no> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff Patch complexity|--- |Small patch -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 --- Comment #1 from Magnus Enger <magnus@enger.priv.no> --- Created attachment 21984 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=21984&action=edit Bug 10782 - Add a koha-mysqlcheck script This patch adds the koha-mysqlcheck script, as a "frontend" for the mysqlcheck command. It can be used to check the integrity of database tables, as well as to repair them. See "man mysqlcheck" for more information. The script takes a Koha instance name as its only required parameter. Any other parameters provided before the instance name are passed directly to mysqlcheck, which means that all the functionality of mysqlcheck is available through this script. To test the script: - Apply the patch, build your own packages and install them, or - copy koha-mysqlcheck to a server already running off packages - Run some variations of the command, with and without arguments, and check that the output makes sense. E.g.: sudo koha-mysqlcheck myinstance sudo koha-mysqlcheck -e myinstance # Extended checks sudo koha-mysqlcheck -e -v myinstance # Extended checks and verbose - See "man mysqlcheck" for other relevant options To test the man page: - Run these commands and look at the formatted man page: $ xsltproc /usr/share/xml/docbook/stylesheet/docbook-xsl/manpages/docbook.xsl \ debian/docs/koha-mysqlcheck.xml $ man -l koha-mysqlcheck.8 - Make sure this test passes: $ prove -v xt/verify-debian-docbook.t -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 --- Comment #2 from Magnus Enger <magnus@enger.priv.no> --- Just to be clear: My plan changed a little between the initial comment and the actual commit. Please disregard the description given in the first comment, and focus on the description in the actual commit. :-) -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 I'm just a bot <gitbot@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |gitbot@bugs.koha-community. | |org When did the bot| |2013-10-30 last check this| | --- Comment #3 from I'm just a bot <gitbot@bugs.koha-community.org> --- Patch applied cleanly, go forth and signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #21984|0 |1 is obsolete| | --- Comment #4 from Chris Cormack <chris@bigballofwax.co.nz> --- Created attachment 25357 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=25357&action=edit Bug 10782 - Add a koha-mysqlcheck script This patch adds the koha-mysqlcheck script, as a "frontend" for the mysqlcheck command. It can be used to check the integrity of database tables, as well as to repair them. See "man mysqlcheck" for more information. The script takes a Koha instance name as its only required parameter. Any other parameters provided before the instance name are passed directly to mysqlcheck, which means that all the functionality of mysqlcheck is available through this script. To test the script: - Apply the patch, build your own packages and install them, or - copy koha-mysqlcheck to a server already running off packages - Run some variations of the command, with and without arguments, and check that the output makes sense. E.g.: sudo koha-mysqlcheck myinstance sudo koha-mysqlcheck -e myinstance # Extended checks sudo koha-mysqlcheck -e -v myinstance # Extended checks and verbose - See "man mysqlcheck" for other relevant options To test the man page: - Run these commands and look at the formatted man page: $ xsltproc /usr/share/xml/docbook/stylesheet/docbook-xsl/manpages/docbook.xsl \ debian/docs/koha-mysqlcheck.xml $ man -l koha-mysqlcheck.8 - Make sure this test passes: $ prove -v xt/verify-debian-docbook.t Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 Robin Sheat <robin@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |robin@catalyst.net.nz -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 --- Comment #5 from Robin Sheat <robin@catalyst.net.nz> --- This seems perfectly fine and sensible (and documented) to me. I won't mark it as passed-QA given Chris signed off on it, but it's pretty straight forward and doesn't interfere with any other part of the system. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #25357|0 |1 is obsolete| | --- Comment #6 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 27459 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=27459&action=edit [PASSED QA] Bug 10782 - Add a koha-mysqlcheck script This patch adds the koha-mysqlcheck script, as a "frontend" for the mysqlcheck command. It can be used to check the integrity of database tables, as well as to repair them. See "man mysqlcheck" for more information. The script takes a Koha instance name as its only required parameter. Any other parameters provided before the instance name are passed directly to mysqlcheck, which means that all the functionality of mysqlcheck is available through this script. To test the script: - Apply the patch, build your own packages and install them, or - copy koha-mysqlcheck to a server already running off packages - Run some variations of the command, with and without arguments, and check that the output makes sense. E.g.: sudo koha-mysqlcheck myinstance sudo koha-mysqlcheck -e myinstance # Extended checks sudo koha-mysqlcheck -e -v myinstance # Extended checks and verbose - See "man mysqlcheck" for other relevant options To test the man page: - Run these commands and look at the formatted man page: $ xsltproc /usr/share/xml/docbook/stylesheet/docbook-xsl/manpages/docbook.xsl \ debian/docs/koha-mysqlcheck.xml $ man -l koha-mysqlcheck.8 - Make sure this test passes: $ prove -v xt/verify-debian-docbook.t Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |martin.renvoize@ptfs-europe | |.com --- Comment #7 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Nice simple script, does what it says on the tin and causes no regressions. A worthwhile addition. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 Galen Charlton <gmcharlt@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master CC| |gmcharlt@gmail.com --- Comment #8 from Galen Charlton <gmcharlt@gmail.com> --- Pushed to master. Thanks, Magnus! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10782 Fridolin SOMERS <fridolyn.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to Master |Pushed to Stable CC| |fridolyn.somers@biblibre.co | |m --- Comment #9 from Fridolin SOMERS <fridolyn.somers@biblibre.com> --- Pushed to 3.14.x, will be in 3.14.11 -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org