Question: Setting Up MySQL & Master/Slave with DreamCompute

dreamcompute

#1

Greetings,

I’m trying to learn how to set up MySQL and do testing with Master/Slave concepts on DreamCompute.

Noob Question 1:
I have 1 instance called “Home” which is where my first server is (Ubuntu, Apache, MySQL) is set up on. The book tells me to set up another VM for a slave MySQL server. Does this mean set up another “instance” on DreamCompute, install Ubuntu, Apache, PHP, MySQL all over again? Or is there something within my “Home” instance that does this?

Question 2:
My current production Dreamhost VPS has all my Apache stuff, websites, photos/images, etc. I also have Dreamhost MySQL VPS where I have multi-GB databases set up for all of my websites. Are these both on my server, or are they two separate servers?

If I switch to DreamCompute, would the best practice be to start up 2 separate instances: 1 to run Apache, websites, photos, etc, and 1 to run a separate MySQL database? and a 3rd instance for a slave MySQL database (I’m currently using about 1GB RAM for VPS and 500MB for MySQL VPS - MySQL usage is not small)? If I set up separate instances for MySQL, does that mean installing the same exact Ubuntu, Apache, PHP, MySQL and everything consistently on all instances?

Thanks
Kind regards


#2

You need to have a separate server running MySQL and setup that server as slave. You don’t need Apache and PHP.

If you have a MySQL VPS then they’re two separate (virtual) servers. You can check your panel to make sure: you’ll see more than one machine there.

[quote=“peppy, post:1, topic:65247”]
If I switch to DreamCompute, would the best practice be to start up 2 separate instances: 1 to run Apache, websites, photos, etc, and 1 to run a separate MySQL database? and a 3rd instance for a slave MySQL database[/quote]

Not necessarily: you have more complexity to manage two machines instead of one, and the advantages may not be visible. There are many ways to deploy WordPress for a high-volume site and the optimal choice largely depends on your actual needs. Maybe you want to learn how to do MySQL master/slave first before going deeper into multi-tier WordPress?


#3

Greetings,

Thanks for the response. Yes, it looks like I have two separate machines based on my VPS control panel. (I just realized my MySQL is using 700MB of RAM, not 500MB.)

I do not have a high-volume Wordpress site, just a couple of tiny blogs that use Wordpress with about 100 visitors per day in traffic, so I almost never use Wordpress. I don’t use Master/Slave setup either, this is just for learning purposes as some day one of my sites may need it. However, my high-volume sites are custom-built, database-driven sites. My VPS has about 60 websites and my MySQL VPS has about 20 databases (1 for each website that uses MySQL).

With DreamCompute, I’m not sure if combining the two (VPS + MySQL VPS) into one instance would slow the sites/server down to noticeable levels or not? Based on your experience and experience of others, would you then recommend having two separate instances (2 vcpus), one for VPS and the other for MySQL, or do you think one instance and vcpu has enough power to handle all of it?

Thanks
Kind regards


#4

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.