> On June 26, 2016, 1:56 a.m., Jonathan Hurley wrote: > > ambari-agent/conf/unix/ambari-agent.ini, line 40 > > <https://reviews.apache.org/r/48972/diff/2/?file=1430174#file1430174line40> > > > > This is still not supportable as it's based off of a specific alert > > name. Also, it's on a per-agent basis where it should be on a > > per-definition basis. > > > > What we should be doing for this is extending the Alert Definition for > > type PORT to include this optional information.
Okay, so I'll entend alerts.json (adding an attribute to specify some command) which is in ZOOKEEPER like below: ``` (snip) "ZOOKEEPER_SERVER": [ { "name": "zookeeper_server_process", "label": "ZooKeeper Server Process", "description": "This host-level alert is triggered if the ZooKeeper server process cannot be determined to be up and listening on the network.", "interval": 1, "scope": "ANY", "source": { "type": "PORT", "uri": "{{zoo.cfg/clientPort}}", "default_port": 2181, "socket_command": "ruok", # insert this line "reporting": { (snip) ``` and update some other related codes.Thanks for suggestion. - Masahiro ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/48972/#review139466 ----------------------------------------------------------- On June 25, 2016, 1:54 p.m., Masahiro Tanaka wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/48972/ > ----------------------------------------------------------- > > (Updated June 25, 2016, 1:54 p.m.) > > > Review request for Ambari, Florian Barca, Jonathan Hurley, and Nate Cole. > > > Bugs: AMBARI-17253 > https://issues.apache.org/jira/browse/AMBARI-17253 > > > Repository: ambari > > > Description > ------- > > There are too many WARNING in ZooKeeper log. > ``` > 2016-06-15 21:02:15,405 - WARN > [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxn@357] - caught end of > stream exception > EndOfStreamException: Unable to read additional data from client sessionid > 0x0, likely client has closed socket > at > org.apache.zookeeper.server.NIOServerCnxn.doIO(NIOServerCnxn.java:228) > at > org.apache.zookeeper.server.NIOServerCnxnFactory.run(NIOServerCnxnFactory.java:208) > at java.lang.Thread.run(Thread.java:745) > ``` > > It may be because of Ambari Alert. Ambari Alert pings to the zookeeper port > to do monitoring. > We should use 'ruok' to monitor zookeepers. > > > Diffs > ----- > > ambari-agent/conf/unix/ambari-agent.ini 914e09a > ambari-agent/src/main/python/ambari_agent/AlertSchedulerHandler.py 65cc8b0 > ambari-agent/src/main/python/ambari_agent/alerts/port_alert.py 1918327 > ambari-agent/src/test/python/ambari_agent/TestAlertSchedulerHandler.py > 1202c81 > ambari-agent/src/test/python/ambari_agent/TestPortAlert.py dffa56c > > Diff: https://reviews.apache.org/r/48972/diff/ > > > Testing > ------- > > mvn clean test > > ``` > +1 overall. Here are the results of testing the latest attachment > http://issues.apache.org/jira/secure/attachment/12811835/AMBARI-17253.2.patch > against trunk revision . > +1 @author. The patch does not contain any @author tags. > +1 tests included. The patch appears to include 1 new or modified test files. > +1 javac. The applied patch does not increase the total number of javac > compiler warnings. > +1 release audit. The applied patch does not increase the total number of > release audit warnings. > +1 core tests. The patch passed unit tests in . > Test results: > https://builds.apache.org/job/Ambari-trunk-test-patch/7427//testReport/ > Console output: > https://builds.apache.org/job/Ambari-trunk-test-patch/7427//console > This message is automatically generated. > ``` > > > Thanks, > > Masahiro Tanaka > >