[mythtv-users] Problem with Ubuntu upgrade
Damian
myth at surr.co.uk
Fri Oct 22 12:03:26 UTC 2010
On 22/10/2010 03:17, mythtv-users-request at mythtv.org wrote:
> Date: Thu, 21 Oct 2010 19:05:41 -0500
> From: Greg Oliver<oliver.greg at gmail.com>
> Subject: Re: [mythtv-users] Problem with Ubuntu upgrade
> To:myth at surr.co.uk
> Cc: Discussion about MythTV<mythtv-users at mythtv.org>
> Message-ID:
> <AANLkTi=Yv+fPq64nzFZ76piWJhDtS6+LHyq9RAWDxs6B at mail.gmail.com>
> Content-Type: text/plain; charset=UTF-8
>
> On Thu, Oct 21, 2010 at 6:22 PM, Damian<myth at surr.co.uk> wrote:
>> > On 21/10/2010 23:13, Greg Oliver wrote:
>>> >>
>>> >> On Thu, Oct 21, 2010 at 4:58 PM, Damian<myth at surr.co.uk> wrote:
>>>> >>>
>>>> >>> On 21/10/2010 13:00,mythtv-users-request at mythtv.org wrote:
>>>>> >>>>
>>>>> >>>> Date: Thu, 21 Oct 2010 12:09:45 +0100
>>>>> >>>> From: Jason Chambers<lists at purplish-monkey.com>
>>>>> >>>> Subject: Re: [mythtv-users] Problem with Ubuntu upgrade
>>>>> >>>> To:mythtv-users at mythtv.org
>>>>> >>>> Message-ID:<4CC01F79.1090802 at purplish-monkey.com>
>>>>> >>>> Content-Type: text/plain; charset=ISO-8859-1
>>>>> >>>>
>>>>> >>>> On 20/10/2010 09:46, Damian wrote:
>>>>>> >>>>>
>>>>>>> >>>>>> On 20/10/2010 01:37, David Whyte wrote:
>>>>>>> >>>>>>
>>>>>>>>> >>>>>>>> On Wed, Oct 20, 2010 at 9:11 AM, Damian<myth at surr.co.uk> wrote:
>>>>> >>>>
>>>>> >>>> <snip>
>>>>> >>>>
>>>>>>>>>>> >>>>>>>>>> 2010-10-20 00:01:05.162 New DB connection, total: 1
>>>>>>>>>>> >>>>>>>>>> 2010-10-20 00:01:05.169 Unable to connect to database!
>>>>>>>>>>> >>>>>>>>>> 2010-10-20 00:01:05.176 Driver error was [1/1045]:
>>>>>>>>>>> >>>>>>>>>> QMYSQL: Unable to connect
>>>>>>>>>>> >>>>>>>>>> Database error was:
>>>>>>>>>>> >>>>>>>>>> Access denied for user 'mythtv'@'MythBox' (using password: YES)
>>>>>>>>>>> >>>>>>>>>>
>>>>>>> >>>>>>
>>>>>>>>> >>>>>>>>
>>>>>>>>> >>>>>>>> Maybe you need to make sure of the following:
>>>>>>>>> >>>>>>>>
>>>>>>>>> >>>>>>>> 1) You have your mythtv configuration files configured properly
>>>>>>>>> >>>>>>>> with
>>>>>>>>> >>>>>>>> the correct mythtv DB credentials. There are numerous files to
>>>>>>>>> >>>>>>>> check
>>>>>>>>> >>>>>>>> here.
>>>>>>>>> >>>>>>>> 2) Is your mysql binding to the correct network address and
>>>>>>>>> >>>>>>>> allowing
>>>>>>>>> >>>>>>>> connections from within your LAN.
>>>>> >>>>
>>>>> >>>> I don't think its 2) as that would give a different error. The message
>>>>> >>>> would be "Can't connect to MySQL server on ..." wouldn't it?
>>>>> >>>>
>>>>> >>>> The access denied messages suggests that the username/password/database
>>>>> >>>> name are wrong. See
>>>>> >>>> http://dev.mysql.com/doc/refman/5.1/en/access-denied.html.
>>>>> >>>>
>>>>> >>>> So either your ~/.mythtv/config.xml has the wrong values in it, or
>>>>> >>>> something (probably the upgrade from the sounds of your original post)
>>>>> >>>> has changed/removed the user's password or permissions.
>>>>> >>>>
>>>>>>> >>>>>> My understanding goes as far as agreeing with what needs to be done,
>>>>>>> >>>>>> but
>>>>>>> >>>>>> I have no idea what to actually check/change or how to go about it.
>>>>>>> >>>>>> What
>>>>>>> >>>>>> should I do next?
>>>>> >>>>
>>>>> >>>> Forget running mythbackend etc. - instead go straight to a shell prompt
>>>>> >>>> on the backend box and try the following command:
>>>>> >>>>
>>>>> >>>> $ mysql -u mythtv -p -h MythBox mythconverg
>>>>> >>>>
>>>>> >>>> When prompted for the password use the same value from
>>>>> >>>> ~/.mythtv/config.xml.
>>>>> >>>>
>>>>> >>>> (if you have used a non-default database name then you need to replace
>>>>> >>>> mythconverg - the correct value is in ~/.mythtv/config.xml too).
>>>>> >>>>
>>>>> >>>> This should fail with the same "Access denied for user
>>>>> >>>> 'mythtv'@'MythBox' (using password: YES)".
>>>>> >>>>
>>>>> >>>> Then readhttp://dev.mysql.com/doc/refman/5.1/en/privilege-system.html
>>>>> >>>> to figure out how to set the user access correctly for your setup and
>>>>> >>>> repeat the mysql command above until it connects OK.
>>>>> >>>>
>>>>> >>>> Once the mysql command successfully connects, then MythTV should be fine
>>>>> >>>> too.
>>>>> >>>>
>>>>> >>>> Regards,
>>>>> >>>> Jason
>>>> >>>
>>>> >>> Thanks for the responses! I'm starting to get somewhere I think.
>>>> >>>
>>>> >>> Here are the steps I've taken:
>>>> >>>
>>>> >>> 1) Checked that I can log in to phpmyadmin as root. I can.
>>>> >>>
>>>> >>> 2) Checked that I can log in to phpmyadmin as mythtv using the password
>>>> >>> found in ~/.mythtv/config.xml. I can
>>>> >>>
>>>> >>> 2) Ran:
>>>> >>> mysql -u mythtv -p -h MythBox mythconverg
>>>> >>> and got:
>>>> >>> Access denied for user 'mythtv'@'MythBox' (using password: YES)
>>>> >>>
>>>> >>> 3) Logged into phpmyadmin as root and went to the privileges section.
>>>> >>> I could see 2 mythtv users in there. One had the host '%' and one had the
>>>> >>> host 'localhost' (neither had the host 'MythBox').
>>>> >>> Both just had 'Usage' listed under privilages, so I edited them and
>>>> >>> clicked
>>>> >>> on 'Check All' to grant all privilages.
>>> >>
>>> >> The password field on the entry with % (that is a SQL wildcard)
>>> >> probably has a diferent password than the localhost entry ? You can
>>> >> either cut and paste from the localhost entry into the % entry in
>>> >> phpmyadmin, or change it from the sql command line like previously
>>> >> posted.
>> >
>> >
>> > Thanks for that Greg,
>> >
>> > In phpmyadmin, I have entered the mythtv password everywhere that I can
>> > enter it relating to the mythtv@% user (ie, reset the password to the one I
>> > know was right before the upgrade) and granted all access. I have also added
>> > mythconverg specific privileges specifically and granted all access.
>> >
>> > Do I have to add Table-specific privileges?
>> >
>> > mysql -u mythtv -p -h MythBox mythconverg
>> >
>> > still wont let me in.
>> >
>> > Anything else I can try?
>> >
>> >
>>> >>
>>>> >>> I was hopeful that this would work, but:
>>>> >>> mysql -u mythtv -p -h MythBox mythconverg
>>>> >>> still returned:
>>>> >>> Access denied for user 'mythtv'@'MythBox' (using password: YES)
>>>> >>>
>>>> >>> Do I need to set up another user with 'MythBox' as the host?
>>> >>
>>> >> No - The '%' is everywhere
>>> >>
>>>> >>> Sorry if phpmyadmin is looked down on, but it's a lot more user friendly
>>>> >>> than the command line. I love the comand line when I know what I'm doing,
>>>> >>> but not when I don't.
>>>> >>>
>>>> >>> What should I do next?
> I'm not very familiar with phpmyadmin. It probably did not do a flush
> privileges since you just pasted the password in, so...
The output of each command follows the command in a line starting **
> mysql -u root -p mythconverg
> grant all on mythconverg.* to mythtv@"%" identified by "mythtv";
** Query OK, 0 rows affected (0.03 sec)
> grant all on mythconverg.* to mythtv@"localhost" identified by "mythtv";
** Query OK, 0 rows affected (0.00 sec)
> flush privileges;
** Query OK, 0 rows affected (0.00 sec)
> use mysql;
** Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
> update user set Password=PASSWORD('mythtv') WHERE user='mythtv';
> flush privileges;
**
Query OK, 0 rows affected (0.01 sec)
Rows matched: 2 Changed: 0 Warnings: 0
> \q
>
> That should do it.. You can try to just 'flush privileges' first to
> make it use the changes made in phpmyadmin regarding the password..
> Either way, if that still does not work, in /etc/my.conf (changes per
> distro), mythtv may be setup to only listen on localhost. I believe
> it ships that way, but mythtv distros enable the network if you
> specify more than one machine. I'm not 100% sure what yours is set to
> though..
>
> http://www.mythtv.org/docs/mythtv-HOWTO-6.html has good info.
> -Greg
>
I've not looked at my.conf yet. Need to leave my machine not but that
will be the first thing I do when I get back.
Thanks for helping Greg.
Damian
More information about the mythtv-users
mailing list