[OpenAFS-devel] locking fairness on Linux?

John S. Bucy bucy-openafs-devel@gloop.org
Sat, 7 May 2005 13:36:24 -0400


On Thu, May 05, 2005 at 11:42:10PM -0400, Chaskiel M Grundman wrote:
> --On Thursday, May 05, 2005 10:17:16 PM -0400 "John S. Bucy" 
> <bucy-openafs-devel@gloop.org> wrote:
> 
> > still see the same behavior if I set
> >the working set size to fit within the dnlc (say, 250 files).  If I
> >understand that code correctly, it shouldn't find its way back into
> >afs_lookup unless it misses the dnlc.
> Note that the dnlc working set is bounded by the vcache size, so if you 
> have -stat 100, then the dnlc will not grow above 100 entries.
> 
> I will run the code and get some stack backtraces to look at tomorrow.


Here's what I got.  I can't make much of it and it seems a little
garbled.  PID 8715 is starving and PID 8716 is running.



john

statnr-rate   S C03CDC88     0  8715   8700                     (NOTLB)
c6acdaf4 00000086 d6305a00 c03cdc88 00034085 d89f8300 ccfe7268 ccfe7260
       e2ca2747 00034085 d6305a00 0000173e e2ca2747 00034085 d65e1bf0 c6acc000
       0001edac cd8e16c0 cd8e16d0 d8abde04 ccfe7270 00000000 00000000 d65e1aa0
Call Trace:
 [<d8abde04>] afs_osi_SleepSig+0xb4/0xf0 [libafs]
 [<c01111a0>] default_wake_function+0x0/0x20
 [<c01111a0>] default_wake_function+0x0/0x20
 [<d8ab0ca3>] rxi_FlushWrite+0x133/0x1b0 [libafs]
 [<d8abde8d>] afs_osi_Sleep+0x4d/0x80 [libafs]
 [<d8aaf347>] rxi_ReadProc+0xe7/0x470 [libafs]
 [<d8ab001a>] rxi_WriteProc+0x1fa/0x4b0 [libafs]
 [<d8ab1143>] rxevent_Post+0x33/0x40 [libafs]
 [<d8aaf820>] rx_ReadProc32+0x80/0xe0 [libafs]
 [<d8ab468a>] xdrrx_getint32+0x1a/0x40 [libafs]
 [<d8aa2f2e>] xdr_afs_uint32+0x3e/0x40 [libafs]
 [<d8aa0f8f>] xdr_AFSFetchStatus+0x1f/0x220 [libafs]
 [<d8aa360a>] RXAFS_FetchStatus+0x17a/0x1c0 [libafs]
 [<d8a729f0>] afs_choose_cell_by_num+0x0/0x20 [libafs]
 [<d8a73642>] afs_Conn+0x102/0x1d0 [libafs]
 [<c01069fa>] do_gettimeofday+0x1a/0xd0
 [<d8a8bf2c>] afs_FetchStatus+0xbc/0x580 [libafs]
 [<d8a728d1>] afs_TraverseCells_nl+0x31/0x50 [libafs]
 [<d8a72937>] afs_TraverseCells+0x47/0xc0 [libafs]
 [<d8a9eda5>] afs_GetVolume+0x25/0x80 [libafs]
 [<d8a88a38>] afs_RemoveVCB+0xb8/0xe0 [libafs]
 [<d8a8a7a4>] afs_GetVCache+0x2b4/0x510 [libafs]
 [<d8a7c540>] afs_dir_GetBlob+0x20/0x40 [libafs]
 [<d8a7c609>] FindItem+0x69/0x120 [libafs]
 [<d8a7c303>] afs_dir_LookupOffset+0x73/0x80 [libafs]
 [<d8a95837>] afs_lookup+0xd07/0x13f0 [libafs]
 [<d8a8d69c>] afs_CopyOutAttrs+0x13c/0x230 [libafs]
 [<d8abbf8c>] crget+0x4c/0xc0 [libafs]
 [<d8ac09a7>] afs_linux_lookup+0x37/0x140 [libafs]
 [<c0157271>] real_lookup+0xc1/0xf0
 [<c0157506>] do_lookup+0x96/0xb0
 [<c0157aad>] link_path_walk+0x58d/0xb10
 [<c01d6040>] __copy_to_user_ll+0x70/0x80
 [<c015827e>] path_lookup+0x6e/0x120
 [<c01584f3>] __user_walk+0x33/0x60
 [<c015335f>] vfs_stat+0x1f/0x60
 [<c0153aab>] sys_stat64+0x1b/0x40
 [<c01d6112>] copy_to_user+0x42/0x60
 [<c01181dc>] sys_gettimeofday+0x3c/0x90
 [<c0102493>] syscall_call+0x7/0xb
statnr-rate   D C03CD7E0     0  8716   8706                     (NOTLB)
cc8ede08 00000082 d6305510 c03cd7e0 cc8ede30 00000008 d8a8cfd2 d6393800
       00000008 cc8ede30 d6305020 00000070 e2ca3262 00034085 d6305660 d6393870
       d6305510 00000286 d6393878 c02cfaab 00000001 d6305510 c01111a0 d6393878
Call Trace:
 [<d8a8cfd2>] afs_AccessOK+0x42/0x170 [libafs]
 [<c02cfaab>] __down+0x7b/0xd0
 [<c01111a0>] default_wake_function+0x0/0x20
 [<c012195e>] groups_alloc+0x3e/0xd0
 [<c02cfbff>] __down_failed+0x7/0xc
 [<c015ab4b>] .text.lock.namei+0x8/0x1dd
 [<c0157506>] do_lookup+0x96/0xb0
 [<c0157aad>] link_path_walk+0x58d/0xb10
 [<c015827e>] path_lookup+0x6e/0x120
 [<c01584f3>] __user_walk+0x33/0x60
 [<c015335f>] vfs_stat+0x1f/0x60
 [<c013f150>] do_brk+0x250/0x2d0
 [<c0153aab>] sys_stat64+0x1b/0x40
 [<c01d6112>] copy_to_user+0x42/0x60
 [<c01181dc>] sys_gettimeofday+0x3c/0x90
 [<c010f3d0>] do_page_fault+0x0/0x5d5
 [<c0102493>] syscall_call+0x7/0xb