NetBSD/sys/coda
hannken 2b6ec89863 The current implementation of vn_lock() is racy. Modification of
the vnode operations vector for active vnodes is unsafe because it
is not known whether deadfs or the original file system will be
called.

- Pass down LK_RETRY to the lock operation (hint for deadfs only).

- Change deadfs lock operation to return ENOENT if LK_RETRY is unset.

- Change all other lock operations to check for dead vnode once
  the vnode is locked and unlock and return ENOENT in this case.

With these changes in place vnode lock operations will never succeed
after vclean() has marked the vnode as VI_XLOCK and before vclean()
has changed the operations vector.

Adresses PR kern/37706 (Forced unmount of file systems is unsafe)

Discussed on tech-kern.

Welcome to 6.99.33
2014-02-27 16:51:37 +00:00
..
cnode.h remove variable names from prototypes. 2012-05-04 01:38:56 +00:00
coda_io.h
coda_namecache.c - move debugging functions to vcoda so modules with -DDEBUG link 2012-08-02 16:06:58 +00:00
coda_namecache.h bcmp -> memcmp 2009-03-18 15:14:29 +00:00
coda_opstats.h
coda_pioctl.h Fix incorrect comments about the buffer size being 2K; it is really 8K now. 2010-08-07 20:39:33 +00:00
coda_psdev.c C requires a statement after a label, and a declaration is not a 2013-10-18 00:03:35 +00:00
coda_subr.c - move debugging functions to vcoda so modules with -DDEBUG link 2012-08-02 16:06:58 +00:00
coda_subr.h - move debugging functions to vcoda so modules with -DDEBUG link 2012-08-02 16:06:58 +00:00
coda_venus.c remove unused code from macro 2013-10-17 20:56:02 +00:00
coda_venus.h
coda_vfsops.c Ensure that the top level sysctl nodes (kern, vfs, net, ...) exist before 2014-02-25 18:30:08 +00:00
coda_vfsops.h
coda_vnops.c The current implementation of vn_lock() is racy. Modification of 2014-02-27 16:51:37 +00:00
coda_vnops.h - move debugging functions to vcoda so modules with -DDEBUG link 2012-08-02 16:06:58 +00:00
coda.h Fix incorrect comments about the buffer size being 2K; it is really 8K now. 2010-08-07 20:39:33 +00:00
files.coda Don't generate unused fs_thefs.h headers. 2010-03-02 16:43:48 +00:00
README mention current status 2012-08-04 12:47:00 +00:00
TODO

$NetBSD: README,v 1.4 2012/08/04 12:47:00 christos Exp $

Coda is a distributed filesystem.  It is derived from AFS, but
supports disconnected operation, both reading and writing.  This
directory contains the interface between the VFS layer and a
user-space program ("venus") that implements the client part of Coda.
The interface is similar to puffs(9) in many respects.

Coda servers do not need kernel support.

For information on Coda, see
  http://www.coda.cs.cmu.edu

As of Sat Aug  4 15:45:27 EEST 2012
	- The coda/vcoda modules have been tested for read/write
	  operations and load/unload on amd64 with a DEBUG/DIAGNOSTIC
	  kernel and there are no locking errors.
	- If you find issues with coda, please file a bug report.
	  Also help can be obtained via the list codalist@coda.cs.cmu.edu.
	- Pkgsrc/net/coda has the latest source available from cmu and
	  has been fixed to co-exist with openafs (openafs has been modified)

To test:
- Install pkgsrc/net/coda

# rm -fr /var/lib/coda			# remove junk if there was a crash
# /usr/pkg/sbin/venus-setup xxxx	# xxxx the domain name
# /usr/pkg/sbin/venus
# clog guest@testserver.coda.cs.cmu.edu	# password is guest
# echo foo > /coda/testserver.coda.cs.cmu.edu/playground/nb.test0 

You should be able to access things in /coda