incubator-ambari-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Artem Ervits <are9...@nyp.org>
Subject RE: api questions
Date Fri, 22 Nov 2013 16:16:25 GMT
Sumit,

I tried that and I get:

curl -u usr:pw -i -X POST -d '{"host_components" : [{"HostRoles":{"component_name":"OOZIE_SERVER"}}]
}' http://ambariserver:8080/api/v1/clusters/clustername/hosts?Hosts/host_name=machinename
HTTP/1.1 409 Conflict
Set-Cookie: AMBARISESSIONID=k9e2ashgd3i4vlzq8c6l7w9k;Path=/
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Content-Type: text/plain
Content-Length: 253
Server: Jetty(7.6.7.v20120910)

{
  "status" : 409,
  "message" : "org.apache.ambari.server.controller.spi.ResourceAlreadyExistsException: Attempted
to create a host_component which already exists: [clusterName=clustername, hostName=machinename,
componentName=OOZIE_SERVER]"


And then:

curl -u usr:pw  -i -X PUT -d '{"ServiceInfo": {"state" : "INSTALLED"}}'  http://ambariserver:8080/api/v1/clusters/clustername/services/OOZIE_SERVER
                               HTTP/1.1 404 Not Found
Set-Cookie: AMBARISESSIONID=1xa5af3najngmuwjytkx6n6rt;Path=/
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Content-Type: text/plain
Content-Length: 205
Server: Jetty(7.6.7.v20120910)

{
  "status" : 404,
  "message" : "org.apache.ambari.server.controller.spi.NoSuchResourceException: The specified
resource doesn't exist: Service not found, clusterName=clustername, serviceName=OOZIE_SERVER"



From: Sumit Mohanty [mailto:smohanty@hortonworks.com]
Sent: Wednesday, November 20, 2013 7:26 PM
To: ambari-user@incubator.apache.org
Subject: Re: api questions

Looks like you can INSTALL OOZIE_SERVER directly without moving it to MAINTENANCE state as
its in the INIT state.

Step 5 at https://cwiki.apache.org/confluence/display/AMBARI/Add+a+host+and+deploy+components+using+APIs
can give you details around installing specific components.

Before you reinstall oozie, ensure that its stopped.

From: Artem Ervits <are9004@nyp.org<mailto:are9004@nyp.org>>
Reply-To: <ambari-user@incubator.apache.org<mailto:ambari-user@incubator.apache.org>>
Date: Wednesday, November 20, 2013 12:52 PM
To: "ambari-user@incubator.apache.org<mailto:ambari-user@incubator.apache.org>" <ambari-user@incubator.apache.org<mailto:ambari-user@incubator.apache.org>>
Subject: api questions

Hello all,

I was messing with Hue and inadvertenly messed up my Oozie installation. I wanted to reinstall
and got myself in a situation where I'm having trouble recovering from . Using the Ambari
API I am trying to put Oozie in maintenance mode just so I could reinstall and I am getting
the following message:

message" : "org.apache.ambari.server.controller.spi.SystemException: An internal system exception
occurred: Invalid transition for servicecomponenthost, clusterName=NYPTest, clusterId=2, serviceName=OOZIE,
componentName=OOZIE_SERVER, hostname=machine02, currentState=INIT, newDesiredState=MAINTENANCE"

If I try to use api to install the service I get:

"status" : 404,
  "message" : "org.apache.ambari.server.controller.spi.NoSuchResourceException: The specified
resource doesn't exist: Service not found,

Any hints?

This electronic message is intended to be for the use only of the named recipient, and may
contain information that is confidential or privileged. If you are not the intended recipient,
you are hereby notified that any disclosure, copying, distribution or use of the contents
of this message is strictly prohibited. If you have received this message in error or are
not the named recipient, please notify us immediately by contacting the sender at the electronic
mail address noted above, and delete and destroy all copies of this message. Thank you.

CONFIDENTIALITY NOTICE
NOTICE: This message is intended for the use of the individual or entity to which it is addressed
and may contain information that is confidential, privileged and exempt from disclosure under
applicable law. If the reader of this message is not the intended recipient, you are hereby
notified that any printing, copying, dissemination, distribution, disclosure or forwarding
of this communication is strictly prohibited. If you have received this communication in error,
please contact the sender immediately and delete it from your system. Thank You.

This electronic message is intended to be for the use only of the named recipient, and may
contain information that is confidential or privileged.  If you are not the intended recipient,
you are hereby notified that any disclosure, copying, distribution or use of the contents
of this message is strictly prohibited.  If you have received this message in error or are
not the named recipient, please notify us immediately by contacting the sender at the electronic
mail address noted above, and delete and destroy all copies of this message.  Thank you.
Mime
View raw message