Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!rutgers!mtune!codas!novavax!murphy!dave From: dave@murphy.UUCP (Dave Cornutt) Newsgroups: comp.unix.wizards Subject: Re: help with missing lost+found! Message-ID: <561@murphy.UUCP> Date: Fri, 14-Aug-87 15:31:53 EDT Article-I.D.: murphy.561 Posted: Fri Aug 14 15:31:53 1987 Date-Received: Sun, 16-Aug-87 05:54:55 EDT References: <180@LOGICON.LOGICON.UUCP> <142700014@tiger.UUCP> Organization: Gould CSD, Fort Lauderdale, FL Lines: 35 Summary: fsck needs empty directory slots, & a 4.3 question In article <142700014@tiger.UUCP>, authorplaceholder@tiger.UUCP.UUCP writes: > > > > Do any of you wizards out there in netland have a quick and easy way > > (BESIDES running mkfs) to recreate an accidentally deleted lost+found > > directory? Using mkdir() doesn't cut it... > > Why not? Mkdir() works on my machine.... What kind of machine are > you on? Mkdir by itself isn't sufficient. Several people have posted shell scripts that make a directory, create a bunch of files in it, and then delete the files. This works, at least for BSD4.2, and I think SYSV too. The idea is to create a bunch of directory slots and force the directory to be extended; this is necessary because fsck is not capable of extending the directory (after all, you can't expect the entire file system to be implemented inside fsck). If fsck tries to move some lost files to the lost+found directory, and there is no space left in the directory, you're out of luck. Now, here's my question: I've seen several postings here saying that BSD4.3 is capable of shrinking directories. In that case, if I create a bunch of files in a lost+found directory and then delete them, what's to stop it from shrinking the directory and undoing the effect? --- "I dare you to play this record" -- Ebn-Ozn Dave Cornutt, Gould Computer Systems, Ft. Lauderdale, FL [Ignore header, mail to these addresses] UUCP: ...!{sun,pur-ee,brl-bmd,seismo,bcopen,rb-dc1}!gould!dcornutt or ...!{ucf-cs,allegra,codas,hcx1}!novavax!gould!dcornutt ARPA: dcornutt@gswd-vms.arpa "The opinions expressed herein are not necessarily those of my employer, not necessarily mine, and probably not necessary."