You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by dm...@apache.org on 2015/08/19 16:10:09 UTC
[2/2] ambari git commit: AMBARI-12810 Host check shows no errors when registering non root agents manually (dlysnichenko)
AMBARI-12810 Host check shows no errors when registering non root agents manually (dlysnichenko)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/8abab310
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/8abab310
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/8abab310
Branch: refs/heads/trunk
Commit: 8abab3106ee86083beb7804fa56b53d5ff5bed46
Parents: 9a8d5d9
Author: Lisnichenko Dmitro <dl...@hortonworks.com>
Authored: Wed Aug 19 17:10:16 2015 +0300
Committer: Lisnichenko Dmitro <dl...@hortonworks.com>
Committed: Wed Aug 19 17:11:22 2015 +0300
----------------------------------------------------------------------
.../libraries/functions/packages_analyzer.py | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/8abab310/ambari-common/src/main/python/resource_management/libraries/functions/packages_analyzer.py
----------------------------------------------------------------------
diff --git a/ambari-common/src/main/python/resource_management/libraries/functions/packages_analyzer.py b/ambari-common/src/main/python/resource_management/libraries/functions/packages_analyzer.py
index 3693886..7f34cc1 100644
--- a/ambari-common/src/main/python/resource_management/libraries/functions/packages_analyzer.py
+++ b/ambari-common/src/main/python/resource_management/libraries/functions/packages_analyzer.py
@@ -91,11 +91,11 @@ def allInstalledPackages(allInstalledPackages):
if OSCheck.is_suse_family():
return _lookUpZypperPackages(
- ["zypper", "search", "--installed-only", "--details"],
+ ["sudo", "zypper", "search", "--installed-only", "--details"],
allInstalledPackages)
elif OSCheck.is_redhat_family():
return _lookUpYumPackages(
- ["yum", "list", "installed"],
+ ["sudo", "yum", "list", "installed"],
'Installed Packages',
allInstalledPackages)
elif OSCheck.is_ubuntu_family():
@@ -109,11 +109,11 @@ def allAvailablePackages(allAvailablePackages):
if OSCheck.is_suse_family():
return _lookUpZypperPackages(
- ["zypper", "search", "--uninstalled-only", "--details"],
+ ["sudo", "zypper", "search", "--uninstalled-only", "--details"],
allAvailablePackages)
elif OSCheck.is_redhat_family():
return _lookUpYumPackages(
- ["yum", "list", "available"],
+ ["sudo", "yum", "list", "available"],
'Available Packages',
allAvailablePackages)
elif OSCheck.is_ubuntu_family():
@@ -121,7 +121,7 @@ def allAvailablePackages(allAvailablePackages):
LIST_AVAILABLE_PACKAGES_UBUNTU,
allAvailablePackages)
-
+# ToDo: add execution via sudo for ubuntu (currently Ubuntu is not supported)
def _lookUpAptPackages(command, allPackages):
try:
result = subprocessWithTimeout(command)