From owner-svn-src-stable-11@freebsd.org Sat Dec 16 00:44:12 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9FBDAE91467; Sat, 16 Dec 2017 00:44:12 +0000 (UTC) (envelope-from cperciva@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6C1806D6C5; Sat, 16 Dec 2017 00:44:12 +0000 (UTC) (envelope-from cperciva@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBG0iB2Y082413; Sat, 16 Dec 2017 00:44:11 GMT (envelope-from cperciva@FreeBSD.org) Received: (from cperciva@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBG0iBMI082412; Sat, 16 Dec 2017 00:44:11 GMT (envelope-from cperciva@FreeBSD.org) Message-Id: <201712160044.vBG0iBMI082412@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cperciva set sender to cperciva@FreeBSD.org using -f From: Colin Percival Date: Sat, 16 Dec 2017 00:44:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326891 - stable/11/sys/fs/nfs X-SVN-Group: stable-11 X-SVN-Commit-Author: cperciva X-SVN-Commit-Paths: stable/11/sys/fs/nfs X-SVN-Commit-Revision: 326891 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 16 Dec 2017 00:44:12 -0000 Author: cperciva Date: Sat Dec 16 00:44:11 2017 New Revision: 326891 URL: https://svnweb.freebsd.org/changeset/base/326891 Log: Add vfs.nfs.suppress_32bits_warning sysctl which reduces the frequency of 'fileid > 32bits' warnings from at most once per minute to at most once per day. Direct commit to stable/11 since the relevant code was removed from HEAD following the switch to 64-bit inodes. Requested by: Rafal Lukawiecki Approved by: rmacklem Modified: stable/11/sys/fs/nfs/nfs_commonsubs.c Modified: stable/11/sys/fs/nfs/nfs_commonsubs.c ============================================================================== --- stable/11/sys/fs/nfs/nfs_commonsubs.c Fri Dec 15 23:50:26 2017 (r326890) +++ stable/11/sys/fs/nfs/nfs_commonsubs.c Sat Dec 16 00:44:11 2017 (r326891) @@ -69,6 +69,7 @@ int nfsrv_lease = NFSRV_LEASE; int ncl_mbuf_mlen = MLEN; int nfsd_enable_stringtouid = 0; static int nfs_enable_uidtostring = 0; +static int nfs_suppress_32bits_warning = 0; NFSNAMEIDMUTEX; NFSSOCKMUTEX; extern int nfsrv_lughashsize; @@ -76,6 +77,8 @@ extern int nfsrv_lughashsize; SYSCTL_DECL(_vfs_nfs); SYSCTL_INT(_vfs_nfs, OID_AUTO, enable_uidtostring, CTLFLAG_RW, &nfs_enable_uidtostring, 0, "Make nfs always send numeric owner_names"); +SYSCTL_INT(_vfs_nfs, OID_AUTO, suppress_32bits_warning, CTLFLAG_RW, + &nfs_suppress_32bits_warning, 0, "Suppress \"> 32 bits\" warnings"); /* * This array of structures indicates, for V4: @@ -836,7 +839,8 @@ nfsv4_loadattr(struct nfsrv_descript *nd, vnode_t vp, static size_t count64fileid; static struct timeval last64mountfileid; static size_t count64mountfileid; - static struct timeval warninterval = { 60, 0 }; + struct timeval warninterval = + { nfs_suppress_32bits_warning ? 86400 : 60, 0 }; if (compare) { retnotsup = 0;