Wednesday, July 17, 2013

Recover Partition Table using Test Disk

Recover Partition Table using Test Disk


TestDisk is powerful free data recovery software! It was primarily designed to help recover lost partitions and/or make non-booting disks bootable again when these symptoms are caused by faulty software, certain types of viruses or human error (such as accidentally deleting a Partition Table). Partition table recovery using TestDisk is really easy.
Src: http://www.cgsecurity.org/wiki/TestDisk

TestDisk can be installed in any OS. If your partition table is corrupted entirely, probably you will be unable to get into an OS to use Test Disk. For such an issue, we can make use of GParted Live Disc which has Test Disk Integrated in it. GParted is available as a bootable ISO
1.GParted Bootable ISO  download
2. Download the Bootable ISO and burn it in a CD.
This image can also be made to be booted from a USB or through PXE. Please refer the following links for it.
Live on USB http://gparted.sourceforge.net/liveusb.php
Live from PXE http://gparted.sourceforge.net/livepxe.php

3.
STEP 1:
Place the bootable disc in the disc tray and make changes in the BIOS to boot the system from the CD.
Select the default settings and press Enter.
Note: If you are unsuccessful in booting with the default settings , then select the second option “Other modes of Gparted Live” . This will bring another set of menu, select ” GParted Live ( Failsafe mode ) ” .
Gnome Partition Editor


Go with the default option, don't touch keymap and press Enter.
Gnome Partition Editor
Select whichever language is appropriate for you.
Go with the default. Just press enter


STEP 2:
Double click the terminal. ( Third Icon from the left )


STEP 3:
This is done , just to ensure that your partition table is corrupt. 
Type the following commands
$ sudo 
#fdisk -l


STEP 4:
Now open the testdisk with the following command
# testdisk
STEP 5:
This will open up the Test Disk Utility. Just press enter and proceed.
STEP 6:
Select the appropriate Hard Disk from which you want to recover the partition table. Here,going to recover the partition table from my Virtual Hard disk created using VMware. This is nothing much different from the physical Hard Disk. selected the appropriate hard disk , select and proceed at the bottom .


STEP 7:
Select the appropriate Partition type. Mostly its Intel. Select and then press Enter to proceed.


STEP 8:
Now select Analyse and then press enter to proceed. 
The quick search option is selected by default. Just press enter to proceed.


STEP 9:
Press yes to proceed.

 Now your partition would have been recovered. Just check if its correct. If you are sure its the correct structure, just pressenter  to proceed.



STEP 10:
Select write and enter to proceed.
Press enter to confirm the write.


STEP 11:
Press enter to proceed.
Select ok
            
Select quit
              


STEP 12:














USING  partition wizzard
Go here and get "partition wizzard" it is free for home use.  You can go ahead and install the free version or you can download and use the bootable CD, either one should work.
http://www.partitionwizard.com/free-partition-manager.html

They also have a little tutorial here but I will go ahead and give you a few tips.
http://www.partitionwizard.com/help/partition-recovery.html


Run the program and go to Wizzard > Partition Recovery Wizzard:
Pwiz1.JPG


Make sure you select the right disk on the next screen:

pwiz2.JPG


Do Quick scan
After it does the scan you will see a screen like this:
pwiz3.JPG


In my example here, it's only showing one possible configuration for the deleted partition.
You may end up with more than one, but don't select any boxes yet.  If your drive had a single partion on it, chances are the starting point of the correct configuration would be 63 or 2048.

If you click the line right where my pointer is you will be able to "browse" the drive using that partition alignment.
Don't check the box, just click the line where I am pointing to and you get a box like this:

pwiz4.JPG


Tuesday, July 16, 2013

HOSTCONSH in BIG-IP



  HOSTCONSH in BIG-IP
 Escape-shift-9, hold down escape, hold down shift, then press 9, you will get this menu on the serial console:
escape-shift-nine

Sunday, July 7, 2013

ERROR: Loading command: list (LoadError) | no such file to load -- zlib | ERROR: While executing gem ... (NameError) | uninitialized constant Gem::Commands::ListCommand



======================================================= 
gem list
ERROR:  Loading command: list (LoadError)
    no such file to load -- zlib
ERROR:  While executing gem ... (NameError)
    uninitialized constant Gem::Commands::ListCommand

=======================================================
 
=============================== 
sudo apt-get install zlib1g-dev
cd /ruby-source-files/ext/zlib
ruby extconf.rb
make
sudo make install  
===============================