我能够登录到我的本地WAS 8管理控制台并部署一个23MB的EAR,并且没有任何问题。但是,当我尝试使用wsadmin和这个Jython脚本进行安装时......
AdminApp.install('C:\Development\MyApp\MyApp.ear')
AdminConfig.save()
... wsadmin只是挂起。我一直在运行这个脚本超过10分钟,我的CPU在负责部署的java.exe进程上占70%。
我想使用wsadmin运行我的EAR部署/取消部署,如果可能的话,可以绕过登录管理控制台的需要。
是否有特定于wsadmin的设置我可以进行调整以使此部署成功?
编辑我
我调整了我的wsadmin调用就像这样启动它(它从DOS命令行调用......)
C:\Development\batch>call "C:\Development\WebSphere\WAS8.0\bin\wsadmin" -lang jython -conntype none -javaoption -Xms256m -Xmx1024m -f MyApp\MyAppDeploy.py
现在我收到java.lang.OutOfMemoryError ...
Exception in thread "Bundle File Closer" java.lang.OutOfMemoryError
at java.util.zip.ZipFile.close(Native Method)
java/lang/OutOfMemoryError
at java/util/zip/ZipFile.close (Native Method)
at java/util/zip/ZipFile.close (ZipFile.java:408)
at org/eclipse/osgi/baseadaptor/bundlefile/ZipBundleFile.close (ZipBundleFile.java:313)
at org/eclipse/osgi/baseadaptor/bundlefile/MRUBundleFileList.dispatchEvent (MRUBundleFileList.java:183)
at org/eclipse/osgi/framework/eventmgr/EventManager.dispatchEvent (EventManager.java:227)
at org/eclipse/osgi/framework/eventmgr/EventManager$EventThread.run (EventManager.java:337)
Exception in thread "Bundle File Closer" at Exception in thread "Thread-10" java.lang.OutOfMemoryErrorjava.lang.O
utOfMemoryError
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:156 at )
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startjava.util.zip.ZipFile(.BundleContextImpl.java
:75Exception in thread "Thread-10" java/lang/OutOfMemoryError
1closejava.lang.OutOfMemoryError
at java/util/zip/ZipFile.close (Native Method)
at java/util/zip/ZipFile.close (ZipFile.java:408)
at org/eclipse/osgi/baseadaptor/bundlefile/ZipBundleFile.close (ZipBundleFile.java:313)
at org/eclipse/osgi/baseadaptor/bundlefile/MRUBundleFileList.dispatchEvent (MRUBundleFileList.java:183)
at org/eclipse/osgi/framework/eventmgr/EventManager.dispatchEvent (EventManager.java:227)
at org/eclipse/osgi/framework/eventmgr/EventManager$EventThread.run (EventManager.java:337)
at java.nio.CharBuffer.wrap(CharBuffer.java:361)
at sun.nio.cs.StreamEncoder$CharsetSE.implWrite(StreamEncoder.java:399)
at sun.nio.cs.StreamEncoder.write(StreamEncoder.java:159)
at java.io.OutputStreamWriter.write(OutputStreamWriter.java:229)
at java.io.BufferedWriter.flushBuffer(BufferedWriter.java:122)
at java.io.PrintStream.write(PrintStream.java:500)
at java.io.PrintStream.print(PrintStream.java:643)
at com.ibm.jvm.io.ConsolePrintStream.print(ConsolePrintStream.java:java/lang/OutOfMemoryError
at java/nio/CharBuffer.wrap (CharBuffer.java:361)
at sun/nio/cs/StreamEncoder$CharsetSE.implWrite (StreamEncoder.java:399)
at sun/nio/cs/StreamEncoder.write (StreamEncoder.java:159)
at java/io/OutputStreamWriter.write (OutputStreamWriter.java:229)
at java/io/BufferedWriter.flushBuffer (BufferedWriter.java:122)
at java/io/PrintStream.write (PrintStream.java:500)
at java/io/PrintStream.print (PrintStream.java:643)
at com/ibm/jvm/io/ConsolePrintStream.print (ConsolePrintStream.java:275)
at java/io/PrintStream.append (PrintStream.java:1039)
at java/io/PrintStream.append (PrintStream.java:51)
at java/lang/StackTraceElement.appendTo (StackTraceElement.java:197)
at java/lang/StackTraceElement.appendTo (StackTraceElement.java:217)
at java/lang/StackTraceElement.appendTo (StackTraceElement.java:165)
at java/lang/Throwable.printStackTrace (Throwable.java:375)
at java/lang/Throwable.printStackTrace (Throwable.java:212)
at java/lang/ThreadGroup.uncaughtException (ThreadGroup.java:779)
at java/lang/ThreadGroup.uncaughtException (ThreadGroup.java:772)
at java/lang/Thread.uncaughtException (Thread.java:1223)
答案 0 :(得分:2)
以下为我解决了这个问题。这是从我的PC上的DOS命令行启动的。
call "C:\Development\WebSphere\WAS8.0\bin\wsadmin" -lang jython -javaoption -Xmx1024m -f %1