You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by "Alejandro Fernandez (JIRA)" <ji...@apache.org> on 2015/06/19 02:28:00 UTC

[jira] [Updated] (AMBARI-12012) Install packages doesn't update actual version with build number if installation timesout on all hosts

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

Alejandro Fernandez updated AMBARI-12012:
-----------------------------------------
    Description: 
STR:

1. User registers repo version 2.3.0.0 (notice that a build number was not provided), and clicks the Install button
2. On all of the hosts, the yum commands timeout (or does a partial install), this way, "hdp-select versions" will report that 2 versions exist (2.2.0.0-2041 and 2.3.0.0-2800). Because the install did not succeed, the command will not return the actual_version installed (which was 2.3.0.0-2800). Note: I did this by decreasing the timeouts in ambari.properties file to 5 mins, and adding a sleep in install_packages.py after the first package was installed.
3. The ambari server code then changes the state of the 2.3.0.0 version it knows about to INSTALL_FAILED so that the user can retry, but did not update the repo version with the actual build version that includes the build number.
4. User retries and this time it succeeds. However, the delta of "hdp-select versions" outputs "", so no "actual_version" is returned! This is really bad because the build number is needed for ambari to use it whenever it calls "hdp-select set <comp> <version>"
5. The ambari server code will change the state to INSTALLED.
The fix is for install_packages.py to always return the actual_version (even in the case of a failure) so that Ambari server can correct the database entry (even if the command fails/timesout). This will only happen the first time, but subsequent attempts to retry installation will use the right value so an exact match will be found in the database. 

  was:
1. User registers repo version 2.3.0.0 (notice that a build number was not provided), and clicks the Install button
2. On all of the hosts, the yum commands timeout (or does a partial install), this way, "hdp-select versions" will report that 2 versions exist (2.2.0.0-2041 and 2.3.0.0-2800). Because the install did not succeed, the command will not return the actual_version installed (which was 2.3.0.0-2800). Note: I did this by decreasing the timeouts in ambari.properties file to 5 mins, and adding a sleep in install_packages.py after the first package was installed.
3. The ambari server code then changes the state of the 2.3.0.0 version it knows about to INSTALL_FAILED so that the user can retry, but did not update the repo version with the actual build version that includes the build number.
4. User retries and this time it succeeds. However, the delta of "hdp-select versions" outputs "", so no "actual_version" is returned! This is really bad because the build number is needed for ambari to use it whenever it calls "hdp-select set <comp> <version>"
5. The ambari server code will change the state to INSTALLED.
The fix is for install_packages.py to always return the actual_version (even in the case of a failure) so that Ambari server can correct the database entry (even if the command fails/timesout). This will only happen the first time, but subsequent attempts to retry installation will use the right value so an exact match will be found in the database. 


> Install packages doesn't update actual version with build number if installation timesout on all hosts
> ------------------------------------------------------------------------------------------------------
>
>                 Key: AMBARI-12012
>                 URL: https://issues.apache.org/jira/browse/AMBARI-12012
>             Project: Ambari
>          Issue Type: Bug
>          Components: ambari-server
>    Affects Versions: 2.1.0
>            Reporter: Alejandro Fernandez
>            Assignee: Alejandro Fernandez
>             Fix For: 2.1.0
>
>
> STR:
> 1. User registers repo version 2.3.0.0 (notice that a build number was not provided), and clicks the Install button
> 2. On all of the hosts, the yum commands timeout (or does a partial install), this way, "hdp-select versions" will report that 2 versions exist (2.2.0.0-2041 and 2.3.0.0-2800). Because the install did not succeed, the command will not return the actual_version installed (which was 2.3.0.0-2800). Note: I did this by decreasing the timeouts in ambari.properties file to 5 mins, and adding a sleep in install_packages.py after the first package was installed.
> 3. The ambari server code then changes the state of the 2.3.0.0 version it knows about to INSTALL_FAILED so that the user can retry, but did not update the repo version with the actual build version that includes the build number.
> 4. User retries and this time it succeeds. However, the delta of "hdp-select versions" outputs "", so no "actual_version" is returned! This is really bad because the build number is needed for ambari to use it whenever it calls "hdp-select set <comp> <version>"
> 5. The ambari server code will change the state to INSTALLED.
> The fix is for install_packages.py to always return the actual_version (even in the case of a failure) so that Ambari server can correct the database entry (even if the command fails/timesout). This will only happen the first time, but subsequent attempts to retry installation will use the right value so an exact match will be found in the database. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)