[OpenAFS-devel] afsd & libafs module version checking??

Troy Benjegerdes hozer@hozed.org
Fri, 9 Dec 2005 22:13:45 -0600


Is there a good way we can put a version string in both afsd and the
kernel module, and spit out a warning if they are mismatched?

I just spent about an hour debugging what looks like using an old afsd
with a new kernel module. I had the old debian /usr/sbin/afsd installed.
If I started afsd manually, (/usr/local/sbin/afsd), it started up fine.

When the debian /etc/init.d/openafs-client script ran, it did:

/usr/sbin/afsd -stat 2000 -dcache 800 -daemons 3 -volumes 70 -fakestat
-afsdb -nosettime

And I get the following oops (with extra debug code in
afs_ComputeCacheParms)


Starting AFS cache scan...afs_ComputeCacheParms afs_cacheblocks:
0x1000000
AFS_FIRSTCSIZE: 0x0 0x0
divide error: 0000 [#2]
SMP
Modules linked in: libafs af_packet ipv6 evdev pcspkr psmouse floppy
aic79xx shpchp pciehp pci_hotplug serverworks sworks_agp agpgart
ohci_hcd usbcore aic7xxx tg3 firmware_class ide_cd ide_core cdrom genrtc
ext3 jbd mbcache sd_mod aacraid scsi_mod unix
CPU:    0
EIP:    0060:[<f8becaed>]    Tainted: PF
EFLAGS: 00010246   (2.6.8-2nopreempt-686-smp)
EIP is at afs_ComputeCacheParms+0x6d/0xc0 [libafs]
eax: 01000000   ebx: 55555556   ecx: 00000000   edx: 00000000
esi: 00111110   edi: 00000000   ebp: f8b69000   esp: f4f71dac
ds: 007b   es: 007b   ss: 0068
Process afsd (pid: 2240, threadinfo=f4f70000 task=f4e08650)
Stack: f8c4db64 00000000 00000000 f8c62478 00000000 f8bea5e8 f8b883a8
f89760a8
       00000000 00666664 f897a000 00000046 00199999 000007d0 f8bec9dc
00199999
       01000000 00000320 00000000 00000000 0000f000 00000001 f8c60100
00000000
Call Trace:
 [<f8bea5e8>] afs_dcacheInit+0x378/0x3d0 [libafs]
 [<f8bec9dc>] afs_CacheInit+0x13c/0x1e0 [libafs]
 [<f8c3969c>] afs_syscall_call+0xfac/0x1910 [libafs]
 [<c013e7d0>] buffered_rmqueue+0x100/0x1f0
 [<c013ebd0>] __alloc_pages+0x310/0x370
 [<f8c3a4de>] afs_syscall+0x3ee/0x4c0 [libafs]
 [<f8c3281f>] afs_ioctl+0x5f/0x70 [libafs]
 [<c0171de1>] dput+0x31/0x1b0
 [<c016ceac>] file_ioctl+0x5c/0x1c0
 [<c016d137>] sys_ioctl+0x127/0x26a
 [<c0158cce>] sys_open+0x7e/0x90
 [<c010604f>] syscall_call+0x7/0xb
Code: f7 f9 89 44 24 04 89 c3 c7 04 24 40 80 c4 f8 e8 2f 25 53 c7


Nuking the old debian afsd and symlinking /usr/sbin/afsd to
/usr/local/bin/afsd makes it all happy again.