The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
.
google unix.com



UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Lost+found morrish Shell Programming and Scripting 1 05-15-2008 12:01 AM
lost+found morrish UNIX for Advanced & Expert Users 3 04-23-2008 06:00 PM
Lost+Found is not available vinod2all AIX 4 07-04-2005 09:50 AM
what is lost+found dir? bok UNIX for Advanced & Expert Users 1 06-01-2005 04:09 PM
lost+found Prafulla UNIX for Advanced & Expert Users 4 03-31-2002 01:24 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 02-16-2002
DPAI's Avatar
DPAI DPAI is offline
Registered User
  
 

Join Date: Jul 2001
Posts: 112
Lost+found

Hi all,

after a crash of our SUN Server 220R on file system was corrupt
and I had run fsck getting a lost of files/dir's in the lost+found
of the file system loking like

drwxrwxr-x 2 lmxadmin DOS---- 512 Oct 31 21:04 #0007680
drwxrwxr-x 2 lammer DOS---- 512 Jan 29 09:29 #0035347
drwxrwxr-x 2 wohlfart DOS---- 512 Nov 2 15:59 #0045338
drwxrwxr-x 2 kaptur DOS---- 512 Jan 24 12:48 #0046080
drwxrwxr-x 2 hariskos DOS---- 512 Nov 15 09:23 #0046853
drwxrwxr-x 2 mantel DOS---- 1024 Jan 23 17:21 #0072324
drwxrwxr-x 2 kaptur DOS---- 29184 Jan 29 10:21 #0103786
drwxrwxr-x 2 mantel DOS---- 1024 Jan 23 16:55 #0103791
drwxrwxr-x 2 kaptur DOS---- 1024 Jan 24 14:09 #0167459

Is it possible to get the contents of the files. I tried to
read it in some way but as as they are directories, I wasn't
successful.

Any hints on getting the files back will be of great help.

DP
  #2 (permalink)  
Old 02-16-2002
Perderabo's Avatar
Perderabo Perderabo is offline Forum Staff  
Unix Daemon
  
 

Join Date: Aug 2001
Location: Ashburn, Virginia
Posts: 9,131
On Suns the size field of a directory is a multiple of 512 bytes. And the minimum number of links on a directory is 2. These directories fufill these requirements and I think that they are really directories. But, on unix, directories are files and you can read them if you have read permission. One program that reads directories is called "ls". But you can use other programs too. I suggest "od -c".

Have you looked inside these directories to see if your files are there?

When fsck finds a problem, I always rerun it to see if I get a clean result. Every now and then, a second fsck run finds additional errors. You might try that.

Also see this thread: Retrieval of deleted files.
  #3 (permalink)  
Old 02-17-2002
DPAI's Avatar
DPAI DPAI is offline
Registered User
  
 

Join Date: Jul 2001
Posts: 112
The thing is , I go to the lost+found directory and whenever i give the command
ls #---<>----
It comes back to the home directory .... and shows the home directory too

I am confused ... How

DP
  #4 (permalink)  
Old 02-18-2002
inquirer
Guest
  
 

Posts: n/a
Bits: 0 [Banking]
Talking rename it

Files in the lost+found folders are usually files that has no inode for some valid reasons . Issue "file" command to determine if that file is a text file or something. And if you are sure that the file is part of what you need. Rename the file using the "mv" command outside the lost+found directory with respect to the type of file (e.g., mv <file> ~/<new filename>).

Thanks!
  #5 (permalink)  
Old 02-18-2002
Perderabo's Avatar
Perderabo Perderabo is offline Forum Staff  
Unix Daemon
  
 

Join Date: Aug 2001
Location: Ashburn, Virginia
Posts: 9,131
inquirer, there is no such thing as a file without an inode. Files (which have inodes) that are not listed in any directory are what gets reattached to lost+found and the name used is the inode number with a # in front of it.

DPAI, to most shells a # starts a comment. Try "ls \#0007680" or "ls ?0007680" or "ls *0007680".

Last edited by Perderabo; 02-18-2002 at 02:06 PM..
  #6 (permalink)  
Old 02-19-2002
thehoghunter
Guest
  
 

Posts: n/a
Bits: 0 [Banking]
It isn't going back to the home directory - some of the files that were lost WERE home directories. Just cd down to discover which ones were lost (do pwd to double check were you are).

When you ran fsck was it with the -y option?
If not, did you answer yes to all the questions?

Do you have a good backup? I don't know of a faster way to get the directories and files back then that unless you cd down to each home directory and move it back where it belongs. First you want to double check your hardware to insure you are not going to put them back on a bad disk.
  #7 (permalink)  
Old 02-20-2002
DPAI's Avatar
DPAI DPAI is offline
Registered User
  
 

Join Date: Jul 2001
Posts: 112
"ls \#0007680" works . Thats great Per....

Yes hoghunter, i answered yes to all the questions . I mean thats the only way to get the partitions to load .

Or is there another way ..

Humor me

DP
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 12:14 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0