As part of my attempt to devise a store update methodology, with minimal disruption to the live store, I would like to duplicate my Zen Cart directory (currently 'shop') along with its associated database.
Since I am able to SSH into my web host and work from the command line, my first thought was to simply use 'cp':
But then I realized that if I do only that, the newly created Zen Cart store (testshop) will be using the same MySQL database as the original shop.[FONT="Courier New"]~/public_html> cp -R shop testshop[/FONT]
Which means that any changes to the database made in one store, will be automatically reflected in the other. This defeats the purpose of my duplicated testshop since I want to use it to test new products, while the real live store is operational and running, without customers being exposed to this.
So, it seems that I need to duplicate not only the Zen Cart directory, but the associated MySQL database as well. I searched the subject and found two excellent articles:
I have installed Zen Cart to a directory. How do I rename or move that directory?
Is it possible to create/build a complete Zen-Cart setup on a test server and then install on a live server?
But while they provide very helpful hints that what I want to accomplish is possible (and some cues about key files that need to be modified properly), they assume the same database name.
My question now is: How do I duplicate Zen Cart's database (with a different name of course)?
I know that my question may be a pure MySQL issue rather than a Zen Cart one, but aside from needing to check for any Zen Cart related "side effects", I am hoping that the answer given here may be helpful to other Zen Cart users who (re)search for an optimal "live update" strategy.
Thanks,
Daniel



When I first started this project, I knew nothing about web technology (and much less about PHP/MySQL ...). I hope that by the time I am done, I will be able clone a zenshop in 111 minutes.

