Today (Saturday) We will make some minor tuning adjustments to MySQL.

You may experience 2 up to 10 seconds "glitch time" when we restart MySQL. We expect to make these adjustments around 1AM Eastern Daylight Saving Time (EDT) US.


Recover deleted files on Linux server


Login or Register to Reply

 
Thread Tools Search this Thread
# 8  
Quote:
Originally Posted by reminisce
Note: The directory was deleted with other use not root user.
That is irrelevant - dead is dead and deleted is deleted.

Quote:
Originally Posted by reminisce
In one of the youtube link ,the admin provided some steps to get back the lost files.


As first step, below command needs to be executed :
ps -aux | grep <filename>
As an output, I could find the file and process id .
That may help as long as the process is running: when a file is deleted the system routine unlink() is used, which deletes the inode (and thus every possibility to access the files data). As long as at least one process still has this file opened, though, the unlink() is postponed, so the process still can access the file even though "from outside" the file already ceases to exist.

This means, if you can somehow get "inside" the process in question and if you can bring the process to write the file (or, at least, its inode information) then you can use this to restore the file, otherwise it is lost.

You might have luck with trying TestDisk as long as you haven't done anything further on that filesystem. My suggestion is to unmount it as soon as possible (preferably: NOW!) because the longer it is in use the bigger the chance that data which are still there (but unaccessible right now) will be overwritten (=definitely and ultimately lost forever).

I hope this helps.

bakunin
# 9  
Quote:
Originally Posted by reminisce
This is the filesystem that is mounted on:
/dev/xvda2 on / type xfs (rw,relatime,seclabel,attr2,inode64,noquota)
For debugfs to work on linux systems you need to use lsdel (list deleted files), for example:

Code:
linux:/tmp# debugfs /dev/md0 

debugfs 1.44.1 (24-Mar-2018)
debugfs:  lsdel
debugfs:

However, according to the man page:

Quote:
debugfs - ext2/ext3/ext4 file system debugger
This means that debugfs should not work for a zfs file system.

I do not use the xfs filesystem on any server, so I cannot help on xfs.

I suggest you find something similar to debugfs that works on the xfs filesystem which will help you locale deleted files (if the the deleted inode entries have not yet been cleared).
# 10  
Hint: Try searching for:

Quote:
xfs_db - debug an XFS filesystem
This User Gave Thanks to Neo For This Post:
Login or Register to Reply

|
Thread Tools Search this Thread
Search this Thread:
Advanced Search

8 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

How to recover the deleted file in Linux?

hi, i deleted one file from linux please let me know, if we can recover it ? if yes, pls let me know the steps to do.. (3 Replies)
Discussion started by: raghur77
3 Replies

2. Red Hat

Recover deleted files from linux server machine..

Hi, I am working Linux server machine. Somebody by mistake(or may be knowingly) deleted few folders and files from the machine. How is this possible to recover those files and folders????:confused: I normally logged in through Putty and winscp only. And don't have any history for putty... (8 Replies)
Discussion started by: pamu
8 Replies

3. Shell Programming and Scripting

Need to Recover Deleted Files

Hi, By mistake, executed the following command : rm -rf * and ALL files got deleted. But I need to get back these files as they are very very important. Please help me how to recover this file. Its Urgent for me please. Thanks in advance. (6 Replies)
Discussion started by: unx100
6 Replies

4. UNIX for Dummies Questions & Answers

how to recover deleted files in unix

Hi Experts, by mistake i deleted some files that are very important to the project. is there any way that i can recover those files,there is no backup for that but the details of the file we know. This will be a great help. Thanks (5 Replies)
Discussion started by: namishtiwari
5 Replies

5. Shell Programming and Scripting

Is there a way to recover files deleted using rm command???

Hi All, I just mistakingly deleted some files using rm command.Is there a way to get it back?i work on Solaris 10 Thanks, Kumar (1 Reply)
Discussion started by: kumarsaravana_s
1 Replies

6. Linux

recover deleted files from memory stick

I'm running Fedora Core4. I deleted images off of my Sony DSC-P73 digital camera's memory stick. I'm looking for a *nix tool to recover the photos from the memory stick. Does anyone know of such a tool? (2 Replies)
Discussion started by: dangral
2 Replies

7. AIX

recover deleted files

How to recover deleted files in AIX ? (1 Reply)
Discussion started by: vjm
1 Replies

8. UNIX for Dummies Questions & Answers

Recover deleted files

Is there a Unix tool, like in Novell, to recover accidentally deleted files? (2 Replies)
Discussion started by: kuultak
2 Replies

Featured Tech Videos