Actually, just restarting the server should do the trick. It seems
like mysql_upgrade did it's job correctly.
Can you restart teh server and check the logs?

Walter

OlinData: Professional services for MySQL
Support * Consulting * Administration
http://www.olindata.com



On Wed, Jan 28, 2009 at 4:13 AM, JD <jd1...@gmail.com> wrote:
> Problem with yum remove mysql is that it will also remove all it's
> dependents,
> whereas yum install mysql will not restore the dependents.
>
> Also, you are probably right re: 5.0.x and 5.1.x
>
> At anywho, I ran:
>
> }# mysql_upgrade --user=root  --password='theNewPassword' Looking for
> 'mysql' as: mysql
> Looking for 'mysqlcheck' as: mysqlcheck
> Running 'mysqlcheck'...
> mysql.columns_priv                                 OK
> mysql.db                                           OK
> mysql.func                                         OK
> mysql.help_category
> error    : Table upgrade required. Please do "REPAIR TABLE `help_category`"
> to fix it!
> mysql.help_keyword
> error    : Table upgrade required. Please do "REPAIR TABLE `help_keyword`"
> to fix it!
> mysql.help_relation                                OK
> mysql.help_topic
> error    : Table upgrade required. Please do "REPAIR TABLE `help_topic`" to
> fix it!
> mysql.host                                         OK
> mysql.proc
> error    : Table upgrade required. Please do "REPAIR TABLE `proc`" to fix
> it!
> mysql.procs_priv                                   OK
> mysql.tables_priv                                  OK
> mysql.time_zone                                    OK
> mysql.time_zone_leap_second                        OK
> mysql.time_zone_name
> error    : Table upgrade required. Please do "REPAIR TABLE `time_zone_name`"
> to fix it!
> mysql.time_zone_transition                         OK
> mysql.time_zone_transition_type                    OK
> mysql.user                                         OK
>
> Repairing tables
> mysql.help_category                                OK
> mysql.help_keyword                                 OK
> mysql.help_topic                                   OK
> mysql.proc                                         OK
> mysql.time_zone_name                               OK
> Running 'mysql_fix_privilege_tables'...
> OK
>
> So, you want me to
>   1. Stop the server
>   2. Remove /var/lib/mysql/mysql  right?
>   3. Restart the server
> Correct?
>
>
>
> Walter Heck wrote:
>>
>> mysql.user is a table name, it is in the form of database_name.table_name.
>> Mysql has a "system database" conveniently called mysql :)
>>
>>
>>>
>>> 090127 18:17:18 [ERROR] Column count of mysql.db is wrong. Expected 22,
>>> found 20. Created with MySQL 50045, now running 50130. Please use
>>> mysql_upgrade to fix this error.
>>>
>>
>> I don't know how you got to where you are now, but it seems like your
>> system database is from MySQL 5.0.45, while you seem to be running
>> 5.1.30.
>>
>> couple of options:
>>
>> 1) try mysql_upgrade again, using root and it's password this time
>> 2) remove the mysql dir inside /var/lib/mysql and then use
>> mysql_install_db to recreate them properly
>> 3) just remove mysql completely and reinstall from scratch
>>
>> Normally I would recommend 2, but in your case I would probably
>> recommend 3 since you just need mysql to run amarok2 (i would
>> recommend songbird anyway: http://www.getsongbird.com/ ;) ) and are
>> not planning on doing anything serious with mysql. Depending on the
>> distro you are using, it can be as simple as yum remove mysql and yum
>> install mysql (removing /var/lib/mysql in between). Your choice though
>> :)
>>
>> good luck!
>>
>> Walter
>>
>> can you try running mysql_upgrade
>> OlinData: Professional services for MySQL
>> Support * Consulting * Administration
>> http://www.olindata.com
>>
>>
>>
>> On Wed, Jan 28, 2009 at 3:21 AM, JD <jd1...@gmail.com> wrote:
>>
>>>
>>> OK, I located a weblog on how to change the password
>>> and it worked.
>>>
>>> I then stopped and started the serever, and this is what it belched out
>>> in
>>> the mysqld.log:
>>>
>>> 090127 18:17:16 [Note] /usr/libexec/mysqld: Normal shutdown
>>>
>>> 090127 18:17:16  InnoDB: Starting shutdown...
>>> 090127 18:17:17  InnoDB: Shutdown completed; log sequence number 0 44044
>>> 090127 18:17:17 [Note] /usr/libexec/mysqld: Shutdown complete
>>>
>>> 090127 18:17:17 mysqld_safe mysqld from pid file
>>> /var/run/mysqld/mysqld.pid
>>> ended
>>> 090127 18:17:18 mysqld_safe Starting mysqld daemon with databases from
>>> /var/lib/mysql
>>> /usr/libexec/mysqld: Table 'mysql.plugin' doesn't exist
>>> 090127 18:17:18 [ERROR] Can't open the mysql.plugin table. Please run
>>> mysql_upgrade to create it.
>>> 090127 18:17:18  InnoDB: Started; log sequence number 0 44044
>>> 090127 18:17:18 [ERROR] Can't open and lock privilege tables: Table
>>> 'mysql.servers' doesn't exist
>>> 090127 18:17:18 [ERROR] Column count of mysql.db is wrong. Expected 22,
>>> found 20. Created with MySQL 50045, now running 50130. Please use
>>> mysql_upgrade to fix this error.
>>> 090127 18:17:18 [ERROR] mysql.user has no `Event_priv` column at position
>>> 29
>>> 090127 18:17:18 [ERROR] Cannot open mysql.event
>>> 090127 18:17:18 [ERROR] Event Scheduler: An error occurred when
>>> initializing
>>> system tables. Disabling the Event Scheduler.
>>> 090127 18:17:18 [Note] /usr/libexec/mysqld: ready for connections.
>>> Version: '5.1.30'  socket: '/var/lib/mysql/mysql.sock'  port: 3306  MySQL
>>> Community Server (GPL) by Remi
>>>
>>> So, how do I fix those errors about 'mysql.plugin' and mysql.db and
>>> mysql.user
>>> For that matter why does it even have a mysql.user ??? Should it not be
>>> mysql.root?
>>>
>>>
>>>
>>>
>>>
>>> Walter Heck wrote:
>>>
>>>>
>>>> We're slowly getting there ;)
>>>> that is the root account for the mysql server, not the linux root
>>>> account
>>>> :)
>>>> when you installed mysql, you chose a root password. If you didn't,
>>>> look up how to reset your mysql root account's password. Plenty of
>>>> info on the web :)
>>>>
>>>> good luck!
>>>>
>>>> Walter
>>>>
>>>> OlinData: Professional services for MySQL
>>>> Support * Consulting * Administration
>>>> http://www.olindata.com
>>>>
>>>>
>>>>
>>>> On Wed, Jan 28, 2009 at 1:47 AM, JD <jd1...@gmail.com> wrote:
>>>>
>>>>
>>>>>
>>>>> I did the chmod. Then
>>>>> # ls -latrR /var/lib/mysql
>>>>> /var/lib/mysql:
>>>>> total 20548K
>>>>> drwxrwxr-x  2 mysql mysql     4096 2007-12-15 15:36 test/
>>>>> -rw-rw-r--  1 mysql mysql  5242880 2007-12-15 15:36 ib_logfile1
>>>>> drwxrwxr-x  2 mysql mysql     4096 2007-12-15 16:10 ampache/
>>>>> drwxrwxr-x  2 mysql mysql     4096 2009-01-21 14:12 mysql/
>>>>> drwxr-xr-x 53 root  root      4096 2009-01-27 14:14 ../
>>>>> srwxrwxrwx  1 mysql mysql        0 2009-01-27 16:35 mysql.sock=
>>>>> -rw-rw-r--  1 mysql mysql  5242880 2009-01-27 16:35 ib_logfile0
>>>>> -rw-rw-r--  1 mysql mysql 10485760 2009-01-27 16:35 ibdata1
>>>>> drwxrwxr-x  5 mysql mysql     4096 2009-01-27 16:35 ./
>>>>>
>>>>> /var/lib/mysql/test:
>>>>> total 12K
>>>>> drwxrwxr-x 2 mysql mysql 4096 2007-12-15 15:36 ./
>>>>> drwxrwxr-x 5 mysql mysql 4096 2009-01-27 16:35 ../
>>>>>
>>>>> /var/lib/mysql/ampache:
>>>>> total 16K
>>>>> -rw-rw-r-- 1 mysql mysql   65 2007-12-15 16:10 db.opt
>>>>> drwxrwxr-x 2 mysql mysql 4096 2007-12-15 16:10 ./
>>>>> drwxrwxr-x 5 mysql mysql 4096 2009-01-27 16:35 ../
>>>>>
>>>>> /var/lib/mysql/mysql:
>>>>> total 788K
>>>>> -rw-rw-r-- 1 mysql mysql  10330 2007-12-15 15:36 user.frm
>>>>> -rw-rw-r-- 1 mysql mysql   1024 2007-12-15 15:36
>>>>> time_zone_transition_type.MYI
>>>>> -rw-rw-r-- 1 mysql mysql      0 2007-12-15 15:36
>>>>> time_zone_transition_type.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   8748 2007-12-15 15:36
>>>>> time_zone_transition_type.frm
>>>>> -rw-rw-r-- 1 mysql mysql   1024 2007-12-15 15:36
>>>>> time_zone_transition.MYI
>>>>> -rw-rw-r-- 1 mysql mysql      0 2007-12-15 15:36
>>>>> time_zone_transition.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   8686 2007-12-15 15:36
>>>>> time_zone_transition.frm
>>>>> -rw-rw-r-- 1 mysql mysql   1024 2007-12-15 15:36 time_zone_name.MYI
>>>>> -rw-rw-r-- 1 mysql mysql      0 2007-12-15 15:36 time_zone_name.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   8606 2007-12-15 15:36 time_zone_name.frm
>>>>> -rw-rw-r-- 1 mysql mysql   1024 2007-12-15 15:36 time_zone.MYI
>>>>> -rw-rw-r-- 1 mysql mysql      0 2007-12-15 15:36 time_zone.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   1024 2007-12-15 15:36
>>>>> time_zone_leap_second.MYI
>>>>> -rw-rw-r-- 1 mysql mysql      0 2007-12-15 15:36
>>>>> time_zone_leap_second.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   8624 2007-12-15 15:36
>>>>> time_zone_leap_second.frm
>>>>> -rw-rw-r-- 1 mysql mysql   8636 2007-12-15 15:36 time_zone.frm
>>>>> -rw-rw-r-- 1 mysql mysql   1024 2007-12-15 15:36 tables_priv.MYI
>>>>> -rw-rw-r-- 1 mysql mysql      0 2007-12-15 15:36 tables_priv.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   8947 2007-12-15 15:36 tables_priv.frm
>>>>> -rw-rw-r-- 1 mysql mysql   1024 2007-12-15 15:36 procs_priv.MYI
>>>>> -rw-rw-r-- 1 mysql mysql      0 2007-12-15 15:36 procs_priv.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   8875 2007-12-15 15:36 procs_priv.frm
>>>>> -rw-rw-r-- 1 mysql mysql   1024 2007-12-15 15:36 proc.MYI
>>>>> -rw-rw-r-- 1 mysql mysql      0 2007-12-15 15:36 proc.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   9691 2007-12-15 15:36 proc.frm
>>>>> -rw-rw-r-- 1 mysql mysql   1024 2007-12-15 15:36 host.MYI
>>>>> -rw-rw-r-- 1 mysql mysql      0 2007-12-15 15:36 host.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   9416 2007-12-15 15:36 host.frm
>>>>> -rw-rw-r-- 1 mysql mysql  17408 2007-12-15 15:36 help_topic.MYI
>>>>> -rw-rw-r-- 1 mysql mysql 333276 2007-12-15 15:36 help_topic.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   8770 2007-12-15 15:36 help_topic.frm
>>>>> -rw-rw-r-- 1 mysql mysql  15360 2007-12-15 15:36 help_relation.MYI
>>>>> -rw-rw-r-- 1 mysql mysql   7281 2007-12-15 15:36 help_relation.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   8630 2007-12-15 15:36 help_relation.frm
>>>>> -rw-rw-r-- 1 mysql mysql  14336 2007-12-15 15:36 help_keyword.MYI
>>>>> -rw-rw-r-- 1 mysql mysql  77815 2007-12-15 15:36 help_keyword.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   8612 2007-12-15 15:36 help_keyword.frm
>>>>> -rw-rw-r-- 1 mysql mysql   3072 2007-12-15 15:36 help_category.MYI
>>>>> -rw-rw-r-- 1 mysql mysql  20916 2007-12-15 15:36 help_category.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   8700 2007-12-15 15:36 help_category.frm
>>>>> -rw-rw-r-- 1 mysql mysql   1024 2007-12-15 15:36 func.MYI
>>>>> -rw-rw-r-- 1 mysql mysql      0 2007-12-15 15:36 func.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   8665 2007-12-15 15:36 func.frm
>>>>> -rw-rw-r-- 1 mysql mysql   9494 2007-12-15 15:36 db.frm
>>>>> -rw-rw-r-- 1 mysql mysql   1024 2007-12-15 15:36 columns_priv.MYI
>>>>> -rw-rw-r-- 1 mysql mysql      0 2007-12-15 15:36 columns_priv.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   8820 2007-12-15 15:36 columns_priv.frm
>>>>> -rw-rw-r-- 1 mysql mysql    256 2007-12-15 16:10 user.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   1314 2007-12-15 16:10 db.MYD
>>>>> -rw-rw-r-- 1 mysql mysql   2048 2007-12-17 00:03 user.MYI
>>>>> -rw-rw-r-- 1 mysql mysql   4096 2007-12-17 00:03 db.MYI
>>>>> drwxrwxr-x 2 mysql mysql   4096 2009-01-21 14:12 ./
>>>>> -rw-rw---- 1 mysql mysql  12288 2009-01-21 14:12 .swp
>>>>> drwxrwxr-x 5 mysql mysql   4096 2009-01-27 16:35 ../
>>>>>
>>>>>
>>>>> I restarted mysqld (service mysqld restart) and this is
>>>>> what got written in the mysql.log
>>>>>
>>>>>
>>>>> 090127 16:40:09 mysqld_safe Starting mysqld daemon with databases from
>>>>> /var/lib/mysql
>>>>> /usr/libexec/mysqld: Table 'mysql.plugin' doesn't exist
>>>>> 090127 16:40:09 [ERROR] Can't open the mysql.plugin table. Please run
>>>>> mysql_upgrade to create it.
>>>>> 090127 16:40:09  InnoDB: Started; log sequence number 0 43655
>>>>> 090127 16:40:09 [ERROR] Can't open and lock privilege tables: Table
>>>>> 'mysql.servers' doesn't exist
>>>>> 090127 16:40:09 [ERROR] Column count of mysql.db is wrong. Expected 22,
>>>>> found 20. Created with MySQL 50045, now running 50130. Please use
>>>>> mysql_upgrade to fix this error.
>>>>> 090127 16:40:09 [ERROR] mysql.user has no `Event_priv` column at
>>>>> position
>>>>> 29
>>>>> 090127 16:40:09 [ERROR] Cannot open mysql.event
>>>>> 090127 16:40:09 [ERROR] Event Scheduler: An error occurred when
>>>>> initializing
>>>>> system tables. Disabling the Event Scheduler.
>>>>> 090127 16:40:09 [Note] /usr/libexec/mysqld: ready for connections.
>>>>> Version: '5.1.30'  socket: '/var/lib/mysql/mysql.sock'  port: 3306
>>>>>  MySQL
>>>>> Community Server (GPL) by Remi
>>>>>
>>>>> So, I ssh'ed into localhost as user mysql and ran the command
>>>>> mysql_upgrade,
>>>>> and it belched out:
>>>>>
>>>>> -bash-3.2$ id
>>>>> uid=27(mysql) gid=27(mysql) groups=27(mysql)
>>>>> -bash-3.2$ mysql_upgrade
>>>>> Looking for 'mysql' as: mysql
>>>>> Looking for 'mysqlcheck' as: mysqlcheck
>>>>> Running 'mysqlcheck'...
>>>>> mysqlcheck: Got error: 1045: Access denied for user 'root'@'localhost'
>>>>> (using password: NO) when trying to connect
>>>>> FATAL ERROR: Upgrade failed
>>>>>
>>>>> I dont get it. I ssh'ed into localhost as follows:
>>>>> ssh my...@localhost
>>>>> Why does it think I am root??
>>>>>
>>>>>
>>>>>
>>>>> Walter Heck wrote:
>>>>>
>>>>>
>>>>>>
>>>>>> Ah, try this:
>>>>>>
>>>>>> "chmod ug+rw ibdata1" and the same for your iblogfile0 and iblogfile1
>>>>>> files..
>>>>>>
>>>>>> Walter
>>>>>>
>>>>>> OlinData: Professional services for MySQL
>>>>>> Support * Consulting * Administration
>>>>>> http://www.olindata.com
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Wed, Jan 28, 2009 at 12:48 AM, JD <jd1...@gmail.com> wrote:
>>>>>>
>>>>>>
>>>>>>
>>>>>>>
>>>>>>> ls -altr /var/lib/mysql
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>
>>>>
>>
>>
>

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/mysql?unsub=arch...@jab.org

Reply via email to