how to restore deleted files in Linux

Asslamo 3likom all

many times we delete files in Linux then discover that it was deleted by mistake and hope to find anyway to restore it again . well it is not 2 easy 2 do but anyway u can know the best solutions then  try ….

the problem here is to have the inode number of the file deleted no more . ok this is usually hard but … many times u will find that u have just 3 or 4 inodes for deleted files so 4 sure ur deleted file will be 1 of them  .

Linux provides many tools that can help view , modify , maintain and tune whatever you want in your FS characterstictics . like

dumpe2fs  is used just to display info a bout ur FS .

tune2fs  used to change some characteristics of it .

debugfs is a v powerful tool used to dir and modify it .

now simply switch user to root

then

debugfs /dev/….    and write the device / partition u want to restore files at

it will give u a prompt as “debugfs:  ”

then write lsdel or list_deleted_inodes

it will print all deleted files’ inodes

now write

undelete inode-nuber  name

and give it the name u want .

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s