You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by Aravindan Vijayan <av...@hortonworks.com> on 2016/02/16 22:29:02 UTC
Review Request 43627: AMBARI-15063 : Metrics monitor fails on restart
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43627/
-----------------------------------------------------------
Review request for Ambari, Dmytro Sen, Sumit Mohanty, and Sid Wagle.
Bugs: AMBARI-15063
https://issues.apache.org/jira/browse/AMBARI-15063
Repository: ambari
Description
-------
PROBLEM
Metrics Monitor failed to START at install on 1 host. Restart also never worked.
BUG
Ambari metrics monitor startup script had a stale pid file with value as 327, and it used "ps ax -o pid | grep <pid>" to check if a monitor process is already running. The above check always returned true since there was another system process with process Id = 3327. Hence, the script assumed that the metric monitor process was already running.
FIX
Change to use grep exact match (grep -w) while checking for process with process ID.
Diffs
-----
ambari-metrics/ambari-metrics-host-monitoring/conf/unix/ambari-metrics-monitor 815b3e4
ambari-metrics/ambari-metrics-timelineservice/conf/unix/ambari-metrics-collector f83af50
Diff: https://reviews.apache.org/r/43627/diff/
Testing
-------
Manual testing done.
Thanks,
Aravindan Vijayan
Re: Review Request 43627: AMBARI-15063 : Metrics monitor fails on
restart
Posted by Aravindan Vijayan <av...@hortonworks.com>.
> On Feb. 16, 2016, 9:35 p.m., bhuvnesh chaudhary wrote:
> > ambari-metrics/ambari-metrics-host-monitoring/conf/unix/ambari-metrics-monitor, line 134
> > <https://reviews.apache.org/r/43627/diff/1/?file=1251968#file1251968line134>
> >
> > How about if the same PID number has been assigned to some other process, may be after system restart.
> > Should we also grep the process/daemon name as well?
It is a valid concern. I have fixed it.
- Aravindan
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43627/#review119360
-----------------------------------------------------------
On Feb. 16, 2016, 10:10 p.m., Aravindan Vijayan wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43627/
> -----------------------------------------------------------
>
> (Updated Feb. 16, 2016, 10:10 p.m.)
>
>
> Review request for Ambari, Dmytro Sen, Sumit Mohanty, and Sid Wagle.
>
>
> Bugs: AMBARI-15063
> https://issues.apache.org/jira/browse/AMBARI-15063
>
>
> Repository: ambari
>
>
> Description
> -------
>
> PROBLEM
> Metrics Monitor failed to START at install on 1 host. Restart also never worked.
>
> BUG
> Ambari metrics monitor startup script had a stale pid file with value as 327, and it used "ps ax -o pid | grep <pid>" to check if a monitor process is already running. The above check always returned true since there was another system process with process Id = 3327. Hence, the script assumed that the metric monitor process was already running.
>
> FIX
> Change to use grep exact match (grep -w) while checking for process with process ID.
>
>
> Diffs
> -----
>
> ambari-metrics/ambari-metrics-host-monitoring/conf/unix/ambari-metrics-monitor 815b3e4
> ambari-metrics/ambari-metrics-timelineservice/conf/unix/ambari-metrics-collector f83af50
>
> Diff: https://reviews.apache.org/r/43627/diff/
>
>
> Testing
> -------
>
> Manual testing done.
>
>
> Thanks,
>
> Aravindan Vijayan
>
>
Re: Review Request 43627: AMBARI-15063 : Metrics monitor fails on
restart
Posted by bhuvnesh chaudhary <bc...@pivotal.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43627/#review119360
-----------------------------------------------------------
ambari-metrics/ambari-metrics-host-monitoring/conf/unix/ambari-metrics-monitor (line 134)
<https://reviews.apache.org/r/43627/#comment180678>
How about if the same PID number has been assigned to some other process, may be after system restart.
Should we also grep the process/daemon name as well?
- bhuvnesh chaudhary
On Feb. 16, 2016, 9:29 p.m., Aravindan Vijayan wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43627/
> -----------------------------------------------------------
>
> (Updated Feb. 16, 2016, 9:29 p.m.)
>
>
> Review request for Ambari, Dmytro Sen, Sumit Mohanty, and Sid Wagle.
>
>
> Bugs: AMBARI-15063
> https://issues.apache.org/jira/browse/AMBARI-15063
>
>
> Repository: ambari
>
>
> Description
> -------
>
> PROBLEM
> Metrics Monitor failed to START at install on 1 host. Restart also never worked.
>
> BUG
> Ambari metrics monitor startup script had a stale pid file with value as 327, and it used "ps ax -o pid | grep <pid>" to check if a monitor process is already running. The above check always returned true since there was another system process with process Id = 3327. Hence, the script assumed that the metric monitor process was already running.
>
> FIX
> Change to use grep exact match (grep -w) while checking for process with process ID.
>
>
> Diffs
> -----
>
> ambari-metrics/ambari-metrics-host-monitoring/conf/unix/ambari-metrics-monitor 815b3e4
> ambari-metrics/ambari-metrics-timelineservice/conf/unix/ambari-metrics-collector f83af50
>
> Diff: https://reviews.apache.org/r/43627/diff/
>
>
> Testing
> -------
>
> Manual testing done.
>
>
> Thanks,
>
> Aravindan Vijayan
>
>
Re: Review Request 43627: AMBARI-15063 : Metrics monitor fails on
restart
Posted by Sid Wagle <sw...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43627/#review119361
-----------------------------------------------------------
Ship it!
Ship It!
- Sid Wagle
On Feb. 16, 2016, 9:29 p.m., Aravindan Vijayan wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43627/
> -----------------------------------------------------------
>
> (Updated Feb. 16, 2016, 9:29 p.m.)
>
>
> Review request for Ambari, Dmytro Sen, Sumit Mohanty, and Sid Wagle.
>
>
> Bugs: AMBARI-15063
> https://issues.apache.org/jira/browse/AMBARI-15063
>
>
> Repository: ambari
>
>
> Description
> -------
>
> PROBLEM
> Metrics Monitor failed to START at install on 1 host. Restart also never worked.
>
> BUG
> Ambari metrics monitor startup script had a stale pid file with value as 327, and it used "ps ax -o pid | grep <pid>" to check if a monitor process is already running. The above check always returned true since there was another system process with process Id = 3327. Hence, the script assumed that the metric monitor process was already running.
>
> FIX
> Change to use grep exact match (grep -w) while checking for process with process ID.
>
>
> Diffs
> -----
>
> ambari-metrics/ambari-metrics-host-monitoring/conf/unix/ambari-metrics-monitor 815b3e4
> ambari-metrics/ambari-metrics-timelineservice/conf/unix/ambari-metrics-collector f83af50
>
> Diff: https://reviews.apache.org/r/43627/diff/
>
>
> Testing
> -------
>
> Manual testing done.
>
>
> Thanks,
>
> Aravindan Vijayan
>
>
Re: Review Request 43627: AMBARI-15063 : Metrics monitor fails on
restart
Posted by bhuvnesh chaudhary <bc...@pivotal.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43627/#review119365
-----------------------------------------------------------
Ship it!
Ship It!
- bhuvnesh chaudhary
On Feb. 16, 2016, 10:10 p.m., Aravindan Vijayan wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43627/
> -----------------------------------------------------------
>
> (Updated Feb. 16, 2016, 10:10 p.m.)
>
>
> Review request for Ambari, Dmytro Sen, Sumit Mohanty, and Sid Wagle.
>
>
> Bugs: AMBARI-15063
> https://issues.apache.org/jira/browse/AMBARI-15063
>
>
> Repository: ambari
>
>
> Description
> -------
>
> PROBLEM
> Metrics Monitor failed to START at install on 1 host. Restart also never worked.
>
> BUG
> Ambari metrics monitor startup script had a stale pid file with value as 327, and it used "ps ax -o pid | grep <pid>" to check if a monitor process is already running. The above check always returned true since there was another system process with process Id = 3327. Hence, the script assumed that the metric monitor process was already running.
>
> FIX
> Change to use grep exact match (grep -w) while checking for process with process ID.
>
>
> Diffs
> -----
>
> ambari-metrics/ambari-metrics-host-monitoring/conf/unix/ambari-metrics-monitor 815b3e4
> ambari-metrics/ambari-metrics-timelineservice/conf/unix/ambari-metrics-collector f83af50
>
> Diff: https://reviews.apache.org/r/43627/diff/
>
>
> Testing
> -------
>
> Manual testing done.
>
>
> Thanks,
>
> Aravindan Vijayan
>
>
Re: Review Request 43627: AMBARI-15063 : Metrics monitor fails on
restart
Posted by Aravindan Vijayan <av...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43627/
-----------------------------------------------------------
(Updated Feb. 16, 2016, 10:10 p.m.)
Review request for Ambari, Dmytro Sen, Sumit Mohanty, and Sid Wagle.
Changes
-------
Fixed review issue
Bugs: AMBARI-15063
https://issues.apache.org/jira/browse/AMBARI-15063
Repository: ambari
Description
-------
PROBLEM
Metrics Monitor failed to START at install on 1 host. Restart also never worked.
BUG
Ambari metrics monitor startup script had a stale pid file with value as 327, and it used "ps ax -o pid | grep <pid>" to check if a monitor process is already running. The above check always returned true since there was another system process with process Id = 3327. Hence, the script assumed that the metric monitor process was already running.
FIX
Change to use grep exact match (grep -w) while checking for process with process ID.
Diffs (updated)
-----
ambari-metrics/ambari-metrics-host-monitoring/conf/unix/ambari-metrics-monitor 815b3e4
ambari-metrics/ambari-metrics-timelineservice/conf/unix/ambari-metrics-collector f83af50
Diff: https://reviews.apache.org/r/43627/diff/
Testing
-------
Manual testing done.
Thanks,
Aravindan Vijayan