我尝试在Windows XP上运行WLST,但始终收到java.lang.NoClassDefFoundError:
Exception in thread "main" java.lang.NoClassDefFoundError: weblogic/wlst
Caused by: java.lang.ClassNotFoundException: weblogic.wlst
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
Could not find the main class: weblogic.wlst. Program will exit.
我尝试运行* user_projects/domains/my_domain/bin/setDomainEnv.cmd *和* wlserver_10.3/server/bin/setWLSEnv.cmd *,但是没有成功,在运行 java weblogic.wlst myscript时,我总是会收到此NoClassDefFoundError。 .py 。我该怎么办?
最佳答案
调用WLST:
<WL_HOME>/common/bin/wlst.cmd myscript.py
例子:
C:/Oracle/Middleware/wlserver_10.3/common/bin/wlst.cmd myscript.py
错误的原因是,
weblogic.jar
环境变量中不存在CLASSPATH
。