rt-setup-database-3.8 does not seem to work

Bug #444046 reported by Raubvogel
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
request-tracker3.8 (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Binary package hint: request-tracker3.8

OS is the beta version of 9.10. Here is the behaviour I would expect (i.e. it works in 3.6):

root@tickets:~# sudo /usr/sbin/rt-setup-database-3.6 --action init --dba rtuser --dba-password mssw
Now creating a database for RT.
Creating mysql database rt3.
Now populating database schema.
Creating database schema.
Done setting up database schema.
Now inserting database ACLs
Done setting up database ACLs.
Now inserting RT core system objects
Checking for existing system user...not found. This appears to be a new installation.
Creating system user...done.
Now inserting RT data
Creating Superuser ACL...done.
Creating groups...3.4.5.6.7.8.9.done.
Creating users...10.12.done.
Creating queues...1.2.done.
Creating ACL...2.3.done.
Creating ScripActions...1.2.3.4.5.6.7.8.9.10.11.12.13.14.15.16.17.done.
Creating ScripConditions...1.2.3.4.5.6.7.8.9.10.done.
Creating templates...1.2.3.4.5.6.7.8.9.10.11.12.done.
Creating scrips...1.2.3.4.5.6.7.8.9.10.11.12.13.14.done.
Creating predefined searches...1.2.3.done.
Done setting up database content.
root@tickets:~#

And here is how rt-setup-database-3.8 is behaving (and yes, the database was deleted between runs):

root@tickets:~# sudo /usr/sbin/rt-setup-database-3.8 --action init --dba rtuser --dba-password mssw
Working with:
Type: mysql
Host: localhost
Name:
User: rtuser
DBA: rtuser
Now creating a mysql database for RT.
Couldn't finish 'create' step.

ERROR: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

root@tickets:~#

The database used in both tests was

root@tickets:~# mysql --version
mysql Ver 14.14 Distrib 5.1.37, for debian-linux-gnu (x86_64) using EditLine wrapper
root@tickets:~#

And, both versions of request-tracker were as ubuntu packages.

Revision history for this message
zikus (rsiripan) wrote :

i'm too get actually the same error, do you find a solution?

Revision history for this message
Raubvogel (raubvogel) wrote : Re: [Bug 444046] Re: rt-setup-database-3.8 does not seem to work

On Fri, Nov 6, 2009 at 12:52 PM, zikus <email address hidden> wrote:
> i'm too get actually the same error, do you find a solution?
>
      The only two solutions I have found so far are

o Stick with 3.6.
o Download RT from the website (i.e. from source) and manually install it.

> --
> rt-setup-database-3.8 does not seem to work
> https://bugs.launchpad.net/bugs/444046
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in “request-tracker3.8” package in Ubuntu: New
>
> Bug description:
> Binary package hint: request-tracker3.8
>
> OS is the beta version of 9.10. Here is the behaviour I would expect (i.e. it works in 3.6):
>
> root@tickets:~# sudo /usr/sbin/rt-setup-database-3.6 --action init --dba rtuser --dba-password mssw
> Now creating a database for RT.
> Creating mysql database rt3.
> Now populating database schema.
> Creating database schema.
> Done setting up database schema.
> Now inserting database ACLs
> Done setting up database ACLs.
> Now inserting RT core system objects
> Checking for existing system user...not found.  This appears to be a new installation.
> Creating system user...done.
> Now inserting RT data
> Creating Superuser  ACL...done.
> Creating groups...3.4.5.6.7.8.9.done.
> Creating users...10.12.done.
> Creating queues...1.2.done.
> Creating ACL...2.3.done.
> Creating ScripActions...1.2.3.4.5.6.7.8.9.10.11.12.13.14.15.16.17.done.
> Creating ScripConditions...1.2.3.4.5.6.7.8.9.10.done.
> Creating templates...1.2.3.4.5.6.7.8.9.10.11.12.done.
> Creating scrips...1.2.3.4.5.6.7.8.9.10.11.12.13.14.done.
> Creating predefined searches...1.2.3.done.
> Done setting up database content.
> root@tickets:~#
>
> And here is how rt-setup-database-3.8 is behaving (and yes, the database was deleted between runs):
>
> root@tickets:~# sudo /usr/sbin/rt-setup-database-3.8 --action init --dba rtuser --dba-password mssw
> Working with:
> Type:   mysql
> Host:   localhost
> Name:
> User:   rtuser
> DBA:    rtuser
> Now creating a mysql database  for RT.
> Couldn't finish 'create' step.
>
> ERROR: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
>
> root@tickets:~#
>
> The database used in both tests was
>
> root@tickets:~# mysql --version
> mysql  Ver 14.14 Distrib 5.1.37, for debian-linux-gnu (x86_64) using  EditLine wrapper
> root@tickets:~#
>
> And, both versions of request-tracker were as ubuntu packages.
>

Revision history for this message
Dominic Hargreaves (dom) wrote :

What's odd here is that the database name is blank. I would be interested if this is reproducible in the current version of RT in Ubuntu (3.8.8-4).

There is an outstanding upstream ticket about some more pathological cases[1] but in this case it seems like the problem is the completely blank database name.

[1] http://issues.bestpractical.com/Ticket/Display.html?id=7568

Revision history for this message
Raubvogel (raubvogel) wrote :

Update: This still happens with Ubuntu 10.04 LTS and RT 3.8.7-1. I also tried on 10.10 and RT 3.8.8-4. And 11.04 and RT 3.8.10.-1. Issue still remains on all these combinations.

Revision history for this message
Raubvogel (raubvogel) wrote :

Ok, it seems a workaround is to first go to mysql (assuming this is the db you are using), and grant all privileges to the rt database (rt3 in this example) to the rt user (rtuser) but *without* creating the database itself. Then run rt-setup-database-3.8

Revision history for this message
Alex Vandiver (alexmv) wrote :

4.0-trunk has just merged a branch which explicitly disables empty branch names at configure time, which may catch this flavor of user error earlier.

Changed in request-tracker3.8 (Ubuntu):
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.