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


Ship it!




Ship It!

- Robert Levas


On Oct. 24, 2016, 1:16 p.m., Jonathan Hurley wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53142/
> -----------------------------------------------------------
> 
> (Updated Oct. 24, 2016, 1:16 p.m.)
> 
> 
> Review request for Ambari, Dmitro Lisnichenko, Nate Cole, and Robert Levas.
> 
> 
> Bugs: AMBARI-18684
>     https://issues.apache.org/jira/browse/AMBARI-18684
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> WebHCat may fail to restart during an upgrade due to the following exception:
> 
> {noformat}
> WARN  | 17 Oct 2016 12:53:02,999 | 
> org.eclipse.jetty.util.component.AbstractLifeCycle | FAILED 
> org.eclipse.jetty.server.Server@19a639d8: java.net.BindException: Address 
> already in use
> java.net.BindException: Address already in use
>         at sun.nio.ch.Net.bind0(Native Method)
>         at sun.nio.ch.Net.bind(Net.java:444)
>         at sun.nio.ch.Net.bind(Net.java:436)
>         at 
> sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:214)
> {noformat}
> 
> The problem seems to be caused by the failure of WebHCat to stop before being 
> upgraded. There was code added in AMBARI-12695 to address the issues with 
> WebHCat not stopping, however, it doesn't look correct.
> 
> - Return Code 0 (prevents the kill -9 from running due to {{not_if}}
> -- 
> {code}
> ! (ls /var/run/webhcat/webhcat.pid >/dev/null 2>&1 && ps -p 
> `/var/lib/ambari-agent/ambari-sudo.sh su hcat -l -s /bin/bash -c 'cat 
> /var/run/webhcat/webhcat.pid'` >/dev/null 2>&1) || ( sleep 10 && ! (ls 
> /var/run/webhcat/webhcat.pid >/dev/null 2>&1 && ps -p `ambari-sudo.sh su hcat 
> -l -s /bin/bash -c 'cat /var/run/webhcat/webhcat.pid'` >/dev/null 2>&1) )
> {code}
> 
> - Return Code 0 (prevents Fail from being raised)
> -- 
> {code}
> ! (ls /var/run/webhcat/webhcat.pid >/dev/null 2>&1 && ps -p 
> `/var/lib/ambari-agent/ambari-sudo.sh su hcat -l -s /bin/bash -c 'cat 
> /var/run/webhcat/webhcat.pid'` >/dev/null 2>&1)
> {code}
> 
> 
> Diffs
> -----
> 
>   
> ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/webhcat_service.py
>  973dd5b 
>   ambari-server/src/test/python/stacks/2.0.6/HIVE/test_webhcat_server.py 
> 683c953 
> 
> Diff: https://reviews.apache.org/r/53142/diff/
> 
> 
> Testing
> -------
> 
> Simulated various cases of missing PID, wrong PID, and sbin/webhcat_server.sh 
> not correctly stopping the daemon in order to test the behavior of the 
> Execute statements.
> 
> -----------------------------------------------------------------------
> Total run:1135
> Total errors:0
> Total failures:0
> 
> 
> Thanks,
> 
> Jonathan Hurley
> 
>

Reply via email to