• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer

Tips and Tricks HQ

  • Home
  • Blog
  • Projects
    • All Projects
    • Simple WP Shopping Cart
    • WP Express Checkout Plugin
    • WP Download Monitor
    • WP Security and Firewall Plugin
    • WP eStore Plugin
    • WP Affiliate Platform
    • WP eMember
    • WP Lightbox Ultimate
    • WP Photo Seller
  • Products
    • All Products
    • Checkout
  • Support
    • Support Portal
    • Customer Only Forum
    • WP eStore Documentation
    • WP Affiliate Software Documentation
    • WP eMember Documentation
  • Contact

What Would You Do If Somehow You Lost all Your Blog’s Content?

You are here: Home / Tech Tips / What Would You Do If Somehow You Lost all Your Blog’s Content?

Last updated: May 3, 2013





I hope this doesn’t happen to anyone else but this morning  my blog Tips and Tricks HQ somehow disappeared from the face of this earth! The day started as usual… I woke up in the morning went to my office and started checking my emails and found out that I received an email from  SiteUpTime (SiteUptime is a website monitoring service that checks your website at regular intervals and notifies you via email or SMS if it becomes unavailable) telling me that my site is down.

natural-disaster_128

So naturally I wanted to check if the site is up now. When I entered the site address in the address bar I got the following screen!

WordPress Blog Setup Screen
WordPress Blog Setup Screen

You can probably imagine that at this point I was pretty scared! I always backup my database and WordPress files regularly so I wasn’t completely in the water but what about all the articles that I have posted after the last backup? Not to mention the traffic that I am loosing now!



Anyway, in my case the damage wasn’t that severe. One of my WordPress database tables ‘wp_options’ was marked as crashed and I was getting the following error that I recovered from the ‘error_log’.

[25-Feb-2009 21:03:32] WordPress database error Table ‘wp_options’ is marked as crashed and should be repaired

I opened a ticked with my web hosting company to address this issue.

Contingency Plan to Recover My Blog Content

After opening the ticket, I started preparing myself for the worst case scenario. So in my mind I was going over the contingency plan to recover my blog content. This is what I planned:

  • Restore the Database with the last db backup file.
  • FTP all the WordPress files (last backed up) to the server.
  • Use Google cache to recover the last few articles that I posted after the last DB backup.

If you didn’t know already… Google, Yahoo, MSN search sites cache the content of each page of your site. So you can recover your blog’s content from the search site’s cache. Google is likely to have the most recent content of a blog already indexed and cached. So I checked out Google to see if it has cached my ‘WordPress PayPal Shopping Cart Plugin’ post which I posted after the last database backup. I was a little happy to find out that Google had my post cached.

Recovering Blog Content from Google Cache
Recovering Blog Content from Google Cache

Yahoo also had the post cached:

Recovering Blog Content from Yahoo Cache
Recovering Blog Content from Yahoo Cache

Luckily, as I mentioned earlier that my case wasn’t that severe,  my web hosting company repaired the database using the cPanel – Databases – Repair DB function.

How to Restore Your Blog’s Content (Disaster Recovery)

There are quite a few methods to recover a blog’s content in case of a disaster.

Option 1: Using PhpMyAdmin

Use PhpMyAdmin to backup the WordPress database regularly and restore it when you need.

  • How to backup your WordPress database using phpMyAdmin
  • How to restore your WordPress database using phpMyAdmin

Option 2: Use the Export and Import  Tools in WordPress 2.7 and above

In order to export all your blog’s posts, pages, comments, categories etc in an XML file do the following:

  • Go to “Tools” -> “Export”
  • Click on “Download export file”.

The resulting XML file contains your posts, pages, comments, custom fields, categories, and tags.

To restore your blog’s content:

  • Go to “Tools” -> “Import”
  • Choose “WordPress” from the list
  • Browse for the previously saved XML file and hit “Upload file and import”

This will import the content.

Option 3: Use the Cache from the Search Sites

If you have never done any backup of your blog and woke up one morning to find out that your blog has been wiped out from the face of this earth then this option is probably your best bet. Search with the option “Site:your-domain-name.com” in the Google search to get all the indexed pages from your blog to show up in Google search result:

Restoring Blog content from Google Cache
Restoring Blog content from Google Cache

Now you can go through each cached page and copy the content over. This manual approach however is not very realistic for any blog with a lot of posts. I would recommend using a script to automate this process.

  • How to restore a site’s content from Google’s cache using a Python script
  • How to restore your WordPress database from Google Cache through Ruby

Hope this helps some of you sleep better at night knowing that your blog content is recoverable 🙂 Please feel free to leave any suggestion in the comment area below.

Related Posts

  • How to import WordPress SQL database backup file without having ‘create new database’ privileges in phpMyAdmin
  • How to Install WordPress on Your Domain
  • Top 15 Search Engine Optimization (SEO) Techniques I Forget to Do
  • How to Separate Pingbacks and Trackbacks from Comments

Tech Tips,  Wordpress Blog Setup,  Disaster Recovery,  Security,  Troubleshooting,  Web Development,  web masters,  Wordpress,  wordpress security

Reader Interactions

