Path: utzoo!attcan!uunet!zephyr!tektronix!tekcrl!terryl From: terryl@tekcrl.LABS.TEK.COM Newsgroups: comp.periphs Subject: Re: WORMs acting like R/W disks... Message-ID: <4242@tekcrl.LABS.TEK.COM> Date: 4 Jul 89 20:21:42 GMT References: <680@rna.UUCP+ <191@arnor.UUCP> <683@rna.UUCP> <423@siswat.UUCP> Reply-To: terryl@tekcrl.LABS.TEK.COM Organization: Tektronix, Inc., Beaverton, OR. Lines: 73 In article <423@siswat.UUCP+ buck@siswat.UUCP (A. Lester Buck) writes: +> In article <191@arnor.UUCP> uri@arnor.UUCP (Uri Blumenthal) writes: +> >From article <680@rna.UUCP>, by dan@rna.UUCP (Dan Ts'o): +> >> ......makes the WORM emulate a read/write +> > Well, maybe I'm not that smart, but how the hell can you emulate read/write +> > device on Write-Once-Read-Many? As I understand, it will be either TERRIBLY +> > non-effective (like zillions of bytes be eaten as garbage), or it will not +> > work at all (:-)! +> > So to use it as a source archive (with modifications once in every 100 years), +> > you probably can (if you're leaving at least 35% of WORM space free for those +> > games). But that's all! +> +> Well, of course it wouldn't be very good for putting your +> /usr/spool/news filesystem on. But /usr/src, probably pretty good. The point +> is that many of us have storage applications requiring random, moderately fast +> access (scratch Exabyte), large capacity and not too many changes (images, +> for example, or school records), but have not been able to use WORMS +> effectively because existing OS's and device drivers and filesystems require +> read-write semantics. Special software drivers must be written to allow +> transparent access to WORMS from UNIX, MSDOS, VMS, etc. However this OCU +> box eliminates the need for special software by putting all those functions +> and workarounds in "hardware" (host and OS independent hardware). +> But the write-once limitation isn't going to go away, not entirely. +> Sometimes you want 800Mb of archival info on a $100 cartridge. + +If you really want to know how to make a WORM look like a magnetic disk, +get a copy of the Summer '88 Usenix paper, "A UNIX File System for a +Write-Once Optical Disk", by Terry Laskodi et al. at Tektronix. +This is a filesystem built inside a Unix device driver which presents +a read/write disk to the operating system (though, of course, with lots +of writing the free space declines). Thanx for the plug, Mr. Buck, but I think I'd better clear up a few misconceptions you seem to have. First, you are correct that we provide the illusion to the OS that a Write-Once device is a Read-Write device, but we really did not build a file system inside the device driver. By the time a disk request is passed to a device driver, the only information the driver has is logical block number, a transfer count and transfer direction. What we really do in the device driver is to map the logical block number onto the real physical block number where the block actually resides on the medium. Of course, to do this we do need to maintain some data structures on the physical medium. All that information is encapsulated inside the device driver, but none of the higher level file systems operations know anything about this. For more excruciating detail, read the paper. Although the paper is(was) titled "A UNIX File System for a Write-Once Optical Disk", the methods we used are general enough to abstract onto almost any file system one might encounter (but we couldn't call it "A VMS File System for a Write-Once Optical Disk", we'd get laughed out of the conference!!!! (-:). +It is based on the report +"An Efficient I/O Interface for Optical Disks" by Jeffrey Scott Vitter, +Tech Report No. CS-84-15, June 1984, CS Dept, Brown University, where +Vitter presents some data structures for using WORMs and proves that +these algorithms are optimal (under some assumptions). Well, this is a judgement call, but our work wasn't based on Mr. Vitter's report alone. His was just one of a few papers on using Write-Once devices we surveyed in order to compare our work with. We like to think our work was more in keeping with the original UNIX philosophy, KISS (Keep It Simple, Stupid). Again, read the paper to find out why.... If you can't find a copy of the proceedings, drop me a line and I'll see if I can snail-mail you a copy of the paper. Terry Laskodi of Tektronix