Created 12-05-2016 04:07 AM
Hi All,
I'm adding Grafana to Ambari .. and getting error ->
Reference link ->
Cmd run ->
curl -u admin:4o12t0n -H "X-Requested-By:ambari" -i -X POST http://sandbox.hortonworks.com:8080/api/v1/clusters/Sandbox/services/AMBARI_METRICS/components/METRI...
Error (in ambari-server.log) ->
--------------------------------------------------------------------------------------------------------
05 Dec 2016 03:52:10,815 ERROR [qtp-ambari-client-745] BaseManagementHandler:66 - Caught a runtime exception while attempting to create a resource: Trying to create a ServiceComponent not recognized in stack info, clusterName=Sandbox, serviceName=AMBARI_METRICS, componentName=METRICS_GRAFANA, stackInfo=HDP-2.4 java.lang.RuntimeException: Trying to create a ServiceComponent not recognized in stack info, clusterName=Sandbox, serviceName=AMBARI_METRICS, componentName=METRICS_GRAFANA, stackInfo=HDP-2.4 at org.apache.ambari.server.state.ServiceComponentImpl.<init>(ServiceComponentImpl.java:111) at org.apache.ambari.server.state.ServiceComponentImpl$$EnhancerByGuice$$fb135ca4.<init>(<generated>) at org.apache.ambari.server.state.ServiceComponentImpl$$EnhancerByGuice$$fb135ca4$$FastClassByGuice$$38a29767.newInstance(<generated>) at com.google.inject.internal.cglib.reflect.$FastConstructor.newInstance(FastConstructor.java:40) at com.google.inject.internal.ProxyFactory$ProxyConstructor.newInstance(ProxyFactory.java:260) at com.google.inject.internal.ConstructorInjector.construct(ConstructorInjector.java:85) at com.google.inject.internal.ConstructorBindingImpl$Factory.get(ConstructorBindingImpl.java:254) at com.google.inject.internal.InjectorImpl$4$1.call(InjectorImpl.java:978) at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1024) at com.google.inject.internal.InjectorImpl$4.get(InjectorImpl.java:974) at com.google.inject.assistedinject.FactoryProvider2.invoke(FactoryProvider2.java:632) at com.sun.proxy.$Proxy18.createNew(Unknown Source) at org.apache.ambari.server.controller.internal.ComponentResourceProvider.createComponents(ComponentResourceProvider.java:408) at org.apache.ambari.server.controller.internal.ComponentResourceProvider$1.invoke(ComponentResourceProvider.java:130) at org.apache.ambari.server.controller.internal.ComponentResourceProvider$1.invoke(ComponentResourceProvider.java:127) at org.apache.ambari.server.controller.internal.AbstractResourceProvider.invokeWithRetry(AbstractResourceProvider.java:450) at org.apache.ambari.server.controller.internal.AbstractResourceProvider.createResources(AbstractResourceProvider.java:273) at org.apache.ambari.server.controller.internal.ComponentResourceProvider.createResources(ComponentResourceProvider.java:127) at org.apache.ambari.server.controller.internal.ClusterControllerImpl.createResources(ClusterControllerImpl.java:289) at org.apache.ambari.server.api.services.persistence.PersistenceManagerImpl.create(PersistenceManagerImpl.java:76) at org.apache.ambari.server.api.handlers.CreateHandler.persist(CreateHandler.java:36) at org.apache.ambari.server.api.handlers.BaseManagementHandler.handleRequest(BaseManagementHandler.java:72) at org.apache.ambari.server.api.services.BaseRequest.process(BaseRequest.java:135) at org.apache.ambari.server.api.services.BaseService.handleRequest(BaseService.java:106) at org.apache.ambari.server.api.services.BaseService.handleRequest(BaseService.java:75) at org.apache.ambari.server.api.services.ComponentService.createComponent(ComponentService.java:137) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at com.sun.jersey.spi.container.JavaMethodInvokerFactory$1.invoke(JavaMethodInvokerFactory.java:60) at com.sun.jersey.server.impl.model.method.dispatch.AbstractResourceMethodDispatchProvider$ResponseOutInvoker._dispatch(AbstractResourceMethodDispatchProvider.java:205)
Created 12-05-2016 04:44 AM
Ambari 2.2.2, Grafana is included as a component of Ambari Metrics. However your version seems to be old "2.2.1.0"
So please upgrade your ambari to 2.2.2 and then perform the Post Upgrade task mentioned in the above link (which includes upgrading ambari-metrics RPMs. then you should be able to add the grafana.
Created 12-05-2016 04:11 AM
@Sunile Manjee, @prao - pls. let me know if you have any inputs on this ?
(I believe you've fixed this in HDP 2.5, per the link posted above)
Created 12-05-2016 04:16 AM
Can you please try opening the following URL in your browser to see if it is showing "AMBARI_METRICS" ?
http://sandbox.hortonworks.com:8080/api/v1/clusters/Sandbox/services
- Also can you please run the following command (rpm -qa | grep ambari-metrics) from the host where you want to install ambari-metrics-grafana
Example:
# rpm -qa | grep ambari-metrics ambari-metrics-grafana-2.4.1.0-22.x86_64 ambari-metrics-monitor-2.4.1.0-22.x86_64 ambari-metrics-hadoop-sink-2.4.1.0-22.x86_64
- Also please share the output of the same above command from the host where the "ambari-metrics-collector" is installed.
Created 12-05-2016 04:28 AM
@jss -
here is the output of the command
[root@sandbox ambari-server]# rpm -qa | grep ambari-metrics ambari-metrics-hadoop-sink-2.2.1.0-161.x86_64 ambari-metrics-collector-2.2.1.0-161.x86_64 ambari-metrics-monitor-2.2.1.0-161.x86_64
yes, url -
http://127.0.0.1:8080/api/v1/clusters/Sandbox/services
shows the services including AMBARI_METRICS
Created 12-05-2016 04:44 AM
Ambari 2.2.2, Grafana is included as a component of Ambari Metrics. However your version seems to be old "2.2.1.0"
So please upgrade your ambari to 2.2.2 and then perform the Post Upgrade task mentioned in the above link (which includes upgrading ambari-metrics RPMs. then you should be able to add the grafana.