VMware Solutions Discussions
VMware Solutions Discussions
Hi All,
I am trying to use the RCU APIs in our virtuilization management application. I downloaded and compiled the CreateVMsInNewNFS.java API. But when I try to run this API i get an error saying
"Exception in thread "main" javax.xml.ws.WebServiceException: Failed to access the WSDL at: http://127.0.0.1:8080/rcu/api?wsdl. It failed with:
http://127.0.0.1:8080/rcu/api?wsdl.
at com.sun.xml.internal.ws.wsdl.parser.RuntimeWSDLParser.tryWithMex(Unknown Source)
at com.sun.xml.internal.ws.wsdl.parser.RuntimeWSDLParser.parse(Unknown Source)
at com.sun.xml.internal.ws.client.WSServiceDelegate.parseWSDL(Unknown Source)
at com.sun.xml.internal.ws.client.WSServiceDelegate.<init>(Unknown Source)
at com.sun.xml.internal.ws.client.WSServiceDelegate.<init>(Unknown Source)
at com.sun.xml.internal.ws.spi.ProviderImpl.createServiceDelegate(Unknown Source)
at javax.xml.ws.Service.<init>(Unknown Source)
at com.netapp.rcu.api.ApiImplService.<init>(ApiImplService.java:47)
at com.netapp.rcu.sample.CreateVmsInNewNFS.main(CreateVmsInNewNFS.java:63)
Caused by: java.io.FileNotFoundException: http://127.0.0.1:8080/rcu/api?wsdl
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
at java.net.URL.openStream(Unknown Source)
at com.sun.xml.internal.ws.wsdl.parser.RuntimeWSDLParser.createReader(Unknown Source)
at com.sun.xml.internal.ws.wsdl.parser.RuntimeWSDLParser.resolveWSDL(Unknown Source)
... 8 more"
Can anyone help me with this ? What is the api wsdl service/ and what application is support to start it ? I see that the default RCU service (NetApp VI Plugin Service) is ON. I cant understand what more I need to do to get these APIs to work.
Thanks
Amit
The path to the WSDL file does not look right. Can you hit it from your web browser?
If you have installed RCU 3.0, the path is https://<host>:61921/rcu/api?wsdl. There is information on using the SOAP API in the Admin Guide including configuring your SOAP path correctly.
No I cant hit it from a web browser either. Do you have a link to the admin guide you mentioned ?
The rapid cloning functionality is working fine from the VSphere Client UI. So I am wondering why the standalone APIs are not working. Isnt the Vsphere client using the same APIs?
Here's the direct link: http://now.netapp.com/NOW/knowledge/docs/rapid_cloning_utility/relrapidclone30/pdfs/install.pdf
RCU provides a set of SOAP APIs that invoke the same functionality as it would via the UI. It invokes a combination of NetApp ONTAP APIs as well as vSphere APIs to perform the requested action.
Hi Costea,
Thanks for the link to the document. I followed the instructions to add the Java SSL security mentioned in Appendix C. I am still not able to get it to work.
1: If I do "netstat -a" I dont see any service listening on port 61921. But there is a service on port 61922. If i try to get to it from the browser with http://host:61922/rcu/api?wsdl it displays wired symbols " "
2: In the doc in the "Launching the Rapid Cloning Utility" section I tried to follow the steps to import certificates. But when I click on the Rapid Cloning Utility icon in Vpshere it says "Cannot display webpage".
Could this mean the RCU service is not working properly ?
Thanks
Amit
I made mistake of using http instead of https in my previous reply. But even with https
https://host:61922/rcu/api?wsdl it takes me to a page with a security certificate error and if I click "Continue to this website" it displays page not found. I used the utility httpsTestUtils.jar mentioned in the installation guide to debug the situation
On running it I got error as
************************************************************************************************
c:\AmitESX>java -jar httpsTestUtil.jar
URL to test: https://sys2vcenter.elab.com:61922/rcu/api?wsdl
Ignore cert errors and debug host validation? (y/n): y
The Name passed to HostnameVerifier : sys2vcenter.elab.com (sys2vcenter.elab.com
)
sys2vcenter.elab.com resolves to (address) : 10.8.112.251
sys2vcenter.elab.com resolves to (hostname) : sys2vcenter.elab.com
The Peer Host name has been reported as: sys2vcenter.elab.com (sys2vcenter.elab.
com)
sys2vcenter.elab.com resolves to (address) : 10.8.112.251
sys2vcenter.elab.com resolves to (hostname) : sys2vcenter.elab.com
The X509 certificate CN: VSC (VSC)
WARNING unable to get inet address using VSC
HostnameVerifier FAIL: CN did not resolve to a vaild hostname.
Unable to read connection.
java.io.IOException: Server returned HTTP response code: 400 for URL: https://sy
s2vcenter.elab.com:61922/rcu/api?wsdl
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown So
urce)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(Unkn
own Source)
at com.netapp.httpsUtil.TestHttps.main(Unknown Source)
**************************************************************************************************************
Does this make any sense?? I cannot figure out what is wrong with the RCU service that i cannot access it from the java API or a web browser.
Hi Amit,
It looks like you have the wrong port number in your URL.
It should be:
https://sys2vcenter.elab.com:61921/rcu/api?wsdl
where you have
https://sys2vcenter.elab.com:61922/rcu/api?wsdl
If that isn't it, it might be that you're using the VSC, not RCU. The RCU has been merged into the Virtual Storage Console as of release 2.0 (VSC 2.0). When this occurred, the url changed slightly.
The new URL is:
https://<host>:8143/kamino/public/api?wsdl
So, you'll want to try
https://sys2vcenter.elab.com:8143/kamino/public/api?ws
When you connect with your browser, you should see something that starts like this:
<definitions targetNamespace="http://server.kamino.netapp.com/" name="ApiImplService">
<types>
<xsd:schema>
<xsd:import namespace="http://server.kamino.netapp.com/" schemaLocation="https://sys2vcenter.elab.com:8143/kamino/public/api?xsd=1"/>
I hope this helps!
Thanks for the reply Eric.
I was using port 61922 because I didnt see any service listening on port 61921. Could that be THE problem that the service itself has not started or not configured the port correctly ?
I tried out your suggestion of using the VSC url. But again I dont see any service on port 8143. there are a couple of ports viz 8244 and 8281 where I see java services running. If I use these ports in the url, I again get to the security certificate page which ends up telling me that page not found or The requested resource (/kamino/public/api) is not available
Also I checked the vsc/xml file for the version number and it is "Virtual Storage Console for VMware vSphere 1.0.09287.800"
Is there any more debugging I can do to find the issue ?
Hi Guys,
I finally managed to find the problem. I had another server with RCU installed on it and pointing to my vsphere client. So the when the RCU service on my server was starting it cudnt find port 65921 free and went to port 65925. So disabling the RCU service on the other server and restarting it on my server made it go to the default port 65921. And I was able to access it from my browser with https://sys2vcenter.elab.com:61921/rcu/api?wsdl.
Thanks for all the help and inputs with the issue.
Regards
Amit