home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.os.coherent
- Path: sparky!uunet!news.mentorg.com!analog1!patbob
- From: patbob@analog1com (Patrick White - SST)
- Subject: Re: 4.0, Low level IO and problems...
- Sender: news@news.mentorg.com (News User)
- Message-ID: <1992Aug20.201610.16702@news.mentorg.com>
- Date: Thu, 20 Aug 1992 20:16:10 GMT
- References: <SJE.92Aug14141342@xylos.ma30.bull.com> <9208192524@umunk.GUN.de>
- Nntp-Posting-Host: analog1.mentorg.com
- Organization: mentor
- Keywords:
- Followup-To:
- Lines: 42
-
- In article <9208192524@umunk.GUN.de>, udo@umunk.GUN.de (Udo Munk) writes:
- |> sje@xylos.ma30.bull.com (Steven J. Edwards) writes:
- |> : Undeletes are just too dangerous on Unix-type systems because it's too
- |> : hard to guarantee file system integrity when more than one agent is
- |> : accessing the same information. Remeber, the Unix file system
- |> : utilities are designed with the thought that only they as a group will
- |> : be fiddling with various hidden parts; they often assume that
- |> : everything is okay, thus causing human-introduced errors to grow and
- |> : expand in avalanche fashion.
- |>
- |> There is a save way: substitue rm by a programm, which brings the file
- |> to delete into an archive (tar, zip, cpio or whatever). After that the
- |> file can be deleted by the new command. Write an undelete command which
- |> extracts the file back from the archive, and then removes it from the
- |> archive. Of cause this needs more or less diskspace. Take a look onto
- |> DR-DOS 6.0, how DRI has solved this problem.
-
- A faster and more efficient way is to have rm make a hard link to the
- file in a save directory before it unlinks it. Much faster than copying bytes.
- Of course, need to make provisions for people removing files of the
- same name, and usually want a way to automatically remove old saved files when
- need the space on the file system.
-
- I see three ways to implement this:
-
- 1) write a new rm. But this would only save files removed with it.
- 2) change the C library unlink() function. Only things recompiled
- with the new C lib will save files.
- 3) rewrite the unlink system call (ie. diddle in the kernel). This
- would give retroactive file saving to all binaries on the system,
- but requires OS source. However, doing this also would allow the
- OS file system code to be modified to remove old saved files as
- needed to reclaim filesystem space.
-
- I've seen this done via (1) & (3). There is a performance loss either
- way, but (3) provided the most transparent solution.
-
- I didn't invent these ideas, I've just seen them tried at school.
-
-
- later,
- Pat White (patbob@techbook.com | patbob@mentorg.com)
-