Comments (15 responses)

  1. Nil says:
    October 13, 2012 at 8:24 am

    Thank you so much for sharing this on your blog. Just lost all my content all of a sudden, then I followed your instructions and got all my content back, in less than 10 mins. 🙂 Really thankful that I searched on Google and that directed me to this post, bless you a hundred fold! 🙂 Can’t thank you enough! 🙂

  2. Cosmo says:
    May 31, 2012 at 2:33 pm

    I know this an old thread, but there is a much quicker way to repair the database. Log into phpMyAdmin, select the database and you should see a list of tables in the database, select the box next to wp-options, and choose “Repair” in the dropdown at the bottom of the list. Job done, no loss of data.

  3. Edwin Crozier says:
    March 30, 2011 at 7:58 am

    Thanks for this tip. I’ve been blogging for a while now and this post just shows how little I know. I’ve never even thought about what would happen if I lost it all. I didn’t realize it could happen.

    I just finished backing everything up and I’m going to bookmark this page as a reminder if I lose everything on how to get the stuff not in the back up yet.

    Thanks.

  4. One24 says:
    March 26, 2011 at 3:25 pm

    If I lost all my blog content I would shoot somebody… Especially if it was one of my sites that is racking in the dough.

  5. Jason says:
    January 17, 2011 at 7:07 pm

    I agree with John…the product called “BackupBuddy” is awesome. It archives your whole blog or it will allow you to make a template for making new blogs.

  6. One24 says:
    January 17, 2011 at 6:57 pm

    Crazy, I never thought about that. I guess I have always figured that my hosting company had my back, however after seeing what you went through I am thinking I need to be more diligent in backing up.

  7. John Gamings says:
    January 3, 2011 at 11:26 am

    Personally I use a plugin called “BackupBuddy” and it is AMAZING. it makes an exact same replica of a site within 30 seconds, which makes setting up multiple sites a breeze. Definitely a must-have plugin in my opinion

  8. taylor lautner says:
    October 19, 2010 at 1:38 pm

    It was a good lesson for you but we sometimes get lessons from such incidents. Even i have a very bad habit of not taking backups. Even my home PC was crashed multiple times and i lost some of my data. It is very important to have backup of your important files somewhere. I think you are lucky in your case it was not a severe issue but many times especially if there is any virus problem, it gets impossible to restore the data and you have to accept the loss. Google Cache is good only to restore content but in case of codings, it won’t help.

  9. sandesh says:
    September 23, 2010 at 4:32 pm

    It is very important to backup all your blog content in this scenario

  10. lcdhdtv says:
    September 17, 2010 at 5:25 pm

    Wow, this post simultaneously enlightened me and scared me straight! I’m never going without backups again! The python script for capturing google cache is on some james bond stuff!

  11. Michiel says:
    February 8, 2010 at 4:17 pm

    Hi Amin, thanks for the great post! I had some problems on the installation too recently, might be a database error as well.

  12. Spitt says:
    January 30, 2010 at 8:04 pm

    My host keeps a backup from the day before, for files. And each day, I am emailed the database. I might lose one day but it would be all comments, since I keep 2 weeks worth of posts in the queue.

    http://www.ilfilosofo.com/blog/wp-db-backup

  13. admin says:
    March 19, 2009 at 4:44 pm

    I am glad is was of some help to you Nina. The Pleasure is all mine 🙂

  14. Nina says:
    March 19, 2009 at 2:47 pm

    Thank you, Thank you! This is wonderful information to have and to use. I printed this page, so I will be prepared. Your blog is amazing! I am grateful that your so generous with your tech expertise and skills.

  15. Darren (Green Change) says:
    February 26, 2009 at 5:44 pm

    Wow, it pays to be prepared!

    Thanks for the tip on using Google Cache to retrieve the last few articles that might be missing from your weekly backups. I hadn’t thought of doing that!

Leave a Reply

Your email address will not be published. Required fields are marked *

Primary Sidebar

Featured & Popular Articles

Video Answers to Top WordPress QuestionsWordPress Optimization Tips and Tricks for Better Performance and SpeedEssential WordPress Security Tips - Is Your Blog Protected?WordPress Simple PayPal Shopping Cart PluginTop 15 Search Engine Optimization (SEO) Techniques I Forget to DoList of the Best and Must Use WordPress PluginsHow do I Start a Blog and Make Money Online?Good Domain Name Picking Tips for Your Blog SetupFind Out Which WordPress Web Hosting Company Offers the Cheapest and Reliable Web Hosting Solution

Featured WordPress Plugins

wordpress estore plugin
wordpress membership plugin
WP Express Checkout Plugin
WordPress Lightbox Ultimate Plugin
WordPress photo seller plugin
wordpress affiliate plugin

Recent Posts

  • Accept Donations via PayPal from Your WordPress Site Easil [...]
  • Buy Now Button Graphics for eCommerce Websites [...]
  • Subscription Button Graphics for eCommerce Websites [...]
  • Adding PayPal Payment Buttons to Your WordPress Sidebar Ea [...]
  • PayPal QR Codes [...]

Comment & Socialize

  • @Rodrigo Souza, Thank you f ...
    - admin
  • The example for 'slm_add_ed ...
    - Rodrigo Souza
  • @Ron, All the valid transac ...
    - admin
  • Hello, when people have sel ...
    - Ron
  • We have hte following featu ...
    - admin

Check out our solutions

View our WordPress plugin collection and start using them on your site.

Our WordPress Solutions

Footer

Company

  • About
  • Privacy Policy
  • Terms and Conditions
  • Affiliate Login

Top WordPress Plugins

  • Simple Shopping Cart
  • PayPal Donations
  • WP Express Checkout
  • WP eStore
  • WP eMember

Blogging Tips

  • How to Start a Blog
  • Selecting a Good Domain
  • Cheap WP Hosting
  • WP Video Tutorials
  • Simple SEO Tips

Search


Keep In Touch

Copyright © 2023 | Tips and Tricks HQ