Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium


mysql replication

Posted on 2014-08-29
Medium Priority
Last Modified: 2014-08-29
Hi, it's been about 5+ years since I setup a master/slave mysql setup and have a few question.

1. The primary mysql server is running version 4. This is our production server. It's 4 because of old PHP code. Work won't let me spend the time to convert so it's 4 until their is a major problem.

2. I setup a new mysql server to run some off production reports, etc. However, I have to manually dump the data from the mysql 4 server then import into the mysql 5 server.

What is the best way to replicate mysql 4 database to a mysql 5 database. I want to automate this task maybe once per week.
Question by:Robert Saylor
  • 3

Accepted Solution

rjohnsonjr earned 1000 total points
ID: 40293176
If you are going to do it once a week.  I would say use mysqldump to dump from the old one and import into the new one.

Author Comment

by:Robert Saylor
ID: 40293225
I was looking for more of an mysql way. With that I would write a shell script to dump the DB, scp it, then import. This I already do was wondering of mysql replication would work and if I can set a time on it.
LVL 36

Assisted Solution

gr8gonzo earned 1000 total points
ID: 40293305
What specific versions are you using?

MySQL replication is real-time. It's not a recurring task. In most cases, you can replicate from an older master to a newer slave, but some versions may have problems. Check this article:


If I were in your spot, I'd search around security blogs for problems with your current MySQL version to get some justification to move up to version 5. Sometimes the business logic of a company doesn't really see the importance of staying up to date, or the future problems with developing against older versions. But they will often pay attention to the possibilities of security breaches.

Author Comment

by:Robert Saylor
ID: 40293324
Old server is 4.1.22-standard-log, new server is 5.1.73 Source distribution.

Yea I did some research and looks like mysql only supports going 1 level up. I think the 5.1.73 is a little more then 1 level. I am writting a shell script to do it with mysqldump now.

Author Closing Comment

by:Robert Saylor
ID: 40293333
mysqldump ultimately is the solution but the link on oracle confirmed the way I wanted to do it would not work.

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

By, Vadim Tkachenko. In this article we’ll look at ClickHouse on its one year anniversary.
Backups and Disaster RecoveryIn this post, we’ll look at strategies for backups and disaster recovery.
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
Suggested Courses
Course of the Month13 days, 15 hours left to enroll

580 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question