[OpenAFS-devel] Problems using the RedHat patches to get OpenAFS
working on Debian using 2.6 kernel
Rainer Schöpf
rainer.schoepf@proteosys.com
Wed, 7 Jul 2004 22:39:03 +0200 (CEST)
On Wed, 7 Jul 2004, Christine Nattrass wrote:
> Here's what I do when I try to run openafs now:
> madscientistgirl@tesla:~/skype_ver-0_90_0_6$ su
> Password:
> tesla:/home/madscientistgirl/skype_ver-0_90_0_6# insmod /usr/local/lib/openafs/libafs-2.6.7.ko
> tesla:/home/madscientistgirl/skype_ver-0_90_0_6# dmesg
> ...
> libafs: module license 'unspecified' taints kernel.
> Found sys_call_table at c0442200
> tesla:/usr/local# /usr/local/sbin/afsd -memcache
> afsd: WARNING: Cache dir check failed (unable to stat cache base directory)
This happens because of -memcache (can therefore be ignored).
> afsd: All AFS daemons started.
> afsd: Can't mount AFS on /afs(22)
Error #22 is EINVAL, Invalid argument. Does this happen immediately, or
after some timeout? In the latter case, it may be that it cannot find the
cell servers in its home cell.
Try this:
/usr/local/sbin/afsd -memcache -nosettime -verbose -debug
> I evidently do have it set up so that was trying to use an xfs file
> system for the cache -- how do I change this?
Several possibilities:
a) use -memcache,
b) replace the xfs by ext3 (or jfs),
c) create an additional ext3 (or jfs) partition and put the cache on it
> Why won't xfs and work?
The AFS disk cache code assumes that it can get a file's inode by calling
the kernel function iget, which isn't true for xfs. Even worse, trying to
call iget for such a file gives you a null pointer, ie a segmentation
fault. Similar things happen for reiserfs. Personally, I think this is a
strange design of the kernel interface, but who am I to criticize the
linux kernel developers...
> Is there any more information on this?
I'm afraid not. afsd will complain if the cache is on a reiserfs
partition, but die happily while trying to access the cache on xfs.
Here is an untested patch to at least give a warning:
*** src/afsd/afsd.c~ 2004-05-08 06:12:27.000000000 +0200
--- src/afsd/afsd.c 2004-07-07 22:27:20.000000000 +0200
***************
*** 1049,1054 ****
--- 1049,1056 ----
}
if (statfsbuf.f_type == 0x52654973) { /* REISERFS_SUPER_MAGIC */
return "cannot use reiserfs as cache partition";
+ } else if (statfsbuf.f_type == 0x58465342) { /* XFS_SUPER_MAGIC */
+ return "cannot use xfs as cache partition";
}
}
#endif
Rainer Schöpf