diff options
author | wanglei <wang840925@gmail.com> | 2010-08-11 09:38:04 +0100 |
---|---|---|
committer | Steve French <sfrench@us.ibm.com> | 2010-08-11 17:11:29 +0000 |
commit | bec5eb6141308a30a73682330cb045a40e442b8c (patch) | |
tree | ae514575d62e65a07d6089746fbd880f816ee382 /fs/afs/proc.c | |
parent | 4a2d789267e00b5a1175ecd2ddefcc78b83fbf09 (diff) | |
download | op-kernel-dev-bec5eb6141308a30a73682330cb045a40e442b8c.zip op-kernel-dev-bec5eb6141308a30a73682330cb045a40e442b8c.tar.gz |
AFS: Implement an autocell mount capability [ver #2]
Implement the ability for the root directory of a mounted AFS filesystem to
accept lookups of arbitrary directory names, to interpet the names as the names
of cells, to look the cell names up in the DNS for AFSDB records and to mount
the root.cell volume of the nominated cell on the pseudo-directory created by
lookup.
This facility is requested by passing:
-o autocell
to the mountpoint for which this is desired, usually the /afs mount.
To use this facility, a DNS upcall program is required for AFSDB records. This
can be obtained from:
http://people.redhat.com/~dhowells/afs/dns.afsdb.c
It should be compiled with -lresolv and -lkeyutils and installed as, say:
/usr/sbin/dns.afsdb
Then the following line needs to be added to /sbin/request-key.conf:
create dns_resolver afsdb:* * /usr/sbin/dns.afsdb %k
This can be tested by mounting AFS, say:
insmod dns_resolver.ko
insmod af-rxrpc.ko
insmod kafs.ko rootcell=grand.central.org
mount -t afs "#grand.central.org:root.cell." /afs -o autocell
and doing:
ls /afs/grand.central.org/
which should show:
archive/ cvs/ doc/ local/ project/ service/ software/ user/ www/
if it works.
Signed-off-by: Wang Lei <wang840925@gmail.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/afs/proc.c')
-rw-r--r-- | fs/afs/proc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/afs/proc.c b/fs/afs/proc.c index 852739d..096b23f 100644 --- a/fs/afs/proc.c +++ b/fs/afs/proc.c @@ -294,7 +294,7 @@ static ssize_t afs_proc_cells_write(struct file *file, const char __user *buf, if (strcmp(kbuf, "add") == 0) { struct afs_cell *cell; - cell = afs_cell_create(name, args); + cell = afs_cell_create(name, strlen(name), args, false); if (IS_ERR(cell)) { ret = PTR_ERR(cell); goto done; |