summaryrefslogtreecommitdiff
path: root/ctdb/config
diff options
context:
space:
mode:
authorRafael David Tinoco via samba-technical <samba-technical@lists.samba.org>2019-06-02 23:44:15 -0300
committerAndreas Schneider <asn@cryptomilk.org>2019-06-04 23:31:24 +0000
commit843fbb1207ee7ac84f3282974b66b9290d8da0ac (patch)
tree9a5876018ee967abe5900ff1b47502057b293aa7 /ctdb/config
parentb9b3acf23e3306ba5cfd1fd254250eef97793921 (diff)
downloadsamba-843fbb1207ee7ac84f3282974b66b9290d8da0ac.tar.gz
ctdb-scripts: Fix tcp_tw_recycle existence check
net.ipv4.tcp_tw_recycle has been removed from Linux 4.12 but, still, makes sense to check its existence. Unfortunately, current check does not test for the procfs file existence. This commit fixes the issue. BUG: https://bugzilla.samba.org/show_bug.cgi?id=13984 Signed-off-by: Rafael David Tinoco <rafaeldtinoco@ubuntu.com> Reviewed-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Tue Jun 4 23:31:24 UTC 2019 on sn-devel-184
Diffstat (limited to 'ctdb/config')
-rwxr-xr-xctdb/config/nfs-linux-kernel-callout4
1 files changed, 2 insertions, 2 deletions
diff --git a/ctdb/config/nfs-linux-kernel-callout b/ctdb/config/nfs-linux-kernel-callout
index def69a04649..71d8ecf8074 100755
--- a/ctdb/config/nfs-linux-kernel-callout
+++ b/ctdb/config/nfs-linux-kernel-callout
@@ -281,8 +281,8 @@ nfs_startup ()
basic_stop "nfs" || true
basic_start "nfs"
_f="${PROCFS_PATH}/sys/net/ipv4/tcp_tw_recycle"
- if [ "$_f" ] ; then
- echo 1 >"$_f"
+ if [ -f "$_f" ] ; then
+ echo 1 >"$_f"
fi
}