From ea552b5898059fe4ed3a546680763974c4e8eb19 Mon Sep 17 00:00:00 2001 From: lissav Date: Thu, 18 Jul 2013 14:14:33 +0000 Subject: [PATCH] fix so output only shows up under updatenode -V git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@17000 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT/postscripts/otherpkgs | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/xCAT/postscripts/otherpkgs b/xCAT/postscripts/otherpkgs index 3f5905509..93b2d9f18 100755 --- a/xCAT/postscripts/otherpkgs +++ b/xCAT/postscripts/otherpkgs @@ -560,8 +560,12 @@ while [ $op_index -le $OTHERPKGS_INDEX ]; do do result=`zypper sd $x` done - zypper --non-interactive refresh - repo_base="/tmp" + result=`zypper --non-interactive refresh 2>&1` + if [ $VERBOSE ]; then + echo "otherpkgs: zypper --non-interactive refresh" + echo " $result" + fi + repo_base="/tmp" elif [ $hasapt -eq 1 ] ; then mkdir -p /etc/apt/sources.list.d result=`rm /etc/apt/sources.list.d/xCAT-otherpkgs*.list 2>&1` @@ -654,7 +658,11 @@ while [ $op_index -le $OTHERPKGS_INDEX ]; do yum clean all fi if [ $haszypper -eq 1 ]; then - zypper --non-interactive refresh + result=`zypper --non-interactive refresh 2>&1` + if [ $VERBOSE ]; then + echo "otherpkgs: zypper --non-interactive refresh" + echo " $result" + fi fi elif [ $hasapt -eq 1 ] ; then REPOFILE="$repo_base/xCAT-otherpkgs$index.list"