From aab427f1643d78e8c525eb0879f89247662ed517 Mon Sep 17 00:00:00 2001 From: Steve Dickson Date: Tue, 22 Jun 2010 21:52:55 +0000 Subject: [PATCH] Updated nfs-utils-1-2-3-rc4.patch --- nfs-utils-1-2-3-rc4.patch | 17 +++++++++++++++++ nfs-utils.spec | 4 ++-- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/nfs-utils-1-2-3-rc4.patch b/nfs-utils-1-2-3-rc4.patch index eb9983a..deb5d4f 100644 --- a/nfs-utils-1-2-3-rc4.patch +++ b/nfs-utils-1-2-3-rc4.patch @@ -2281,6 +2281,23 @@ index 0000000..30f4054 + $(INSTALL) --mode 755 nfs-iostat.py $(DESTDIR)$(sbindir)/nfsiostat + +MAINTAINERCLEANFILES=Makefile.in +diff --git a/tools/nfs-iostat/nfs-iostat.py b/tools/nfs-iostat/nfs-iostat.py +index 2d0b143..1207674 100644 +--- a/tools/nfs-iostat/nfs-iostat.py ++++ b/tools/nfs-iostat/nfs-iostat.py +@@ -366,6 +366,12 @@ class DeviceData: + sends = float(self.__rpc_data['rpcsends']) + if sample_time == 0: + sample_time = float(self.__nfs_data['age']) ++ # sample_time could still be zero if the export was just mounted. ++ # Set it to 1 to avoid divide by zero errors in this case since we'll ++ # likely still have relevant mount statistics to show. ++ # ++ if sample_time == 0: ++ sample_time = 1; + if sends != 0: + backlog = (float(self.__rpc_data['backlogutil']) / sends) / sample_time + else: diff --git a/tools/nfs-iostat/nfsiostat.man b/tools/nfs-iostat/nfsiostat.man new file mode 100644 index 0000000..99e04fb diff --git a/nfs-utils.spec b/nfs-utils.spec index 4dd16d7..8ad17c2 100644 --- a/nfs-utils.spec +++ b/nfs-utils.spec @@ -2,7 +2,7 @@ Summary: NFS utilities and supporting clients and daemons for the kernel NFS ser Name: nfs-utils URL: http://sourceforge.net/projects/nfs Version: 1.2.2 -Release: 5%{?dist} +Release: 6%{?dist} Epoch: 1 # group all 32bit related archs @@ -251,7 +251,7 @@ fi %attr(4755,root,root) /sbin/umount.nfs4 %changelog -* Tue Jun 22 2010 Steve Dickson 1.2.2-5 +* Tue Jun 22 2010 Steve Dickson 1.2.2-6 - Update to upstream RC release: nfs-utils-1-2-3-rc4 * Thu May 6 2010 Steve Dickson 1.2.2-4