Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
06-28-2009, 09:58 AM
|
#1
|
LQ Guru
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: Slack14.2/Many
Posts: 5,573
|
Best way to simulate data loss, corruption, partition wiping, etc & then "rescue" it?
OK,
What I'm trying to do is learn how to "rescue" a system that has been corrupted, formatted, or data overwritten, etc. in Qemu
and then try to save it with partimage, testdisk, photorec, etc.
My idea was to use Qemu to create a whatever size qemu-img, partition it and install a few distro's to it, then somehow destroy stuff, wreck the partition table or whatever, and then try to use various tools to
Rescue the system, and I would be able to learn system rescue, etc
"hands-on", but in virtuality, so no harm done.
So, if that's not a good idea, then how would I practice with recovery tools, etc without risking my own systems?
thanks
|
|
|
06-28-2009, 01:15 PM
|
#2
|
Member
Registered: Dec 2007
Location: Charleston WV, USA
Distribution: Slackware 12.2, Arch Linux Amd64
Posts: 896
Rep:
|
Well, I like the idea.  As to how you "wreck" your filesystem, you can destroy your partition table by writting garbage to the MBR, for example.
dd if=/dev/urandom of=/dev/sda skip=446 bs=64 count=1
|
|
|
06-28-2009, 02:23 PM
|
#3
|
LQ Guru
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: Slack14.2/Many
Posts: 5,573
Original Poster
|
OK, I'm gonna try that
Now, what TYPES of corruption/damage can data recovery tools
really help with?
Like, if I dd'd the mbr, as in Uncle's post, that type of damage is easily fixed or no?
Does anyone know different ways of screwing up the OS, but still have the ability
to recover some/all?
like formatting
bad partitioning
what else?
|
|
|
06-28-2009, 02:35 PM
|
#4
|
LQ 5k Club
Registered: Jan 2006
Location: Oldham, Lancs, England
Distribution: Slackware64 15; SlackwareARM-current (aarch64); Debian 12
Posts: 8,311
Rep: 
|
I don't know the answers, but it does sound like an interesting experiment.
|
|
|
06-28-2009, 02:39 PM
|
#5
|
LQ Guru
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: Slack14.2/Many
Posts: 5,573
Original Poster
|
OK, well, I guess I'm gonna try different things, huh?
One question though, as I stated at first, Doing this in "virtual" land
will still be an almost exact recreation of a event happening in a real-time system-yes? Or no?
Quote:
My idea was to use Qemu to create a whatever size qemu-img, partition it and install a few distro's to it, then somehow destroy stuff, wreck the partition table or whatever, and then try to use various tools to Rescue the system, and I would be able to learn system rescue, etc
"hands-on", but in virtuality, so no harm done.
|
I can't really think of a better/safer way than doing it in an emulator
as otherwise I would have to use an old lappy, which is what will be used eventually, once I know what's what 
|
|
|
06-28-2009, 02:46 PM
|
#6
|
LQ 5k Club
Registered: Jan 2006
Location: Oldham, Lancs, England
Distribution: Slackware64 15; SlackwareARM-current (aarch64); Debian 12
Posts: 8,311
Rep: 
|
Mmm, I should think it would near enough the same as doing it to a "real" system. And with Qemu, you can create those qcow files, that allow you to leave your originals untouched. That's one advantage.
|
|
|
06-28-2009, 02:50 PM
|
#7
|
LQ Guru
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: Slack14.2/Many
Posts: 5,573
Original Poster
|
OK, so this is my plan so far...
create qemu-img, partition and install like 5 distro's(various)
thenn...somehow destroy the partition table...I think I did that once when Playing with CFDISK, I did a partition scheme, wrote it to disk, then, instead of re-booting, I re-arranged the partition table like 2 more times, then tried to format it.
At reboot it was all screwy!
But, that's just 1 way....how would I find out the different ways a system can be destroyed, but recoverable?
I guess I'm off to see Mr. Google, so I'll go get a stiff drink, some indian smoke and
burn down qemu!
|
|
|
06-28-2009, 02:59 PM
|
#8
|
LQ 5k Club
Registered: Jan 2006
Location: Oldham, Lancs, England
Distribution: Slackware64 15; SlackwareARM-current (aarch64); Debian 12
Posts: 8,311
Rep: 
|
Good luck. 
|
|
|
06-28-2009, 07:26 PM
|
#9
|
Member
Registered: Oct 2007
Location: Norway
Distribution: Slackware 14.1
Posts: 446
Rep:
|
At work today I thought about doing the exact same thing. That is.. scary :P
The reason is that I am (As most nerds) the free computer technician in the family/community. My dads colleague lost two harddrives in a thunderstorm, and as usual he didn't have any backup. I got called in to "rescue" them free of charge (As always. Got to buy the hardware I needed tho, so now I got a cool adapter for IDE (3.5" and 2.5") and sata with including powersupply  I got to keep the harddrives as well, but I don't trust them, so I don't know what to use them for. Except experimenting with rescuing data). The drives them selfs showed up and seemed to be alright, but the MBR was corrupt. Easy, I thought. Well, long story short, I couldn't fix it. And that was annoying. So basically now I have to learn how. 
Last edited by Dinithion; 06-29-2009 at 05:17 AM.
|
|
|
All times are GMT -5. The time now is 03:44 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|