transfer from server with mariadb 10.3 to server with mysql 8.0

Operating System & Version
Ubuntu 20.04
cPanel & WHM Version
102

bitpt

Active Member
Sep 28, 2006
43
4
158
When try transfer from a server with Mariadb10.3 to Mysql 8.0 transfer in some databases got error and do not work.
However, when do a fullbackup and a restore work always well.
Now i need transfer a large site(more then 200G) and transfer is better option (site not stop).
Anyone know why in fullbackup and restore work fine, but not in direct transfer?

Thank You!!!
 
Last edited:

bitpt

Active Member
Sep 28, 2006
43
4
158
seems user in "stream account transfer" is username and with "restorepkg" is root.

Solve this, first transfer (server load is much lower), then dump db with root permissions.

Account transfer needs an option to allow restore with root or any other mechanism or option that allows transferring the db without issues.
 

Steini Petur

Well-Known Member
Apr 24, 2016
89
21
58
Iceland
cPanel Access Level
Root Administrator
Hi,
Please note that if you have a large server, you may run into much more than a brick wall when going over from 10.3 to 8.0


These were just the few issues we ran into, I had to help clients with databases which had TEXT DEFAULT which are not allowed in 8, what you may not realize is if you are restoring 100's upon 100's of databases and accounts you may miss the text when it just didn't add the database for John or Jane..

I will be doing another set of 6 servers for our company but I will be staying away from MySQL 8.0!, Ill start at 10.3 MariaDB and go with it, remember if you do 8.0 you cant roll back.

My best way to do this especially if its many accounts is to do this

Backup in commandline
for x in `ls /var/cpanel/userdata`; do /scripts/pkgacct $x; done

Once done, I like to move them fast so
for x in `ls -arth /home | grep tar.gz`; do rsync -avh --progress -e 'ssh -p (port) -T -o Compression=no -x' $x [email protected](IP):/home/; done

Then just loop through them to restore
for x in `ls /home | grep tar.gz`; do /scripts/restorepkg --unrestricted --force --allow_reseller $x; done

Just my two cents, and careful with MySQL 8.0 cant stress the hell I was in for 2 nights straight. Remember if you are not in Console and an SSH session, do this in screen, so you can get back to it with screen -r in case you lose the connection. Also remember that doing things with backup tool cpbackup, it relies on your system load so it can constantly pause for a while when it's waiting for load to go down, pain in the ass, didn't have that issue with pkgacct but it also can be tweaked in WHM > Tweak
 
  • Like
Reactions: bitpt

bitpt

Active Member
Sep 28, 2006
43
4
158
I already migrate all dbs and is working fine.
If you want find what happened for this stream migration fail, thats ok, but pls don't migrate again, server already working after dumping dbs.

Can you send ticket link or submit a normal ticket?
 
Last edited: