summaryrefslogtreecommitdiffstats
path: root/utils/statd/monitor.c
diff options
context:
space:
mode:
authorScott Mayhew <smayhew@redhat.com>2016-06-21 11:51:40 -0400
committerSteve Dickson <steved@redhat.com>2016-06-21 12:07:50 -0400
commit0aeb65f5f52903907451cdce7dbf0b4be21d46a3 (patch)
treeb0e1676db4d15a87dc792c96dc8e8620b85c9dd2 /utils/statd/monitor.c
parent6a648d46c0fcf28d76e80c4d7eb6509373f3e024 (diff)
downloadnfs-utils-0aeb65f5f52903907451cdce7dbf0b4be21d46a3.tar.gz
nfs-utils-0aeb65f5f52903907451cdce7dbf0b4be21d46a3.tar.xz
nfs-utils-0aeb65f5f52903907451cdce7dbf0b4be21d46a3.zip
statd: suppress a benign log message in nsm_delete_host()
Commit 76f8ce8c (statd: Update existing record if we receive SM_MON with new cookie) added some logic to unconditionally delete some existing on-disk monitor records. That works fine in an HA-NFS setup where there's a good chance of monitor files being left around after service failovers, but in the case where there isn't an existing monitor file statd emits a scary looking message like this: Jun 15 14:14:59 hostname rpc.statd[1368]: Failed to delete: could not stat original file /var/lib/nfs/statd/sm/nfs.smayhew.test: No such file or directory That message can be suppressed. Signed-off-by: Scott Mayhew <smayhew@redhat.com> Signed-off-by: Steve Dickson <steved@redhat.com>
Diffstat (limited to 'utils/statd/monitor.c')
-rw-r--r--utils/statd/monitor.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/utils/statd/monitor.c b/utils/statd/monitor.c
index 368bd80..45c4346 100644
--- a/utils/statd/monitor.c
+++ b/utils/statd/monitor.c
@@ -193,7 +193,7 @@ sm_mon_1_svc(struct mon *argp, struct svc_req *rqstp)
* Now, Create file on stable storage for host, first deleting any
* existing records on file.
*/
- nsm_delete_monitored_host(dnsname, mon_name, my_name);
+ nsm_delete_monitored_host(dnsname, mon_name, my_name, 0);
if (!nsm_insert_monitored_host(dnsname,
(struct sockaddr *)(char *)&my_addr, argp)) {
@@ -324,7 +324,7 @@ sm_unmon_1_svc(struct mon_id *argp, struct svc_req *rqstp)
ha_callout("del-client", mon_name, my_name, -1);
nsm_delete_monitored_host(clnt->dns_name,
- mon_name, my_name);
+ mon_name, my_name, 1);
nlist_free(&rtnl, clnt);
return (&result);
@@ -379,7 +379,7 @@ sm_unmon_all_1_svc(struct my_id *argp, struct svc_req *rqstp)
/* PRC: do the HA callout: */
ha_callout("del-client", mon_name, my_name, -1);
nsm_delete_monitored_host(clnt->dns_name,
- mon_name, my_name);
+ mon_name, my_name, 1);
nlist_free(&rtnl, clnt);
++count;
clnt = temp;