VMware Communities > Developer Community > Management APIs (VI Perl, VI SDK, CIM SDK) > Discussions

This Question is Possibly Answered

1 "correct" answer available (10 pts) 2 "helpful" answers available (6 pts)
1 Replies Last post: Oct 12, 2008 11:21 PM by dkaur
Reply

java.lang.NoClassDefFoundError when trying to run SimpleClient to test java development

Oct 8, 2008 10:04 AM

Click to view jon.h's profile Lurker jon.h 2 posts since
Oct 8, 2008

Hi there,

I am new to developing and im trying to follow the sdk installation guide for java. I have set all my environment variables and am trying to run the simple client to test my setup. I keep getting the following message when running in command prompt;

I changed directory to the following as described in the instructions;

C:\>cd %SDKHOME%\samples\Axis\java\com\vmware\vimsample.classes
The system cannot find the path specified.

This wasnt fount so i changed it to...
C:\>cd %SDKHOME%\samples\Axis\java\com\vmware\

C:\devprojects\visdk21\SDK\samples\Axis\java\com\vmware>

Then input as requested...

java -Djavax.net.ssl.trustStore=c:\\VMware-Certs\vmware.keystore -Xmx1024M
com.vmware.vimsample.simpleclient.SimpleClient https://sdkpubslab-02.eng.vmware.com/sdk root
password

Which got the following error..

Exception in thread "main" java.lang.NoClassDefFoundError: com/vmware/vimsample/
simpleclient/SimpleClient

Not sure if im doing something wrong here? Can anyone help?

Reply Re: java.lang.NoClassDefFoundError when trying to run SimpleClient to test java development Oct 12, 2008 11:21 PM
Click to view dkaur's profile Hot Shot dkaur 186 posts since
Jun 1, 2007
VMware

Try cd into C:\>cd %SDKHOME%\samples\Axis\java and then run the sample as follows:

java -Djavax.net.ssl.trustStore=c:\\VMware-Certs\vmware.keystore -Xmx1024M
com.vmware.vimsample.simpleclient.SimpleClient https://sdkpubslab-02.eng.vmware.com/sdk root
password

I hope you have ensured your environment variables are set appropriately.


Actions