Closed
Bug 521422
Opened 16 years ago
Closed 16 years ago
Synchronize stage database with production.
Categories
(quality.mozilla.org :: Website, defect)
Tracking
(Not tracked)
RESOLVED
INVALID
People
(Reporter: paul, Unassigned)
References
()
Details
Hello,
Can we copy over the production database over to our stage server?
Best, Paul
Comment 1•16 years ago
|
||
(In reply to comment #0)
> Hello,
>
> Can we copy over the production database over to our stage server?
>
> Best, Paul
you mean the qmo stage server right ?
| Reporter | ||
Comment 2•16 years ago
|
||
Hi Carsten
That's correct.
Is it also possible to pull the latest QMO code out of SVN somewhere and download a sanitized version of the database for development on my local server ?
Best, Paul
Comment 3•16 years ago
|
||
From Aakash's email: "Tomcat's commented that since there's data on both staging and production, that it might be better to not go this route."
My opinion is that staging should be as similar to production as possible. I am unaware of any reason we shouldn't sync. Is anyone?
Thus, my suggestion is to do the following:
1) Get a dump of prod db. Sanitize it as such:
* remove all the emails or set them to the qa mailing list (users table). E.g:
UPDATE users SET mail = 'qa@mozilla.org';
* set all the passwords to something easy to remember. E.g:
UPDATE users SET pass = MD5('password');
* truncate all tables that have the word "cache" in them. E.g:
SELECT table_name FROM INFORMATION_SCHEMA.TABLES WHERE table_schema = 'qmo_db_name' AND table_name LIKE '%cache%';
And then truncate all of those.
Feel free to write a script to do this :)
I have a sanitized dump that I sent to Mark a while back, but it's from a dump over 6 months old.
2) Transfer this above sanitized db to stage, and also make a sanitized copy available to Paul Booker and Jamey.
If you have a khan account, you can find an old dump to practice on in my local folder:
/home/pcraciunoiu/quality_mozilla_org.*
I would love to see a script for this, and I'm sure you can work with Alex Buchanan to make it work for SFx (or maybe he already has a script). Alex, don't hesitate to add to the above if I missed anything.
I sent a clean dump to Tomcat, Aakash, Jamey and Paul B just now.
When the script is ready, you probably have to turn this bug over to IT to set up a daily cron or something of the sort.
Comment 4•16 years ago
|
||
Spread Firefox stage has something along these lines set up.
It started in bug 434548
A flag file in SVN is used to trigger the DB update script. e.g.
http://viewvc.svn.mozilla.org/vc/projects/spreadfirefox.com/trunk/db-update/
For SFx, we don't find the need to keep the stage DB constantly up to date, but it is certainly useful to have an easy switch to flip.
This includes a script to sanitize the DB and do a few other tasks,
http://svn.mozilla.org/projects/spreadfirefox.com/trunk/clean_db.php
A lot of that script should work for QMO too, but some is SFx specific, also there may be private data not covered by that script.
There is also some more info here,
https://wiki.mozilla.org/Spreadfirefox#Spreadfirefox.stage
Comment 5•16 years ago
|
||
This bug is being moved to a resolved state of invalid due to one of the following reasons:
- we're moving to wordpress and so all drupal cruft is not going to be fixed
- the feature is not supported on the new qmo, at least for this release.
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → INVALID
Comment 6•16 years ago
|
||
This bug is being moved to a resolved state of invalid due to one of the following reasons:
- we're moving to wordpress and so all drupal cruft is not going to be fixed
- the feature is not supported on the new qmo, at least for this release.
You need to log in
before you can comment on or make changes to this bug.
Description
•