classnotfoundexception - Error while executing wsStopApp ant task unable to instantiate class com.ibm.ws.scripting.WasxShell -


i trying execute wsstopapp ant script of websphere wsadmin scripts. code below:

<target name="was_wsstopapp">             <property name="dep_var" value="was_home" />             <antcall target="depcheck" />             <property name="dep_var" value="was_appname" />             <antcall target="depcheck" />             <taskdef name="wsstopapp" classname="com.ibm.websphere.ant.tasks.stopapplication" classpath="${was_cp}" />             <echo message="value of was_home ${was_home} , classpath ${was_cp}"/>             <wsstopapp application="${was_appname}" user="${was_user}" password="${was_password}" failonerror="${was_failonerror}" washome="${was_home}" profilename="appsrv03"/>     </target> 

all properties set in properties file. was_cp set ant script below

        <path id="was.runtime">             <fileset dir="${was_home}/lib">                     <include name="**/*.jar" />             </fileset>             <fileset dir="${was_home}/plugins">                     <include name="**/*.jar" />             </fileset>             <fileset dir="${was_home}/java/jre/lib">                     <include name="**/*.jar"/>             </fileset>     </path>     <property name="was_cp" value="${tostring:was.runtime}" /> 

i can see including given jars in class path. after executing wsstopapp target script, getting below error:

[wsstopapp] profilehome=/opt/middleware/cloudapp/websphere/85-64/profiles/appsrv03 [wsadmin] ibm class sharing adaptor not work in configuration. [wsadmin] not running on j9 java vm. [wsadmin] org.eclipse.core.runtime.coreexception: plug-in "com.ibm.ws.admin.services" unable instantiate class com.ibm.ws.scripting.wasxshell". [wsadmin]   @ org.eclipse.core.internal.registry.osgi.registrystrategyosgi.throwexception(registrystrategyosgi.java:194) [wsadmin]   @ org.eclipse.core.internal.registry.osgi.registrystrategyosgi.createexecutableextension(registrystrategyosgi.java:188) [wsadmin]   @ org.eclipse.core.internal.registry.extensionregistry.createexecutableextension(extensionregistry.java:904) [wsadmin]   @ org.eclipse.core.internal.registry.configurationelement.createexecutableextension(configurationelement.java:243) [wsadmin]   @ org.eclipse.core.internal.registry.configurationelementhandle.createexecutableextension(configurationelementhandle.java:55) ------ ------ [wsadmin] caused by: java.lang.noclassdeffounderror: com/ibm/corba/iiop/orb [wsadmin]     @ java.lang.class.forname0(native method) [wsadmin]     @ java.lang.class.forname(class.java:190) [wsadmin]     @ com.ibm.ws.util.platformhelperfactory.getbackuphelper(platformhelperfactory.jav:123) [wsadmin]     @ com.ibm.ws.util.platformhelperfactory.getplatformhelper(platformhelperfactory.java:89) [wsadmin]     @ com.ibm.ws.management.adminhelper.getplatformhelper(adminhelper.java:139 [wsadmin]     @ com.ibm.ws.scripting.abstractshell.<init>(abstractshell.java:240) [wsadmin]     @ com.ibm.ws.scripting.wasxshell.<init>(wasxshell.java:200) 

could please provide resolution? websphere version using is 8.5.

you need run script ws_ant.bat/sh provided websphere profile. works me:

<?xml version="1.0" encoding="utf-8"?> <project name="proj" default="main">         <taskdef name="wsstopapp" classname="com.ibm.websphere.ant.tasks.stopapplication"/>         <target name="main">             <wsstopapp application="testappear" user="wasadmin" password="password"/>         </target> </project> 

then call it:

c:\ibm\websphere\appserver85\profiles\appsrv01\bin>ws_ant.bat -f stopant.xml  buildfile: d:\workspacepwroc\anttest\stopant.xml  main: [wsstopapp] stopping application [testappear]...   [wsadmin] wasx7209i: connected process "server1" on node node01 using  soap connector;  type of process is: unmanagedprocess [wsstopapp] stopped application [testappear]  build successful total time: 8 seconds 

Comments

Popular posts from this blog

node.js - Mongoose: Cast to ObjectId failed for value on newly created object after setting the value -

[C++][SFML 2.2] Strange Performance Issues - Moving Mouse Lowers CPU Usage -

ios - Possible to get UIButton sizeThatFits to work? -