Now that WordPress 3.0 RC3 (third release candidate) is out, it can only mean that WordPress 3.0 is just around the corner. The final version could be any day now, so now is the time to start getting ready. Thinking about doing the update to 3? Awesome. It should be painless for you, but … this doesn’t mean that you shouldn’t plan ahead. You need to back up your WordPress database.
If you don’t have your WP database backed up on a regular basis, now is the time to start. The easiest thing to do is to install WP-DBManager. Doesn’t matter if you install it through WordPress or manually, the key is to install it and activate it.
Once WP-DBManger is active, look for the new “Database” button and click the options link. (Yes, I know there is a big red box at the top of the screen saying your database backups might be at risk; we’ll get to that in a moment.)
Most of the time the settings at the top are going to be just fine, so what you’ll want to do is scroll down and set how often to back up and how often to optimize.
I have my database set to backup every day, but I left the email box blank so I’m not emailed a copy. If you want extra security, have a copy sent to your gmail account. Remember after a while you’ll want to clean things up and delete old copies of your database.
I have my database set to optimize every 7 days, I think the default is 3 which seems extreme to me.
Click Save Changes, then click “Backup DB”.
Now you’ll make a backup of your database, just to have an extra bonus one (or if you want to update WordPress right then). On the screen, just click “Backup” and wait until its done. I like to gzip (compress) my database because uncompressed it’s about 40 megs.
Now for the error.
There is a file called htaccess.txt in the plugin’s folder (wp-content/plugins/wp-dbmanager) and you just have to copy it to wp-content/backup-db/ then rename it to .htaccess. You can do this a couple of ways via FTP. First is if your FTP client is like mine (Transmit from Panic) you can drag htaccess.txt to the right place then rename it. If your FTP client can’t do that, then download a copy of the plugin from WordPress.org (the link is above), unzip it, then upload htaccess.txt from your computer to the right place on the server.
Don’t forget, you have to rename the file to .htaccess for the error to go away (and the protection to actually work). For most FTP clients, you can easily do this by right-clicking (command-click on the Mac of course) and from the contextual menu selecting “Rename”.
You might wonder about the rest of the important stuff in wp-content (themes, uploads, etc), well if you’re like me that’s getting to be a pretty hefty download. I have yet to find a reliable way for those files to get backed up, beyond what DreamHost does automatically. If someone has a simple and easy way to backup your wp-content directory, I’m all ear.
Yes, I do SSH up to the server, zip a copy, and download it. However, not every one can SSH up to there server to download the files. And the web-based file managers sometimes have issues compressing large numbers of file.
So when WP 3.0 drop (any time now!), remember have your database backed up first. Then go ahead and update.