[mythtv-users] New install and my problmes.

R. G. Newbury newbury at mandamus.org
Sat Feb 3 00:31:51 UTC 2007


Go to mythtv.org.
On the left side of the page, there is a link Documentation.

Since you are having such trouble, you might find the howto at 
wilsonet.org (Jarod Wilson's howto) of great assistance, as it explains 
things well. It is for Fedora, but the only differences with other 
distros are how you install stuff, and some differences in the placement 
of files.

Damian Surr wrote:
>   
> Thanks for responding Geoff
> 
> To begin with, I was getting this:
> mysql> select host,user,password from user;
> +-----------+------------------+------------------+
> | host      | user             | password         |
> +-----------+------------------+------------------+
> | localhost | root             |                  |
> | MythBox   | root             |                  |
> | localhost | debian-sys-maint | 4bfb03e20e6b2002 |
> | localhost | mythtv           | 0476fc026afffe24 |
> | %         | mythtv           | 0476fc026afffe24 |
> +-----------+------------------+------------------+
> 5 rows in set (0.01 sec)
Ok you did have a mythtv user, with password set... possibly the wrong 
password..




> 
>> This will at least tell you what your users are, and whether a password 
>> has been set. If a password has been set for mysql user mythtv, you can 
>> delete that user ( delete from user where user = 'mythtv';) (yes that is 
>> confusing, one user is the table, and the other is the field).
>>   
> I followed your instructions and got this:
> mysql> select host,user,password from user;
> +-----------+------------------+------------------+
> | host      | user             | password         |
> +-----------+------------------+------------------+
> | localhost | root             |                  |
> | MythBox   | root             |                  |
> | localhost | debian-sys-maint | 4bfb03e20e6b2002 |
> +-----------+------------------+------------------+
> 3 rows in set (0.00 sec)


Ok so now you have deleted the mythtv user.

> I couldn't get anywhere with the above instructions. I'm sure it's 
> completely obvious to anyone who knows, but I tried following the 
> instructions and it didn't get me any further.
>
The script I was referring to is this:


CREATE DATABASE if not exists mythconverg;
GRANT ALL ON mythconverg.* TO mythtv at localhost IDENTIFIED BY "mythtv";
FLUSH PRIVILEGES;
GRANT CREATE TEMPORARY TABLES ON mythconverg.* TO mythtv at localhost 
IDENTIFIED BY "mythtv";
FLUSH PRIVILEGES;
ALTER DATABASE mythconverg DEFAULT CHARACTER SET latin1;

Save that to a file called mc.sql

then call it using:

"mysql -u root -p < mc.sq"

This will create the mythtv user, with password 'mythtv' and give the 
proper privileges.



> I searched the net for Mythtv and Mysql and looked for anything 
> relevant. A couple of pages came up with a couple of things that I tried.
> The end of one page had these commands that seemed to work ok:
> sudo mythbackend &
> sudo mythfilldatabase

Those commands start the backend as root, and run mythfilldatabase, as 
root. Both are useless until you get the database running..

> I think it was after doing all of the above that going into the front 
> end let me watch TV again. Result!, but still lots of problems.
> 
> Another page on the Ubuntu forums recommended this ..
> sudo /usr/bin/mysql_install_db
YOu are past there.

> sudo /usr/bin/mysqladmin -u root -h localhost password ''
> sudo dpkg-reconfigure --force mythtv-database



  All seemed to go well, but now I have:
> mysql> select host,user,password from user;
> +-----------+------------------+------------------+
> | host      | user             | password         |
> +-----------+------------------+------------------+
> | localhost | root             |                  |
> | MythBox   | root             |                  |
> | localhost | debian-sys-maint | 4bfb03e20e6b2002 |
> | %         | mythtv           | 32b1b1fb4cb0846d |
> | localhost | mythtv           | 32b1b1fb4cb0846d |
> +-----------+------------------+------------------+
> 
> Still, I had TV again, so that's something.
> 
> Just rebooted and I don't have TV again. Mythfrontend just gives me 
> LOADS of errors like this:
> QSqlQuery::exec: database not open
> QSqlQuery::exec: database not open
> 2007-02-02 10:33:32.384 DB Error (KickDatabase):
> Query was:
> SELECT NULL;
> No error type from QSqlError?  Strange...
> 2007-02-02 10:33:33.996 Unable to connect to database!
> 2007-02-02 10:33:33.996 Driver error was [1/1045]:
> QMYSQL3: Unable to connect
> Database error was:
> Access denied for user 'mythtv'@'localhost' (using password: YES)
> 
> QSqlQuery::exec: database not open
> QSqlQuery::exec: database not open
> 2007-02-02 10:33:34.052 DB Error (KickDatabase):
> Query was:
> SELECT NULL;
> No error type from QSqlError?  Strange...
> 2007-02-02 10:33:34.104 Failed to init MythContext, exiting.

Under Fedora, we use scripts in /etc/init.d/ to start service programs. 
Mysql and mythbackend are atarted that way.
Unlesss you have started mysql, and then mythbackend, you will not be 
able to watch TV.

Looks like you do not have mysql running, when you tried this: DATABASE 
NOT OPEN.

> Where in the documentation should I be looking? Sorry if I seem stupid, 
> but I can usually find everything I need for anything on google within a 
> minute or two. This has me stumped. I'm sure (and hope) it looks very 
> simple from the outside, but not from here.


See my comments at the top. At the moment, you are just thrashing around 
trying ANYTHING.

THAT DOES NOT WORK FOR MYTHTV. The entire edifice must be built carefully.

Go read those pages. Then check that mysqld (the server) is running and 
that user mythtv can log on and access database mythconverg.

Then run mythtv-setup and make sure that your backend is pointed to 
properly on the first page of 'General'. It is quite possible that you 
have filled in an IP address at one point when you are running on 
'localhost....the IP address should be 127.0.0.1 and the name should be 
localhost as that is where you mythtv user is tied to.
(Once you get this working you can think about what has to be done to 
add another frontend box, which will require a real address).

> Is there a way to reset whatever's going on with mysql, or myth, or 
> whatever the problem may be?
You do not need to 're-set' anything yet.
Read the documentation.


Geoff

-- 
              R. Geoffrey Newbury			
            Barrister and Solicitor
       Suite 106, 150 Lakeshore Road West
          Mississauga, Ontario, L5H 3R2

         o905-271-9600 f905-271-1638
           newbury at mandamus.org

        Helping with the HTTP issue
<a href="http://www.w3.org/Protocols/">HTTP</a>


More information about the mythtv-users mailing list