[mythtv-users] Problem Connecting To Database

Robin Hill myth at robinhill.me.uk
Sun Nov 12 19:58:51 UTC 2006


On Sun Nov 12, 2006 at 01:32:23PM -0600, Tom Purl wrote:

> >>On 11/12/06, Tom Purl <[1]tom at tompurl.com> wrote:
> >>  Here's my problem:  when I try and start mythbackend
> >>  (sudo /etc/init.d/mythbackend start) , I get the following error
> >>  messasge
> >>  in /var/log/mythtv/mythbackend.log:
> >> 
> >>      QSqlQuery::exec: database not open
> >>      QSqlQuery::exec: database not open
> >> 
> >>  mysql is running, so I don't understand why I'm getting this error.
> >>  Can anyone else see why this may be happening?
> >> 
> >>  Thanks a ton in advance!
> >> 
> > So you can "mysql -u mythtv -p mythconverg"?
> 
> Yes, except the name of my database is mythdb.  Also, in
> mythtv-setup, I use 127.0.0.1 instead of localhost, so I logged into
> mysql using the following command:
> 
>     mysql -u mythtv -h 127.0.0.1 -p mythdb
> 
> ...and it worked.  
>   
> > Try using your real IP address instead of localhost. Something along
> > the lines of [2]192.168.1.2. Use that in mythtv-setup instead of
> > localhost.
> 
> Since I'm using the 127.0.0.1 ip address, and tested it with the
> mysql client, I didn't try this workaround.
> 
> What else could I be missing?
> 
When you're using the mysql command-line client to connect to 127.0.0.1,
then it defaults to using unix sockets rather than TCP/IP.  It may well
be that the QT driver doesn't do this and your database isn't listening
for network connections at all.  You can check this by adding
--protocol=TCP to your command line.  If this is the case then make sure
that you don't have "skip-networking" set in your /etc/mysql/my.cnf
file.

HTH,
        Robin
-- 
     ___        
    ( ' }     |       Robin Hill        <myth at robinhill.me.uk>  |
   / / )      | Little Jim says ....                            |
  // !!       |      "He fallen in de water !!"                 |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
Url : http://mythtv.org/pipermail/mythtv-users/attachments/20061112/dca5173c/attachment.pgp 


More information about the mythtv-users mailing list