You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by Andrew Onischuk <ao...@hortonworks.com> on 2015/10/01 13:37:16 UTC

Review Request 38926: HostCleanup script does not work for hosts that are manually registered

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38926/
-----------------------------------------------------------

Review request for Ambari and Vitalyi Brodetskyi.


Bugs: AMBARI-13284
    https://issues.apache.org/jira/browse/AMBARI-13284


Repository: ambari


Description
-------

Found using build #216.

1) Please confirm: When you manually register hosts, Ambari does not call to
check the hosts (and generate the .result file).  
2) If #1 is correct, that means host cleanup will not run since the result
file is not there  
3) If the result file is not there, currently the hostcleanup script fails
with the error below. Can we have it that the script instead runs the check
and generates the result so it can do the cleanup? It would prompt again "Host
Check results not found. Generate results yes/no. If no, abort" kinda thing.

    
    
    
    # python /usr/lib/python2.6/site-packages/ambari_agent/HostCleanup.py
    You have elected to remove all users as well. If it is not intended then use option --skip "users". Do you want to continue [y/n] (y)y
    Traceback (most recent call last):
    File "/usr/lib/python2.6/site-packages/ambari_agent/HostCleanup.py", line 606, in <module>
    main()
    File "/usr/lib/python2.6/site-packages/ambari_agent/HostCleanup.py", line 590, in main
    with open(hostcheckfileca, "rb") as f2:
    IOError: [Errno 2] No such file or directory: '/var/lib/ambari-agent/data/hostcheck_custom_actions.result'


Diffs
-----

  ambari-agent/src/main/python/ambari_agent/HostCleanup.py a725d43 
  ambari-server/src/main/resources/custom_actions/scripts/check_host.py 4d3cf76 

Diff: https://reviews.apache.org/r/38926/diff/


Testing
-------

mvn clean test


Thanks,

Andrew Onischuk


Re: Review Request 38926: HostCleanup script does not work for hosts that are manually registered

Posted by Vitalyi Brodetskyi <vb...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38926/#review101216
-----------------------------------------------------------

Ship it!


Ship It!

- Vitalyi Brodetskyi


On Жов. 1, 2015, 11:37 до полудня, Andrew Onischuk wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38926/
> -----------------------------------------------------------
> 
> (Updated Жов. 1, 2015, 11:37 до полудня)
> 
> 
> Review request for Ambari and Vitalyi Brodetskyi.
> 
> 
> Bugs: AMBARI-13284
>     https://issues.apache.org/jira/browse/AMBARI-13284
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> Found using build #216.
> 
> 1) Please confirm: When you manually register hosts, Ambari does not call to
> check the hosts (and generate the .result file).  
> 2) If #1 is correct, that means host cleanup will not run since the result
> file is not there  
> 3) If the result file is not there, currently the hostcleanup script fails
> with the error below. Can we have it that the script instead runs the check
> and generates the result so it can do the cleanup? It would prompt again "Host
> Check results not found. Generate results yes/no. If no, abort" kinda thing.
> 
>     
>     
>     
>     # python /usr/lib/python2.6/site-packages/ambari_agent/HostCleanup.py
>     You have elected to remove all users as well. If it is not intended then use option --skip "users". Do you want to continue [y/n] (y)y
>     Traceback (most recent call last):
>     File "/usr/lib/python2.6/site-packages/ambari_agent/HostCleanup.py", line 606, in <module>
>     main()
>     File "/usr/lib/python2.6/site-packages/ambari_agent/HostCleanup.py", line 590, in main
>     with open(hostcheckfileca, "rb") as f2:
>     IOError: [Errno 2] No such file or directory: '/var/lib/ambari-agent/data/hostcheck_custom_actions.result'
> 
> 
> Diffs
> -----
> 
>   ambari-agent/src/main/python/ambari_agent/HostCleanup.py a725d43 
>   ambari-server/src/main/resources/custom_actions/scripts/check_host.py 4d3cf76 
> 
> Diff: https://reviews.apache.org/r/38926/diff/
> 
> 
> Testing
> -------
> 
> mvn clean test
> 
> 
> Thanks,
> 
> Andrew Onischuk
> 
>