Project

General

Profile

Actions

Bug #3632

open

The NFSv4 DRC max size should be dynamic

Added by Marcel Telka over 9 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
nfs - NFS server and client
Start date:
2013-03-16
Due date:
% Done:

0%

Estimated time:
Difficulty:
Medium
Tags:
needs-triage
Gerrit CR:

Description

The current max DRC size for NFSv4 server is 8192 entries:

46 /*
47  * The default size of the duplicate request cache
48  */
49 uint32_t nfs4_drc_max = 8 * 1024;

In case the number of nfsd threads (NFSD_SERVERS - see nfs(4)) is less than 8192, everything somehow works.

If there is more than 8192 threads configured, then we can end up in a situation when 8192 threads are handling non-idempotent requests (thus all 8192 DRC entries are in the NFS4_DUP_NEW state) and every new non-idempotent request will fail with NFS4ERR_RESOURCE (because no new DRC entry could be allocated).

In case the number of nfsd threads is less than (or equal to) 8192, you should never see the NFS4ERR_RESOURCE error caused by the DRC exhaustion.

It is obvious that the max size of DRC should be somehow dynamic. The NFSv4 DRC max size should at least depend on NFSD_SERVERS.

Workaround:

Do not setup more than 8192 nfsd threads and/or increase nfs4_drc_max (via /etc/system).

No data to display

Actions

Also available in: Atom PDF