Path: utzoo!utgpu!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!mailrus!ames!pasteur!agate!saturn!yale!root@husc6.harvard.edu From: yale!root@husc6.harvard.edu (Celray Stalk) Newsgroups: comp.os.research Subject: Re: OSF and operating system research, and other topics Message-ID: <5606@saturn.ucsc.edu> Date: 29 Nov 88 17:12:16 GMT Sender: usenet@saturn.ucsc.edu Organization: Yale University Computer Science Dept, New Haven CT 06520-2158 Lines: 35 Approved: comp-os-research@jupiter.ucsc.edu Along the lines of robust file systems: For my master's thesis I modified the Unix kernel (the SunOS version, which matters little except that the code was messier because it dealt with NFS) to include "transaction logging" in the database sense of the words. I used the sticky bit on non-executable files to mean that the file should have transactions logged on it whenever it was changed. Then in the kernel I added code that watched for this bit during writes and logged all changes (the before and after write data, the size of the write and the location it occured at) into a system-wide log file. The next step was to write a set of library routines which implemented the usual "undo", "redo", etc database functions on files which had logging done. The last step was to analyze the performance cost of logging a file. It turned out that, as expected, the cost was no higher than two synchronous disk writes. Synchronous because transaction logging requires that changes occur to the file before the changes are logged, and that cannot be assured unless synchronous writes are used. Of course extra disk space was used to store the transaction file. So the long answer to a short question is that it is possible to add at least _some_ more robustness to current Unix disk systems without incurring large performance penalties. (And of course you get more than just robustness through transaction logging.) --Peter ------------------------------------------ -------------------------------- Peter Baer Galvin (203)432-1254 Senior Systems Programmer, Yale Univ. C.S. galvin-peter@cs.yale.edu 51 Prospect St, P.O.Box 2158, Yale Station ucbvax!decvax!yale!galvin-peter New Haven, Ct 06457 galvin-peter@yalecs.bitnet