Friday, October 20, 2006

2nd Week: MythTV Database Issues

OK, for the second time in my life I had to scour the internet for the solution to a problem with a new installation of MythTV (from CVS). I'm putting this here so I can find it again in future!

If you try and run mythfrontend or mythtv-setup and get errors such as the following:

QSqlDatabase: QMYSQL3 driver not loaded
QSqlDatabase: available drivers:
2006-10-20 11:14:52.435 New DB connection, total: 1
2006-10-20 11:14:52.436 Unable to connect to database!
2006-10-20 11:14:52.437 No error type from QSqlError? Strange...
QSqlQuery::exec: database not open
QSqlQuery::exec: database not open
2006-10-20 11:14:52.496 DB Error (KickDatabase):
Query was:
SELECT NULL;
No error type from QSqlError? Strange...
2006-10-20 11:14:52.572 Unable to connect to database!
2006-10-20 11:14:52.573 No error type from QSqlError? Strange...

... then the solution is twofold. Firstly make sure you have the Qt MySQL drivers installed (Ubuntu people: that's libqt3-mt-mysql). Secondly - and this is the bit that always takes ages to find... You need an /etc/ld/so.conf file that contains the path to the said driver. Ubuntu people: /usr/local/lib.

That's it. That's what takes hours to solve. Not any more.

No comments: