Question: Is there a way to test for correctness once the SQL DB copy has been installed on the local machine so I can confidently move to step number 3? Is there any information on the web that would help with the below goals? Are the below goals even possible or a good idea?Info:I would like to set up a VM server on my local computer which will serve pages in the exact same way as my current hosting(but only to me on my local computer). I currently pay a big web hosting company to host my website & web store and they are doing a great job, but I would like to be able to work on my Web store and its corresponding MySQL database without being at risk of messing something completely up on the live servers.My current plan of action:Set up a VM with debian server, MySQL, PHP, Apache(or something else)Copy my current MySQL databases from my hosting provider and install on VM server.Copy web store (PHP/HTML) code to VM server.Modify and test new features on VM server.upload MySQL DB and HTML/PHP code back to web host's server where it should work as before but with new modifications.Now I'm pretty sure I have step one down correctly but I can't for the life of me figure out where to began for steps 2 and 3. I've looked online for resources about how to make a 1 to 1 copy and install the database on a different machine but none of the information seems to be working or correct for my SQL DB (MySQL).
Setting up a VM testing server [MySQL, HTML, & PHP webstore] Testing for SQL correctness?
web development;server;mysql;webserver;testing
This is exactly what I do all the time. There is a full LAMP stack installed locally on my home machine. The hosting provider also uses LAMP and between cPanel and the output of php_info(), I know which software versions to match both configurations.All you need is to make sure the files (PHP/HTML/CSS/JPEG/PNG/etc) are the same which you can do with rsync (or an FTP GUI client with synchronization feature) and to transfer the database. Doing the DB transfer is fairly easy. If you have access to the command-line you use a MySQL prompt to export the database on the hosting server and you import it locally.Without the command-line you can do the export/import using a tool like phpMyAdmin. Just make sure that the export is done with the DROP option enabled so that everything gets overridden later when you import. For import, you need to make sure your PHP file upload limit is large enough to allow your DB to be transferred. The default is fine for small DBs but with a large site it needs to be boosted.