From e25955d8e2de7378585b4b348f9c10049a878c5e Mon Sep 17 00:00:00 2001 From: Ivan Devat Date: Mon, 4 Nov 2019 15:30:42 +0100 Subject: [PATCH 4/4] specify full path when running external tools --- pcsd/bootstrap.rb | 2 +- pcsd/pcs.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pcsd/bootstrap.rb b/pcsd/bootstrap.rb index c932a0cc..e79b0d92 100644 --- a/pcsd/bootstrap.rb +++ b/pcsd/bootstrap.rb @@ -63,7 +63,7 @@ end COROSYNC_QUORUMTOOL = COROSYNC_BINARIES + "corosync-quorumtool" if not defined? $cur_node_name - $cur_node_name = `hostname`.chomp + $cur_node_name = `/bin/hostname`.chomp end def configure_logger(log_device) diff --git a/pcsd/pcs.rb b/pcsd/pcs.rb index ad153f62..12eb3eb1 100644 --- a/pcsd/pcs.rb +++ b/pcsd/pcs.rb @@ -1849,7 +1849,7 @@ def cluster_status_from_nodes(auth_user, cluster_nodes, cluster_name) end def get_node_uptime() - uptime = `cat /proc/uptime`.chomp.split(' ')[0].split('.')[0].to_i + uptime = `/bin/cat /proc/uptime`.chomp.split(' ')[0].split('.')[0].to_i mm, ss = uptime.divmod(60) hh, mm = mm.divmod(60) dd, hh = hh.divmod(24) -- 2.21.0