Bug 724894
Summary: | Can't create bacula MySQL tables | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Edouard Bourguignon <madko> | ||||||
Component: | bacula | Assignee: | Andreas Thienemann <andreas> | ||||||
Status: | CLOSED CURRENTRELEASE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||||
Severity: | high | Docs Contact: | |||||||
Priority: | unspecified | ||||||||
Version: | 15 | CC: | andreas, dnovotny, fedora, fschwarz, gwync, hhorak, lnykryn, mmcgrath, negativo17, vanmeeuwen+fedora | ||||||
Target Milestone: | --- | ||||||||
Target Release: | --- | ||||||||
Hardware: | All | ||||||||
OS: | Linux | ||||||||
Whiteboard: | |||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||
Doc Text: | Story Points: | --- | |||||||
Clone Of: | Environment: | ||||||||
Last Closed: | 2012-07-18 09:19:14 UTC | Type: | --- | ||||||
Regression: | --- | Mount Type: | --- | ||||||
Documentation: | --- | CRM: | |||||||
Verified Versions: | Category: | --- | |||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||
Embargoed: | |||||||||
Attachments: |
|
Description
Edouard Bourguignon
2011-07-22 08:17:48 UTC
MaxValue is a reserved word in mysql 5.5 cf http://dev.mysql.com/doc/refman/5.5/en/reserved-words.html Have reported this bug upstream: http://bugs.bacula.org/view.php?id=1753 Here is the patch found on the bacula mantis: --- make_mysql_tables.orig 2010-02-15 16:05:14.000000000 +0200 +++ make_mysql_tables 2010-02-15 16:09:50.000000000 +0200 @@ -322,12 +322,12 @@ -CREATE TABLE Counters ( - Counter TINYBLOB NOT NULL, - MinValue INTEGER DEFAULT 0, - MaxValue INTEGER DEFAULT 0, - CurrentValue INTEGER DEFAULT 0, - WrapCounter TINYBLOB NOT NULL, +CREATE TABLE \`Counters\` ( + \`Counter\` TINYBLOB NOT NULL, + \`MinValue\` INTEGER DEFAULT 0, + \`MaxValue\` INTEGER DEFAULT 0, + \`CurrentValue\` INTEGER DEFAULT 0, + \`WrapCounter\` TINYBLOB NOT NULL, PRIMARY KEY (Counter(128)) ); I try and it works now. Can someone integrate it in a new release of bacula packages? Created attachment 518652 [details]
proposed patch which adds quotes to MaxValue column
This patch adds quotes to all sql queries where MaxValue is used. I've tested it only in some use cases, so another tests are welcome.
Created attachment 529756 [details]
Patch for MaxValue issue from upstream git
In bacula git they have solved it only for files in src/cats/. But they have used different type of quotation in .c files.
Fix commited to git -> http://lists.fedoraproject.org/pipermail/scm-commits/2011-November/679426.html ->modified bacula-5.0.3-10.fc15 has been submitted as an update for Fedora 15. https://admin.fedoraproject.org/updates/bacula-5.0.3-10.fc15 Package bacula-5.0.3-10.fc15: * should fix your issue, * was pushed to the Fedora 15 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing bacula-5.0.3-10.fc15' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2011-15370 then log in and leave karma (feedback). bacula-5.0.3-16.fc15 has been submitted as an update for Fedora 15. https://admin.fedoraproject.org/updates/bacula-5.0.3-16.fc15 |