0

I have a MYSQL Server 5.6 on ubuntu 14.04, having more than 2000 databses. Now we have to upgrade it to MYSQL version 5.7. Kindly let me know how can i take backup of this huge data & upgrade process. Hoping for earliest response

03amittrivedi
  • 19
  • 1
  • 1
  • 3

1 Answers1

0

To backup and restore your databases

Export:- mysqldump -u root -p --all-databases > alldb.sql

Import:- mysql -u root -p < alldb.sql

If you want to install MySQL 5.7, you'll need to add the newer APT package repository from the MySQL APT repository page. Click Download on the bottom right, then copy the link on the next page from No thanks, just start my download. Download the .deb package to your server

wget https://dev.mysql.com/get/mysql-apt-config_0.8.1-1_all.deb

Next, install it using dpkg.

sudo dpkg -i mysql-apt-config_0.8.1-1_all.deb

You'll see a prompt that asks you which MySQL product you want to configure. The MySQL Server option, which is highlighted, should say mysql-5.7. If it doesn't, press ENTER, then scroll down to mysql-5.7 using the arrow keys, and press ENTER again.

Once the option says mysql-5.7, scroll down on the main menu to Apply and press ENTER again. Now, update your package index.

sudo apt-get update

Finally, install the MySQL-server package, which now contains MySQL 5.7.

sudo apt-get install mysql-server

Now upgrade all mysql databases .

sudo mysql_upgrade -u root -p

Now restart mysql server .

sudo service mysql restart
Sukhjinder Singh
  • 1,944
  • 2
  • 8
  • 17
  • Thanks for your kind response But i have 2500 databases with tables, is it not taking backup through sqldump command. Then suggest me how to deal this issue – 03amittrivedi Apr 07 '20 at 15:10