Migración de MySQL 5.5 a 5.6/ Migration from MySQL 5.5 to 5.6
- Crear una copia: mysqldump (shell> mysqldump --single-transaction --all-databases > bd_backup_20150115.sql;) o workbrench
- linux: es bueno comenzar con una actualizacion: sudo apt-get update
- detener el servicio de MySQL (consider setting innodb_fast_shutdown to 0 before shutting down, en InnoDB el apagado es mas lento y tendría q estar totalmente apagado)
- windows: NET STOP MySQL | C:\> "C:\Program Files\MySQL\MySQL Server 5.5\bin\mysqladmin" -u root shutdown
- linux:
- check: sudo service mysql status
- stop: sudo service mysql stop
- por si la nueva versión da problemas con el arranque: mantener la anterior con un rename de mysqld (/usr/sbin/mysqld -> /usr/sbin/mysqld-5.5) y hacer una copia de la configuracion actual (my.cnf o my.ini)
- lanzar la actualizacion
- windows: installer
- Red Hat:
- copiar el instalador mysql-apt-config_0.3.2-1ubuntu12.04_all.deb (para lanzar el apt-get)
- añadir el fichero anterior al repo: sudo dpkg -i mysql-apt-config_0.3.2-1ubuntu12.04_all.deb
- sudo apt-get install mysql-server
- sudo apt-get install libmysqlclient18
- CIUDADO!! en mi caso uso el python connector y en la version 2.0.2 daba un error de perdida de conexion y en la 2.0.3 no lo daba pero se quedaba colgado, por lo que he instalado el 1.2.3
- Mantener los parametros que han cambiado de valor por defecto para que funcione bien lo que teniamos, poniendo la siguiente configuracion en el fichero:
- windows: my.ini en el directorio raiz
- linux: my.cnf en el directorio raiz (/etc/mysql/my.cnf)
- [mysqld]
innodb_file_per_table=0
innodb_checksum_algorithm=INNODB
binlog_checksum=NONE
- Lanzar la comprobación de las tablas y que se actualicen/corrijan si hace falta (shell> mysql_upgrade -u root -p)
- rearrancar el servicio / programa
- windows: NET START MySQL / mysqld
- linux: sudo service mysql start
____________________________________________
- Create a backup: mysqldump (shell> mysqldump --single-transaction --all-databases > bd_backup_20150115.sql;) or workbrench
- linux: it is advisable to update the system: sudo apt-get update
- Stop the MySQL service (consider setting innodb_fast_shutdown to 0 before shutting down, in InnoDB the stop action takes more time and it is necessary a complete stop)
- windows: NET STOP MySQL | C:\> "C:\Program Files\MySQL\MySQL Server 5.5\bin\mysqladmin" -u root shutdown
- linux:
- check: sudo service mysql status
- stop: sudo service mysql stop
- Safety actions: keep a copy, with a rename, of mysqld (/usr/sbin/mysqld -> /usr/sbin/mysqld-5.5) an another of the current configuration (my.cnf o my.ini)
- Launch the actualization
- windows: installer
- Red Hat:
- copy the instaler mysql-apt-config_0.3.2-1ubuntu12.04_all.deb (to launch the apt-get)
- adding the file to the repo: sudo dpkg -i mysql-apt-config_0.3.2-1ubuntu12.04_all.deb
- sudo apt-get install mysql-server
- sudo apt-get install libmysqlclient18
- CAREFUL!! the python connector version 2.0.2 had a problem with connection and version 2.0.3 does not return the "lost connection error" but is frozen the thread, so I had to install the version 1.2.3
- Keeping the value of the paremeters that has change the default value in this version, so the following configuration must be added to configuration file:
- windows: my.ini (mysql path or "Program Data" folder)
- linux: my.cnf (path /etc/mysql/my.cnf)
- [mysqld]
innodb_file_per_table=0
innodb_checksum_algorithm=INNODB
binlog_checksum=NONE
- Checking problems and updating tables (shell> mysql_upgrade -u root -p)
- Starting the service or program
- windows: NET START MySQL / mysqld
- linux: sudo service mysql start
Refs:
- 5.5 to 5.6: http://dev.mysql.com/doc/refman/5.6/en/upgrading-from-previous-series.html
- APT upgrade: http://dev.mysql.com/doc/mysql-apt-repo-quick-guide/en/index.html#repo-qg-apt-upgrading
- windows upgrade: http://dev.mysql.com/doc/refman/5.6/en/windows-upgrading.html
No hay comentarios:
Publicar un comentario