You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by "Romain Lenoel (JIRA)" <ji...@apache.org> on 2015/03/03 15:11:04 UTC
[jira] [Updated] (AMBARI-9812) Exception during after-INSTALL hook
(HDP 2.0.6) if stack version contains letters
[ https://issues.apache.org/jira/browse/AMBARI-9812?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Romain Lenoel updated AMBARI-9812:
----------------------------------
Fix Version/s: (was: 2.0.0)
> Exception during after-INSTALL hook (HDP 2.0.6) if stack version contains letters
> ---------------------------------------------------------------------------------
>
> Key: AMBARI-9812
> URL: https://issues.apache.org/jira/browse/AMBARI-9812
> Project: Ambari
> Issue Type: Bug
> Components: ambari-server, stacks
> Affects Versions: 2.0.0
> Reporter: Romain Lenoel
> Priority: Critical
> Attachments: AMBARI-9812.patch, AMBARI-9812_branch-2.0.0.patch
>
>
> When trying to install a stack named "2.2.XXX" which simply extends HDP-2.2 (and so 2.0.6), the following exception is raised :
> {code}
> Traceback (most recent call last):
> File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/after-INSTALL/scripts/hook.py", line 35, in <module>
> AfterInstallHook().execute()
> File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 208, in execute
> method(env)
> File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/after-INSTALL/scripts/hook.py", line 31, in hook
> setup_hdp_install_directory()
> File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/after-INSTALL/scripts/shared_initialization.py", line 26, in setup_hdp_install_directory
> if params.hdp_stack_version != "" and compare_versions(params.stack_version_unformatted, '2.2') >= 0:
> File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/version.py", line 73, in compare_versions
> return cmp(_normalize(version1, desired_segments=max_segments), _normalize(version2, desired_segments=max_segments))
> File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/version.py", line 34, in _normalize
> return [int(x) for x in v_list]
> ValueError: invalid literal for int() with base 10: 'XXX'
> {code}
> The exception raises because of the use of the unformatted version name in the following code {code}File "/var/lib/ambari-agent/cache/stacks/HDP/2.0.6/hooks/after-INSTALL/scripts/shared_initialization.py", line 26, in setup_hdp_install_directory
> if params.hdp_stack_version != "" and compare_versions(params.stack_version_unformatted, '2.2') >= 0{code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)