MYSQL upgrade to 5.6.14 5.1.73

Read-only transactions in MySQL5.6 introduced improved to create a snapshot view of the cost, reduce the holding trx_sys-> time mutex, which is conducive to enhancing the performance of read-only; it has been well known.

鉴于我司版本极低,所以亟需升级,接下来把本次升级的步骤和填坑记录下来:

Upgrade online environment with:

  • CentOS 6.5
  • MySql5.1.73
  • Seafile (why mention him in the back mentioned him)

The first step: to prepare the installation files

wget http://dev.mysql.com/get/Downloads/MySQL-5.6/MySQL-shared-5.6.14-1.el6.x86_64.rpm/from/http://cdn.mysql.com/

wget http://dev.mysql.com/get/Downloads/MySQL-5.6/MySQL-client-5.6.14-1.el6.x86_64.rpm/from/http://cdn.mysql.com/

wget http://dev.mysql.com/get/Downloads/MySQL-5.6/MySQL-server-5.6.14-1.el6.x86_64.rpm/from/http://cdn.mysql.com/

Step Two: Back up the SQL data

Since our Mysql data directory in the default data directory Centos environment [/ var / lib / mysql], directly copy the backup directory on your machine.

The third step: uninstall the old version

yum remove mysql mysql-server mysql-libs compat-mysql51

Then it will delete python mysql connection of a dependent [MySQL-python]

Step four: Install the new version

rpm -ivh MySQL-shared-5.6.14-1.el6.x86_64.rpm
rpm -ivh MySQL-server-5.6.14-1.el6.x86_64.rpm
rpm -ivh MySQL-client-5.6.14-1.el6.x86_64.rpm

service mysql start

OK, here we generally that it is the upgrade is complete, and Ferguson. Teenagers too young ......

Stepped pit began:

  • Because a schema using a custom function, when calling the error "Can not load from mysql.proc"
    • mysql_upgrade -uroot -p password( Remember do not need to execute the command )
    • ALTER TABLE proc MODIFY COLUMN comment text CHARACTER SET utf8 COLLATE utf8_bin NOT NULL AFTER sql_mode;
    • The pit has been filled.
  • Seafile service is turned on, actually prompted me to create a new administrator user, connected to the client from the associated schema seafile in either table query, we are not able to find the table. Presumably the first command to the pit should not be performed destroyed.
    • Fortunately, we have backed up the data in a second step.
    • Replace the backup data decompression [/ var / lib / mysql], start error "MySQL ERROR! The server quit without updating PID file", view the error log output path /etc/my.cnf (if not /etc/my.cnf , the error log path / var / lib / mysql / [machine name] .err), View log
      • unknown variable ‘default-character-set=utf8’
      • Operating system error number 13 (file operation right), since the home file and the decompressed packet is not mysql, chown mysql: After successful mysql -R / var / lib / mysql.

So far all pits have been filled.

Original: Big Box  MYSQL upgrade to 5.6.14 5.1.73


Guess you like

Origin www.cnblogs.com/wangziqiang123/p/11618145.html