You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ambari.apache.org by "Jonathan Hurley (JIRA)" <ji...@apache.org> on 2017/02/23 20:05:44 UTC

[jira] [Updated] (AMBARI-20148) "Set Version on All Hosts" Fails For Hosts Without Any Stack Components

     [ https://issues.apache.org/jira/browse/AMBARI-20148?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jonathan Hurley updated AMBARI-20148:
-------------------------------------
    Attachment: AMBARI-20148.patch

> "Set Version on All Hosts" Fails For Hosts Without Any Stack Components
> -----------------------------------------------------------------------
>
>                 Key: AMBARI-20148
>                 URL: https://issues.apache.org/jira/browse/AMBARI-20148
>             Project: Ambari
>          Issue Type: Bug
>          Components: ambari-server
>    Affects Versions: 2.5.0
>            Reporter: Jonathan Hurley
>            Assignee: Jonathan Hurley
>            Priority: Critical
>             Fix For: 2.5.0
>
>         Attachments: AMBARI-20148.patch
>
>
> During EU of HDP from 2.5.3.0 to 2.6.0.0, "Set Version on All Hosts" step failed for all hosts which don't have "versionable" components on them.
> *stdout*
> {noformat}
> * 2017-02-21 23:55:38,889 - Task. Type: EXECUTE, Script: scripts/ru_set_all.py - Function: actionexecute
> * 2017-02-21 23:55:39,048 - call[('/usr/bin/yum', 'clean', 'all')] {'sudo': True}
> * 2017-02-21 23:55:39,328 - call returned (0, 'Loaded plugins: fastestmirror, security\nCleaning repos: HDP-2.5 HDP-UTILS-1.1.0.21 ambari-2.5.0.0 base extras updates\nCleaning up Everything\nCleaning up list of fastest mirrors')
> * 2017-02-21 23:55:39,329 - call[('ambari-python-wrap', '/usr/bin/hdp-select', 'set', 'all', '2.6.0.0-517')] {'sudo': True}
> * 2017-02-21 23:55:39,356 - call returned (1, 'ERROR: Invalid version 2.6.0.0-517\n\nValid choices:')
> * Traceback (most recent call last):
> *   File "/var/lib/ambari-agent/cache/custom_actions/scripts/ru_set_all.py", line 189, in <module>
> *     UpgradeSetAll().execute()
> *   File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 313, in execute
> *     method(env)
> *   File "/var/lib/ambari-agent/cache/custom_actions/scripts/ru_set_all.py", line 65, in actionexecute
> *     raise Exception("Command '{0}' exit code is nonzero".format(cmd))
> * Exception: Command '('ambari-python-wrap', '/usr/bin/hdp-select', 'set', 'all', '2.6.0.0-517')' exit code is nonzero
> * Command failed after 1 tries
> {noformat}
> *stderr*
> {noformat}
> * Traceback (most recent call last):
> *   File "/var/lib/ambari-agent/cache/custom_actions/scripts/ru_execute_tasks.py", line 156, in <module>
> *     ExecuteUpgradeTasks().execute()
> *   File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 313, in execute
> *     method(env)
> *   File "/var/lib/ambari-agent/cache/custom_actions/scripts/ru_execute_tasks.py", line 153, in actionexecute
> *     shell.checked_call(task.command, logoutput=True, quiet=True)
> *   File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 72, in inner
> *     result = function(command, **kwargs)
> *   File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 102, in checked_call
> *     tries=tries, try_sleep=try_sleep, timeout_kill_strategy=timeout_kill_strategy)
> *   File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 150, in _call_wrapper
> *     result = _call(command, **kwargs_copy)
> *   File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 303, in _call
> *     raise ExecutionFailed(err_msg, code, out, err)
> * resource_management.core.exceptions.ExecutionFailed: Execution of 'source /var/lib/ambari-agent/ambari-env.sh ; /usr/bin/ambari-python-wrap /var/lib/ambari-agent/cache/custom_actions/scripts/ru_set_all.py actionexecute /var/lib/ambari-agent/data/command-71697.json /var/lib/ambari-agent/cache/custom_actions /var/lib/ambari-agent/data/structured-out-71697.json INFO /var/lib/ambari-agent/tmp' returned 1. 2017-02-21 23:55:39,048 - call[('/usr/bin/yum', 'clean', 'all')] {'sudo': True}
> * 2017-02-21 23:55:39,328 - call returned (0, 'Loaded plugins: fastestmirror, security\nCleaning repos: HDP-2.5 HDP-UTILS-1.1.0.21 ambari-2.5.0.0 base extras updates\nCleaning up Everything\nCleaning up list of fastest mirrors')
> * 2017-02-21 23:55:39,329 - call[('ambari-python-wrap', '/usr/bin/hdp-select', 'set', 'all', '2.6.0.0-517')] {'sudo': True}
> * 2017-02-21 23:55:39,356 - call returned (1, 'ERROR: Invalid version 2.6.0.0-517\n\nValid choices:')
> * Traceback (most recent call last):
> *   File "/var/lib/ambari-agent/cache/custom_actions/scripts/ru_set_all.py", line 189, in <module>
> *     UpgradeSetAll().execute()
> *   File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 313, in execute
> *     method(env)
> *   File "/var/lib/ambari-agent/cache/custom_actions/scripts/ru_set_all.py", line 65, in actionexecute
> *     raise Exception("Command '{0}' exit code is nonzero".format(cmd))
> * Exception: Command '('ambari-python-wrap', '/usr/bin/hdp-select', 'set', 'all', '2.6.0.0-517')' exit code is nonzero
> {noformat}
> {{hdp-select}} exists on this hosts, but since there's no stack installed, it can fail in two different ways:
> {code}
> [root@c6402 ~]# hdp-select versions
> Traceback (most recent call last):
>   File "/usr/bin/hdp-select", line 395, in <module>
>     printVersions()
>   File "/usr/bin/hdp-select", line 240, in printVersions
>     for f in os.listdir(root):
> OSError: [Errno 2] No such file or directory: '/usr/hdp'
> [root@c6402 ~]# echo $?
> 1
> {code}
> {code}
> [root@c6402 ~]# hdp-select versions
> [root@c6402 ~]# echo $?
> 0
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)