travis' brain dump

on the list of things not to do on a weekend…

by on Aug.12, 2008, under Tech Stuff

accidently delete your entire photo gallery instead of individual albums photos.

Indeed… I became one of those morons I rant about in the tech world on a daily basis. yay for me! I seriously forgot my helmet. Backups? lol yeah funny thing about those… so lets tell the story. πŸ™‚

You see my server, being FreeBSD and having no real money for a good solid backup solution for such an operating system did what any good admin would do. at least make regular tarballs, gzip them and ship them offsite. While this does suffice as a good backup strategy for the most part, it does not however save even myself from a failure spot. So Sunday, I was doing some cleanup and wiped out my backups from over a month ago. Keep in mind a month ago is when I installed NextGen Gallery for my wordpress blogsite software and decided to discontinue use of my previous Gallery for personal reasons. (security mainly) When I did so, I also changed my backup selections to include the new paths for the new gallery and left off the old gallery since I fully intended on porting over my gallery as quickly as possible. (can you smell the failure here?) so, Sunday I go about maintenance and cleared out all my old backups from over a month ago not even thinking for a second that later in the day I would need them.

I logged into my old gallery sometime in the afternoon and decided to clean out the albumsΒ I had already ported to get a better view of what I still needed to port. Instead of deleted selected galleries,Β I deleted the entire thing. Before I had realized what I had done, it was …. GONE. Now when I say GONE, I mean it. Anyone who knows UFS2 file systems (freebsd) knows that there is no recycle bin unless you make one for yourself and script it, blah blah… when you delete a file, the pointer is wiped and the open space becomes territory for destructive over-write. πŸ˜‰

I’d say that 95% of my pictures I have a backup for already on my server at home, but it was those 5% that I didn’t have anymore (but do now) that sent me a feeling I never want again.

Did I panic? no. Did I lose control of my bodily functions? Almost. Did I find a new hero on the internet? YES.

Christophe Grenier at cgsecurity.org, you are my new hero. LOL

He’s got a handy little tool out there called photorec which I have to say is probably the biggest life saver should you ever shoot yourself in the foot. It scours the entire drive for whatever you wiped out from top to bottom and leaves no stone (or block) unturned. 6 hours of running on the /home partition (it’s pretty darn big) and it recovered every one of my lost photos. (as well as everyone elses… BAD BAD BAD ARTIFICIAL!!)

Moral of the story? Make sure you have a good recent backup before you click delete on ANYTHING and don’t be a complete tard. IT people will laugh at you as I laugh even at myself. πŸ™‚


8 Comments for this entry

Leave a Reply

You must be logged in to post a comment.

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!