Topic on Project:Support desk

Is this a valid way to wipe and restore my entire wiki?

3
RedKnight7 (talkcontribs)

Hi, I have a tiny personal wiki that only I can edit. Yesterday I invited somebody else to edit it; that worked fine. But I made the mistake of leaving Account Creation on overnight and got over a hundred new spam accounts and pages (details here).

Fortunately, I archived my whole wiki just prior to turning on Account Creation. Rather than dealing with all the new bogus users and pages (and clutter in my logs and histories for an otherwise very clean site), I'm considering just restoring from the archive. And then use copies of the few changes that that one guest editor did, for them to apply again.

Could some kindly expert here tell me if these steps will work?

I have been bit many times by simple-looking operations actually going way south and taking days to recover from. This one sounds like it's asking for it!

My host provider is SiteGround. I used their Site Tools and its File Manager to make a .zip of my wiki, specifically, the public_html, logs, and webstats folders. (Not anything else at a "higher" level!) It's an 820 MB zip; my site is pretty small.

IF this is easy, I imagine I only need to:

  1. First, make a copy of the four pages that the one legit editor worked on. The entire contents of them.
  2. Delete the three folders (public_html, logs, and webstat).
  3. Unzip my mediawiki archive to the same place (root wiki.[my site]).

In theory this should restore it to as it was before, right? Nothing else needed? No "sync" problems somehow? (Though I might need to clear all my PC's browser cookies for my site.)

Then for the legit user who only edited four pages:

  1. Work with them to have Account Creation open for a brief period, and let them make an account. Then turn it back off again.
  2. Let them (the new user) replace the four pages with the backups I made.

Since I got copies of the four pages, if they replace the entire page, then all changes will show up as edits they made, right? One of the four pages was their User page (completely new), but the other three were edits here and there on existing pages.

The only thing I can think of that will be lost with this approach is that instead of all their individual edits showing up as they did them the day (yesterday), they'd all now show up as one big edit by them for each page, as of the time they copy in the backup of each page (the one that included their edits from yesterday). We can live with that. Fortunately, they're pretty understanding.

Many thanks if you can help. Wow this is all so much more work than I ever thought. It never ceases to amaze me how much, lol.

Bawolff (talkcontribs)

Page contents are stored in the database. It is unclear if your archive includes that, but it sounds like it might not.


P.s. there is also a feature where if you go to special:createaccount when loggged in as admin,you can invite someone by email (assuming email enabled) without opening it to the world.

RedKnight7 (talkcontribs)

Hi, after researching the wiki database (and still feeling unsure), ultimately I just went with using my site host's Backup And Restore tool, which applies to the entire site. I hadn't thought of this at the time I wrote the OP above; I was hoping there might be a simple Yes to my question.

Fortunately it's a tiny wiki and there were only 5 pages that had been changed, so I just saved their source before backing up. Everything seems to have worked fine. I didn't even need to wipe the cookies and cache on my browser PC.

Also: Many thanks for mentioning Special:CreateAccount. I didn't know about it; it's easy to get lost in all the google results and MW Manual pages that list every possible option. By using it, I didn't even have to expose the Account Creation link.

I'm kind of shocked that spammers found it and started abusing my site within 15 minutes. The analytics for my site show a sudden spike in access from Latvia, haha

Reply to "Is this a valid way to wipe and restore my entire wiki?"