Try to restore some content to MDC from before backing out the 9.12 upgrade

RESOLVED FIXED

Status

developer.mozilla.org
User management
RESOLVED FIXED
8 years ago
6 years ago

People

(Reporter: sheppy, Assigned: sheppy)

Tracking

Details

Attachments

(1 attachment)

(Assignee)

Description

8 years ago
A lot of Mozmill documentation was apparently heavily edited during the 24 hours or so between upgrading to 9.12 and backing out. Can we restore from the backup done before rolling back just the articles in the https://developer.mozilla.org/en/Mozmill/ subtree?

I have no idea how hard the sql work to do this would be, but the request has been made by the writer(s).
The writer was myself. So if you can also search for edits from 'whimboo' it should work better I believe. Thanks.

Comment 2

8 years ago
Maybe mindtouch can write a script that takes stuff from that db and imports it in to our production DB.
Does it mean IT cannot step in here and we have to rely on code from Mindtouch? If that's the case, can you please get in contact with them, Sheppy?

Comment 4

8 years ago
That's exactly what it means.  It's compiled c# code for which we do not have the source (nor c# expertise).
(Assignee)

Comment 5

8 years ago
I'm not sure why code is needed to pull some stuff out of the database. That said, I'll try asking MindTouch about this, but I don't expect them to jump up and offer to write us code to do this.

Comment 6

8 years ago
Because they don't like money?  Don't we pay them?
(Assignee)

Comment 7

8 years ago
Well, we're currently out of contract with them because we refused to pay for another year until they fix all the stuff we paid them for last year.

I had rather assumed we could just pull up the data using mysql queries. If I can just get the XHTML from the database, I can paste it into the appropriate articles. That's why I was surprised by the request to get a tool written. I was under the impression this is just a handful of articles, so it would seem to me it would take less time to just pull the stuff from the backup by hand.

That said, I've posed the question about a tool; waiting on a reply.
(Assignee)

Comment 8

8 years ago
Response about the tool from MindTouch is basically what I said; they're not sure the time needed to write a tool to do something that involves a simple sql query to pull out the XHTML content from the database for the desired range of timestamps is worth the time or money investment for anyone.

select page_content,page_title where <date specification here>

Then send me that output, and I can copy and paste it into the articles.

Updated

8 years ago
Assignee: server-ops → mrz

Comment 9

8 years ago
(In reply to comment #8)
> Response about the tool from MindTouch is basically what I said; they're not
> sure the time needed to write a tool to do something that involves a simple sql
> query to pull out the XHTML content from the database for the desired range of
> timestamps is worth the time or money investment for anyone.
> 
> select page_content,page_title where <date specification here>
> 
> Then send me that output, and I can copy and paste it into the articles.

There are no related tables that also need updating?  If I can just copy directly from one table all I need to know is, which table?

"select page_content,page_title where <date specification here>" <- What is the exact query I need to run?
hmm, I missed this bug, but the schema's based on mediawiki so it should be easy to figure out.  I made that backup with the intention of having it available for something like this if needed.  The pre-rollback backup is in tm-backup01:/data/backups/oneoffs/, it'll need to be restored somewhere to pull stuff out of it.
Given the comment from Dave, who can work on this?

Updated

8 years ago
Assignee: mrz → tellis

Comment 12

8 years ago
tm-stage01-master01 (and -slave01) now have this database:

  mdc_restore_deleteafter_20100601

It has a copy of the backup restored into it.
Is there a staging site I could check if all the content I miss has been restored? Or does it mean you will start syncing the missing content now?

Comment 14

8 years ago
It's just a database. How would I sync the missing content? Reading this bug history, I don't think anyone knows how that would happen. Do we have a MindTouch contact who will help us with this?

Comment 15

8 years ago
Oops. I missed this comment.

(In reply to comment #8)
> select page_content,page_title where <date specification here>
> 
> Then send me that output, and I can copy and paste it into the articles.

Got it. I'm ready to do this. What is "date specification here"?
(Assignee)

Comment 16

8 years ago
I'm waiting for one of the MindTouch guys to log in for the day on their IRC channel, then I will get this information.
(Assignee)

Comment 17

8 years ago
should be

select page_content, page_title where page_timestamp>YYYYMMDDHHMMSS

Where YYYYMMDDHHMMSS is the timestamp corresponding to when we attempted the upgrade, in order to get all the pages changed since that time.

Comment 18

8 years ago
That part I knew.

I need to know when was "the 24 hours or so between upgrading to 9.12 and backing out"?
(Assignee)

Comment 19

8 years ago
I was afraid of that...

Try: 2010-04-13 16:50 PDT

That's about five minutes before oremj posted that the upgrade was complete.

Comment 20

8 years ago
Got it. Here's the exact query I ran:

mysql> select page_title,page_text from pages where page_timestamp >= '20100413165000' and page_timestamp <= '20100414165000' into outfile '/tmp/content-from-2010-04-13-1650-to-2010-04-14-1650.tsv';

I will attach the result. Note that the newlines are escaped in the content (\ at the EOL) so you probably gotta do a little text processing.

The general idea should be a given row is page_title<tab>page_text where a row in this case start with a line that doesn't end in a backslash.

Comment 21

8 years ago
Created attachment 445399 [details]
Content from 13 April 2010 for MDC.

Comment 22

8 years ago
Should have mentioned in comment #20, but I also sanity checked the timestamps in the database restore, and your timestamp is correct, give or take a minute. I failed to realise that I could have determined that info without asking. Sorry.

Updated

8 years ago
Status: NEW → RESOLVED
Last Resolved: 8 years ago
Resolution: --- → FIXED
(Assignee)

Comment 23

8 years ago
Not fixed yet, but now this is mine, to re-insert the content into the wiki. :)
Assignee: tellis → eshepherd
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
(In reply to comment #23)
> Not fixed yet, but now this is mine, to re-insert the content into the wiki. :)

Any update Sheppy? Meanwhile for some of the pages I had to do other updates so simply restoring the content isn't enough anymore. Any hope that old content can be restored? If yes, please give me a list of items under Mozmill and I can tell, which ones haven't been modified. Thanks.
Status: REOPENED → ASSIGNED

Updated

8 years ago
Component: Server Operations → Administration
Product: mozilla.org → Mozilla Developer Center
QA Contact: mrz → administration
Version: other → unspecified
I have updated all the content which has been lost during the failed upgrade. From my side everything is back. Thanks.
Status: ASSIGNED → RESOLVED
Last Resolved: 8 years ago6 years ago
Resolution: --- → FIXED
Component: Administration → User management
Product: Mozilla Developer Network → Mozilla Developer Network
You need to log in before you can comment on or make changes to this bug.