OpenAFS Master Repository branch, openafs-stable-1_6_x, updated. openafs-stable-1_6_22_2-25-g1922a30

Gerrit Code Review
Mon, 9 Apr 2018 05:01:31 -0400

The following commit has been merged in the openafs-stable-1_6_x branch:
commit 1922a30c3d793b0fa401f1c5048637ffc5ae5a87
Author: Michael Meffie <>
Date:   Fri Jul 7 11:11:12 2017 -0400

    afs: fix afs_xserver deadlock in afsdb refresh
    When setting up a new volume, the cache manager calls afs_GetServer() to
    setup the server object for each fileserver associated with the volume.
    The afs_GetServer() function locks afs_xserver and then, among other
    things, calls afs_GetCell() to lookup the cell info by cell number.
    When the cache manager is running in afsdb mode, afs_GetCell() will
    attempt to refresh the cell info if the time-to-live has been exceeded
    since the last call to afs_GetCell(). During this refresh the AFSDB
    calls afs_GetServer() to update the vlserver information. The afsdb
    handler thread and the thread processing the volume setup become
    deadlocked since the afs_xserver lock is already held at this point.
    This bug will manifest when the DNS SRV record TTL is smaller than the
    time the fileservers respond to the GetCapabilities RPC within
    afs_GetServer() and there are multiple read-only servers for a volume.
    Avoid the deadlock by using the afs_GetCellStale() variant within
    afs_GetServer(). This variant returns the memory resident cell info
    without the afsdb upcall and the subsequent afs_GetServer() call.
    Tested-by: BuildBot <>
    Reviewed-by: Benjamin Kaduk <>
    (cherry picked from commit 030a9849e22f443492342794f436e2c86c98a903)
    Change-Id: I01ad0c3fd042a818a9387db2d847208da6d7689a
    Tested-by: BuildBot <>
    Reviewed-by: Michael Meffie <>
    Reviewed-by: Mark Vitale <>
    Reviewed-by: Stephan Wiesand <>

 src/afs/afs_server.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

OpenAFS Master Repository