Create dump and restore all databases

I have 2 mariadb servers: please note both are IDENTICAL version installed in UBUNTU

*SOURCE: $ mysql --version mysql Ver 15.1 Distrib 10.3.32-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2

*TARGET: $ mysql --version mysql Ver 15.1 Distrib 10.3.32-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2

Here is the dump command executed in SOURCE mysqldump --user=root --password=[mypassword] --routines --lock-tables --databases portfolio > /home/sk/mariaDBBackups/portfolio.sql

Here is the restore command executed in TARGET (base) pista@pista-OptiPlex-390:/mariaDBBackups$ mysql -u root -p portfolio < portfolio.sql

And I get syntax errors: ERROR 1064 (42000) at line 1379: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '' at line 91

Is there a "compatible" mysqldump command. Kindly let me know what is the problem?

Comments

Comments loading...
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.