WLST Help....

I have created a domain meant for developers to use on their boxes... I thought I read somewhere that you could use WLST to basically package a domain so that it can be created somewhere else, but I can't find that info again... I'd appreciate any input I can get...Thanks!

Hi Chris,
From you question i think, you want to create a template of your domain so that you can use the same template to generate the same type of domain. I dont know the exact URL to point you to, but i can tell you know what you need to do inorder to create a template of your domain
run ..\wlserver_10.0\common\bin\config_builder.cmd and point it to your existing domain folder. This will zip your domain into a template i.e. jar file and then when you use this template in configuration wizard to create a new domain instead of wlp.jar, you will be actually using using your domain template and creating a new domain similar to the existing one.
Hope this is what you want to know.
Do let me know if there is any problem
Regards
Ramesh
Regards
Ramesh

Similar Messages

  • How to create/get user & role in Weblogic 9.2 programmatically?

    Hi,
    I am new to Weblogic 9.
    I need to create a web service to manage user/role in WebLogic 9.
    Searching thru the web and found some classes like:
    AtnSecurityMgmtHelper, AtnProviderDescription etc
    Are those the correct classes to create/retrieve user & role?
    If so, what jar file contains those classes and where is the jar
    file?
    Thanks in advance,
    Terry

    You can do it with WLST help
    http://e-docs.bea.com/wls/docs92/config_scripting/config_WLS.html#wp1019913
    or via JMX through http://e-docs.bea.com/wls/docs92/javadocs/weblogic/management/security/authentication/UserEditorMBean.html and such

  • WLDF - Instrumentation for EJB call statistics

    Hello,
    I'm new with Weblogic and I'm looking for stats concerning my ejbs. I'm using weblogic 10.3.
    With JMX I have only found data concerning EJB pool size but no statistics (like execution time)
    thus, I'm looking for instrumentation using WLDF to see if it is possible to get the execution time of an EJB method.
    Firstly, I try to instrument a method, i've used the following weblogic-diagnostic.xml file.
    <wldf-resource xmlns="http://www.bea.com/ns/weblogic/90/diagnostics">
         <instrumentation>
         <enabled>true</enabled>
         <include>com.gemalto.*</include>
         <wldf-instrumentation-monitor>
         <name>ConfigurationManagerBean_Monitor</name>
    <enabled>true</enabled>
         <action>DisplayArgumentsAction</action>
    <location-type>before</location-type>
    <pointcut>execution(public * com.xxx.* get*(...))</pointcut>
         </wldf-instrumentation-monitor>
         </instrumentation>
    </wldf-resource>
    When I put this file into my MEAT-INF EAR, the deploying is OK but I'cant see nothing into WLDF console extension ?
    Could you please explain me a little bit how to configure correctly my instrumentation ?
    Thank you a lot.
    C.

    When I put this file into my MEAT-INF EAR, the deploying is OK but I'cant see nothing into WLDF console extension ?Are there events in the WLDF Archive for the deployed monitor? Have you enabled Instrumentation through a WLDF System Resource targeted to the server?
    In order to view instrumentation data through the console extension,
    - the WLDF DyeInjection monitor needs to be deployed through the WLDF SystemResouce at server scope as well.
    - the application monitors must be of the "Around" type with the TraceElapsedTimeAction assigned to them
    Then the console extension can build a call-tree of known requests that have passed through the server, based on each request's Diagnostic Context ID.
    If you truly want to view information from the DisplayArgumentsAction, you will need to view the data stored in the WLDF Archive using the WLS Console, or WLST. In the Console, you can view the data by navigating to Diagnostic Modules -> Logs and selecting the EventsDataArchive "log". On the resulting page you can customize your views (the default view only shows you the last 5 minutes of data in the archive, I believe).
    Using WLST you can use the exportDiagnosticData (offline) or exportDiagnosticDataFromServer (online) functions. See the WLST help on these functions for details on how to use them.
    Mike

  • Using WLST with ant. Need help

    I try to create ant task which connects to WLST engine and creates datasource.
    This is build.xml :
    +<?xml version="1.0" ?>+
    +<project name="deploy" default="connect" basedir=".">+
    +<echo> ${wl.home} </echo>+
    +<path id="wl.appc.classpath">+
    +<pathelement location="${wl.home}/server/lib/weblogic.jar"/>+
    +</path>+
    +<taskdef name="wlst" classpathref="wl.appc.classpath" classname="weblogic.ant.taskdefs.management.WLSTTask" />+
    +<target name="connect">+
    +<wlst executescriptbeforefile="true" debug="false">+
    +<script>+
    connect('weblogic','weblogic','t3://localhost:7001')
    +</script>+
    +</wlst>+
    +</target>+
    +</project>+
    Running this is script I'm getting the following error:
    Buildfile: c:\wl-ds.xml
    [echo] C:/Oracle/Middleware11.1.1.4/wlserver_10.3
    connect:
    [wlst] java.lang.NoClassDefFoundError: weblogic/management/scripting/WLSTInterpreterInvoker
    [wlst] Caused by: java.lang.ClassNotFoundException: weblogic.management.scripting.WLSTInterpreterInvoker
    [wlst] at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
    [wlst] at java.security.AccessController.doPrivileged(Native Method)
    [wlst] at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
    [wlst] at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
    [wlst] at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
    [wlst] at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
    [wlst] at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
    [wlst] Could not find the main class: weblogic.management.scripting.WLSTInterpreterInvoker. Program will exit.
    [wlst] Exception in thread "main"
    BUILD FAILED
    c:\wl-ds.xml:12: Java returned: 1
    Ant founds weblogic.ant.taskdefs.management.WLSTTask but in some reasons cannot find weblogic.management.scripting.WLSTInterpreterInvoker, although they both placed in the weblogic.jar
    I can't understand what I do wrong! Please, help or advice what to do...
    Edited by: creed on 03.03.2011 20:55

    Hi,
    Just wanted to check if the issue was resolved, I have the same issue , Below is the details of the error i get when i try jay's script
    Apache Ant version 1.8.0 compiled on February 1 2010
    Trying the default build file: build.xml
    Buildfile: D:\anttest\build.xml
    Adding reference: ant.PropertyHelper
    Detected Java version: 1.6 in: D:\SYS\JAVA\jdk1.6.0_21\jre
    Detected OS: Windows Server 2008
    Adding reference: ant.ComponentHelper
    Setting ro project property: ant.file -> D:\anttest\build.xml
    Setting ro project property: ant.file.type -> file
    Adding reference: ant.projectHelper
    Adding reference: ant.parsing.context
    Adding reference: ant.targets
    parsing buildfile D:\anttest\build.xml with URI = file:/D:/anttest/build.xml
    Setting ro project property: ant.project.name -> deploy
    Adding reference: deploy
    Setting ro project property: ant.project.default-target -> run
    Setting ro project property: ant.file.deploy -> D:\anttest\build.xml
    Setting ro project property: ant.file.type.deploy -> file
    Project base dir set to: D:\anttest
    +Target:
    +Target: connect
    +Target: run
    Adding reference: ant.LocalProperties
    parsing buildfile jar:file:/D:/SYS/apache-ant-1.8.0/lib/ant.jar!/org/apache/tools/ant/antlib.xml with URI = jar:file:/D:/SYS/apache-ant-1.8.0/lib/ant.jar!/org/apache/tools/ant/antlib.xml from a zip file
    Setting project property: wl.home -> D:\SYS\Weblogic1034\wlserver_10.3
    Adding reference: wl.classpath
    fileset: Setup scanner in dir D:\SYS\Weblogic1034\wlserver_10.3\server\lib with patternSet{ includes: [*.jar] excludes: [] }
    Finding class weblogic.ant.taskdefs.management.WLSTTask
    Loaded from D:\SYS\Weblogic1034\wlserver_10.3\server\lib\weblogic.jar weblogic/ant/taskdefs/management/WLSTTask.class
    Class org.apache.tools.ant.taskdefs.Java loaded from parent loader (parentFirst)
    Class weblogic.ant.taskdefs.management.WLSTTask loaded from ant loader (parentFirst)
    Class java.lang.Object loaded from parent loader (parentFirst)
    Class java.lang.Throwable loaded from parent loader (parentFirst)
    Class org.apache.tools.ant.BuildException loaded from parent loader (parentFirst)
    Class java.lang.Exception loaded from parent loader (parentFirst)
    Class java.lang.IllegalStateException loaded from parent loader (parentFirst)
    Class java.io.Reader loaded from parent loader (parentFirst)
    Class java.io.StringReader loaded from parent loader (parentFirst)
    Class java.lang.String loaded from parent loader (parentFirst)
    Class java.io.IOException loaded from parent loader (parentFirst)
    Class java.io.OutputStream loaded from parent loader (parentFirst)
    Class java.io.FileOutputStream loaded from parent loader (parentFirst)
    +Datatype wlst weblogic.ant.taskdefs.management.WLSTTask
    Setting ro project property: ant.project.invoked-targets -> run
    Attempting to create object of type org.apache.tools.ant.helper.DefaultExecutor
    Adding reference: ant.executor
    Build sequence for target(s) `run' is [connect, run]
    Complete build sequence is [connect, run, ]
    connect:
    [echo] WebLogic Home is : D:\SYS\Weblogic1034\wlserver_10.3
    Class org.apache.tools.ant.types.Path loaded from parent loader (parentFirst)
    Finding class weblogic.ant.taskdefs.management.WLSTScript
    Loaded from D:\SYS\Weblogic1034\wlserver_10.3\server\lib\weblogic.jar weblogic/ant/taskdefs/management/WLSTScript.class
    Class org.apache.tools.ant.Task loaded from parent loader (parentFirst)
    Class weblogic.ant.taskdefs.management.WLSTScript loaded from ant loader (parentFirst)
    Class java.lang.Boolean loaded from parent loader (parentFirst)
    Class java.lang.StringBuilder loaded from parent loader (parentFirst)
    Class org.apache.tools.ant.types.Commandline$Argument loaded from parent loader (parentFirst)
    Class org.apache.tools.ant.util.FileUtils loaded from parent loader (parentFirst)
    Class java.io.PrintWriter loaded from parent loader (parentFirst)
    Class java.io.LineNumberReader loaded from parent loader (parentFirst)
    Finding class weblogic.utils.StringUtils
    Loaded from D:\SYS\Weblogic1034\modules\com.bea.core.utils_1.9.0.0.jar weblogic/utils/StringUtils.class
    Class weblogic.utils.StringUtils loaded from ant loader (parentFirst)
    Class java.lang.SecurityException loaded from parent loader (parentFirst)
    Class java.lang.NoSuchMethodException loaded from parent loader (parentFirst)
    Finding class weblogic.utils.StringUtils$StringMaker
    Loaded from D:\SYS\Weblogic1034\modules\com.bea.core.utils_1.9.0.0.jar weblogic/utils/StringUtils$StringMaker.class
    Class weblogic.utils.StringUtils$StringMaker loaded from ant loader (parentFirst)
    Finding class weblogic.utils.StringUtils$ReflectedStringMaker
    Loaded from D:\SYS\Weblogic1034\modules\com.bea.core.utils_1.9.0.0.jar weblogic/utils/StringUtils$ReflectedStringMaker.class
    Class weblogic.utils.StringUtils$ReflectedStringMaker loaded from ant loader (parentFirst)
    Class java.lang.Class loaded from parent loader (parentFirst)
    Class java.lang.Integer loaded from parent loader (parentFirst)
    Class java.lang.reflect.Constructor loaded from parent loader (parentFirst)
    Class java.lang.reflect.InvocationTargetException loaded from parent loader (parentFirst)
    Class java.lang.IllegalAccessException loaded from parent loader (parentFirst)
    Class java.lang.InstantiationException loaded from parent loader (parentFirst)
    Class java.lang.RuntimeException loaded from parent loader (parentFirst)
    Class java.lang.Character loaded from parent loader (parentFirst)
    Class java.io.File loaded from parent loader (parentFirst)
    Class org.apache.tools.ant.types.CommandlineJava loaded from parent loader (parentFirst)
    [wlst] Executing 'D:\SYS\JAVA\jdk1.6.0_21\jre\bin\java.exe' with arguments:
    [wlst] '-Ddebug=false'
    [wlst] '-DfailOnError=true'
    [wlst] '-DexecuteScriptBeforeFile=true'
    [wlst] '-DscriptTempFile=C:\Users\Administrator\AppData\Local\Temp\2\wlsttempfile214271013.py'
    [wlst] '-classpath'
    [wlst] 'D:\SYS\apache-ant-1.8.0\lib\ant-launcher.jar;D:\SYS\apache-ant-1.8.0\lib\ant-antlr.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-bcel.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-bsf.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-log4j.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-oro.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-regexp.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-resolver.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-xalan2.jar;D:\SYS\apache-ant-1.8.0\lib\ant-commons-logging.jar;D:\SYS\apache-ant-1.8.0\lib\ant-commons-net.jar;D:\SYS\apache-ant-1.8.0\lib\ant-jai.jar;D:\SYS\apache-ant-1.8.0\lib\ant-javamail.jar;D:\SYS\apache-ant-1.8.0\lib\ant-jdepend.jar;D:\SYS\apache-ant-1.8.0\lib\ant-jmf.jar;D:\SYS\apache-ant-1.8.0\lib\ant-jsch.jar;D:\SYS\apache-ant-1.8.0\lib\ant-junit.jar;D:\SYS\apache-ant-1.8.0\lib\ant-netrexx.jar;D:\SYS\apache-ant-1.8.0\lib\ant-nodeps.jar;D:\SYS\apache-ant-1.8.0\lib\ant-stylebook.jar;D:\SYS\apache-ant-1.8.0\lib\ant-swing.jar;D:\SYS\apache-ant-1.8.0\lib\ant-testutil.jar;D:\SYS\apache-ant-1.8.0\lib\ant-trax.jar;D:\SYS\apache-ant-1.8.0\lib\ant.jar;D:\SYS\apache-ant-1.8.0\lib\xercesImpl.jar;D:\SYS\apache-ant-1.8.0\lib\xml-apis.jar;D:\SYS\JAVA\jdk1.6.0_21\lib\tools.jar'
    [wlst] 'weblogic.management.scripting.WLSTInterpreterInvoker'
    [wlst]
    [wlst] The ' characters around the executable and arguments are
    [wlst] not part of the command.
    [wlst] Using input " "
    Execute:Java13CommandLauncher: Executing 'D:\SYS\JAVA\jdk1.6.0_21\jre\bin\java.exe' with arguments:
    '-Ddebug=false'
    '-DfailOnError=true'
    '-DexecuteScriptBeforeFile=true'
    '-DscriptTempFile=C:\Users\Administrator\AppData\Local\Temp\2\wlsttempfile214271013.py'
    '-classpath'
    'D:\SYS\apache-ant-1.8.0\lib\ant-launcher.jar;D:\SYS\apache-ant-1.8.0\lib\ant-antlr.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-bcel.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-bsf.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-log4j.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-oro.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-regexp.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-resolver.jar;D:\SYS\apache-ant-1.8.0\lib\ant-apache-xalan2.jar;D:\SYS\apache-ant-1.8.0\lib\ant-commons-logging.jar;D:\SYS\apache-ant-1.8.0\lib\ant-commons-net.jar;D:\SYS\apache-ant-1.8.0\lib\ant-jai.jar;D:\SYS\apache-ant-1.8.0\lib\ant-javamail.jar;D:\SYS\apache-ant-1.8.0\lib\ant-jdepend.jar;D:\SYS\apache-ant-1.8.0\lib\ant-jmf.jar;D:\SYS\apache-ant-1.8.0\lib\ant-jsch.jar;D:\SYS\apache-ant-1.8.0\lib\ant-junit.jar;D:\SYS\apache-ant-1.8.0\lib\ant-netrexx.jar;D:\SYS\apache-ant-1.8.0\lib\ant-nodeps.jar;D:\SYS\apache-ant-1.8.0\lib\ant-stylebook.jar;D:\SYS\apache-ant-1.8.0\lib\ant-swing.jar;D:\SYS\apache-ant-1.8.0\lib\ant-testutil.jar;D:\SYS\apache-ant-1.8.0\lib\ant-trax.jar;D:\SYS\apache-ant-1.8.0\lib\ant.jar;D:\SYS\apache-ant-1.8.0\lib\xercesImpl.jar;D:\SYS\apache-ant-1.8.0\lib\xml-apis.jar;D:\SYS\JAVA\jdk1.6.0_21\lib\tools.jar'
    'weblogic.management.scripting.WLSTInterpreterInvoker'
    The ' characters around the executable and arguments are
    not part of the command.
    [wlst] java.lang.NoClassDefFoundError: weblogic/management/scripting/WLSTInterpreterInvoker
    [wlst] Caused by: java.lang.ClassNotFoundException: weblogic.management.scripting.WLSTInterpreterInvoker
    [wlst] at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
    [wlst] at java.security.AccessController.doPrivileged(Native Method)
    [wlst] at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
    [wlst] at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
    [wlst] at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
    [wlst] at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
    [wlst] Could not find the main class: weblogic.management.scripting.WLSTInterpreterInvoker. Program will exit.
    [wlst] Exception in thread "main"

  • Help creating project specific ALSB Customization file using WLST

    I asked this question in August in another forum and was redirected here, but never followed up. I'm hopeful someone has done this...
    Is it possible to create an ALSB CUstomization file for a single project using WLST?
    If so, does anyone have an example they would be wiling to share. I've been beating my head against the wall for almost 2 days (well, months now...) , and I'm REALLy starting to get a headache from it now....
    We're running WLS 9.2 MP2 and ALSB 2.6 RP1
    Any help is greatly appreciated,
    Brian

    Brian, OSB specific questions are best directed in the SOA Suite forum:
    SOA Suite
    It looks like there is an ALSBConfigurationMBean with a customize method, but I have not worked with it and it does not sound like that will give you precisely what you want:
    http://edocs.bea.com/alsb/docs261/javadoc/com/bea/wli/sb/management/configuration/ALSBConfigurationMBean.html#customize(java.util.List)

  • Exception when running WLST in Eclipse - Please Help!!!

    Hello,
    I am trying to get get a WLST online connection via a java class, but I am getting an exception when trying to connect to an admin server instance:
    <br>
    <br><b>javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
         java.io.EOFException]
         at weblogic.jrmp.Context.lookup(Context.java:189)
         at weblogic.jrmp.Context.lookup(Context.java:195)
         at javax.naming.InitialContext.lookup(InitialContext.java:351)
         at weblogic.management.scripting.WLSTHelper.initDeprecatedConnection(WLSTHelper.java:546)
         at weblogic.management.scripting.WLSTHelper.initConnections(WLSTHelper.java:285)
    <br>
    <br>
    The CompatabilityMBeanServer is not initialized properly. This might happen if the CompatabilityMBeanServer is disabled via the JMXMBean.To view the real exception use dumpStack()
    WLST detected that the RuntimeMBeanServer is not enabled. This might
    happen if the RuntimeMBeanServer is disabled via the JMXMBean.
    Please ensure that this MBeanServer is enabled. Online WLST cannot function
    without this MBeanServer.</b>
    <br>
    <br>
    I am basically trying to run the following WLST command in java:
    <b>connect('weblogic','weblogic','t3://localhost:7201')</b>
    <br>
    <br>
    Here is the java block that I call to create the connection with the WLSTIterpreter:
    <br>
    <br>
    <b>StringBuffer buffer = new StringBuffer();
    buffer.append("connect('weblogic','weblogic','t3://localhost:7201')\n");     System.out.println(buffer.toString());
    <br>
    INTERPRETER.exec(buffer.toString());</b>
    <br>
    <br>
    My admin server is running at this address and the CompatabilityMBeanServer is enabled. The strange thing this is that I am able to run the WLST via the command line and the connection is successful with no problems. This leads me to believe that there is something wrong with my classpath/environment that I have setup in Eclipse but I am not sure.
    Any ideas on where I went wrong??? Please help!
    Thanks :)
    PS. I am running WebLogic 9.1 and java 150_06
    Message was edited by:
    rogaljo

    I also have a similar issue (JNDI lookup works on the command line but not in Eclipse).
    I posted another topic regarding this today with the title:
    "CommunicationException ..."
    In the groups:
    weblogic...jndi
    weblogic...jdbc

  • Urgent help need to solve wlst  RuntimeMBeanServer is not enabled

    I am using wlst to connect to a osb but I am getting the following errors:
    How can enable RuntimeMBeanServer using the console ?
    [wlst] The CompatabilityMBeanServer is not initialized properly.
    [wlst] This might happen if the CompatabilityMBeanServer is
    [wlst] disabled via the JMXMBean.
    [wlst]
    [wlst] To view the root cause exception use dumpStack()
    [wlst] WLST detected that the RuntimeMBeanServer is not enabled. This
    [wlst] might happen if the RuntimeMBeanServer is disabled via the JMXMBean.
    [wlst] Please ensure that this MBeanServer is enabled. Online WLST cannot
    [wlst] function without this MBeanServer.
    [wlst] Traceback (innermost last):
    [wlst] File "/tmp/wlsttempfile1273502167.py", line 8, in ?
    [wlst] File "<iostream>", line 22, in connect
    [wlst] File "<iostream>", line 646, in raiseWLSTException
    [wlst] WLSTException: Error occured while performing connect : "Cannot connect to WLST."
    [wlst] Use dumpStack() to view the full stacktrace
    [wlst] Exception in thread "main" java.lang.IllegalStateException: Traceback (innermost last):
    [wlst] File "/tmp/wlsttempfile1273502167.py", line 8, in ?
    [wlst] File "<iostream>", line 22, in connect
    [wlst] File "<iostream>", line 646, in raiseWLSTException
    [wlst] WLSTException: Error occured while performing connect : "Cannot connect to WLST."
    [wlst] Use dumpStack() to view the full stacktrace
    [wlst]      at weblogic.management.scripting.WLSTInterpreterInvoker.printError(WLSTInterpreterInvoker.java:110)
    [wlst]      at weblogic.management.scripting.WLSTInterpreterInvoker.executePyScript(WLSTInterpreterInvoker.java:103)
    [wlst]      at weblogic.management.scripting.WLSTInterpreterInvoker.main(WLSTInterpreterInvoker.java:27)
    [wlst] Java Result: 1

    N Gasparotto wrote:
    bsac14 wrote:
    my database is in no archive mode
    can you please tell how to restore
    yes it is a datafile corruptionYou did not say how you defined that's a datafile corruption. You provide minimum to zero information.
    I just need to bring the database up,no need any exact data
    I can refresh from prod laterThen drop and recreate database. Basically and since you are not in archive mode, no recover is possible. Period.
    Nicolas.Hi,
    How did you come to the conclusion that your datafile is corrupted? Can you provide and supported logs?
    Regards .....

  • Need Help regarding wlst script

    Hi
    I am new to wlst scripting, I need to know how to add error handling in below script and how to unlock the invoke in case of error.
    below is the script
    connect(userConfigFile=str(gConfigFile), userKeyFile=str(gKeyFile), url=str(gAdminHost) + ':' + str(gAdminPort));
    print 'Connecting to Domain ...'
    domainCustom()
    cd ('oracle.biee.admin')
    print 'Connecting to BIDomain MBean ...'
    cd ('oracle.biee.admin:type=BIDomain,group=Service')
    objs = jarray.array([], java.lang.Object)
    strs = jarray.array([], java.lang.String)
    invoke('lock', objs, strs)
    cd ('..')
    cd ('oracle.biee.admin:type=BIDomain.BIInstance.ServerConfiguration,biInstance=coreapplication,group=Service')
    objs=jarray.array([newRPDlocation,newRPDpassword],Object)
    strs=jarray.array(['java.lang.String', 'java.lang.String'],String)
    invoke('uploadRepository', objs, strs)
    cd ('..')
    cd ('oracle.biee.admin:type=BIDomain,group=Service')
    objs = jarray.array([], java.lang.Object)
    strs = jarray.array([], java.lang.String)
    invoke('commit', objs, strs)
    disconnect()
    exit()
    Thanks
    Samit Baghla

    A handy link - http://docs.python.org/2/tutorial/errors.html
    An example (taken from - Middleware Snippets: Automate WebLogic 12.1.2 Deployment)
    def createFile(directory_name, file_name, content):
         dedirectory = java.io.File(directory_name);
         defile = java.io.File(directory_name + '/' + file_name);
         writer = None;
         try:
              dedirectory.mkdirs();
              defile.createNewFile();
              writer = java.io.FileWriter(defile);
              writer.write(content);
         finally:
              try:
                   print 'WRITING FILE ' + file_name;
                   if writer != None:
                        writer.flush();
                        writer.close();
              except java.io.IOException, e:
                   e.printStackTrace();

  • Help Needed with wlst distributeApplication and deploy weblogic 10x

    Looking for help on missing steps...
    Trying to distribute an application .war from one host (adminServer host) to all cluster members.
    I first distribute the app which appears to work:
    PackagePath = '/opt/wls/domain1/deploy/app1.war
    clusterName= 'SomeCluster'
    myapp = 'app1'
    distributeApplication(PackagePath, targets=clusterName)
    I then execute a deploy cmd, pointing to where the distributed application should be on each host:
    deploy(myapp, PackagePath, targets=clusterName)
    At this point everything completes without error, but on the admin Server console I see two deploys now for app1:
    1. app1 is deployed and active
    2. app1.war is deployed in Prepared state with the status as distribute Defferred.
    Im guessing #2 is there from the distributeApplication call... how do I deploy the app after executing the distributeApplication call?
    Thanks
    Edited by: user9253444 on Jul 29, 2010 5:29 AM

    Ok, so it looks like I only need to call a startapplicaiton after the distribute to make this work.

  • Creation of Customisation file from WLST Script in OSB

    Hi,
    Please help in creating Customisation file in OSB from WLST Scripts

    Hi,
    Please refer -
    Create Customization File in OSB 10g with WLST script
    http://download.oracle.com/docs/cd/E13159_01/osb/docs10gr3/deploy/config_appx.html
    http://download.oracle.com/docs/cd/E13159_01/osb/docs10gr3/javadoc/com/bea/wli/config/customization/Customization.html
    Regards,
    Anuj

  • Problem with WLST in weblogic application server 10.3 on solaris 10 x86

    Hi Friends, I installed Sun Solaris 10 on my desktop x86. I am able to install oracle weblogic application server 10.3.
    I created one domain and I am trying to start AdminServer on that using WLST command.
    Before that , I started the admin server from command as normal start ( nohup ./startWebLogic.sh &) and the server started perfectly alright. After that I was trying to open admin console in firefox browser. It was opening perfectly alright.
    Now I stopped the server and checked no processes which are related to weblogic were running , and then initialized the WLST environment using the script "wlst.sh" , which is at (in my system) /usr/bea/wlserver_10.3/common/bin/wlst.sh. Now the environment had been set and the WLST offline prompt came up.
    Now I used the below WLST scirpt command
    startServer('AdminServer','mydomain','t3://localhost:7001','weblogic','weblogic1');
    and the server started perfectly alright, now what I did was , I started admin console at FireFox browser , it prompted me to enter user name and password , I gave them , and once the login is done, then in my shell window , I am seeing error as
    **wls:/offline> WLST-WLS-1263965848154: <Jan 19, 2010 11:39:24 PM CST> <Error> <HTTP> <BEA-101017> <[ServletContext@28481438[app:consoleapp module:console path:/console spec-version:2.5]] Root cause of ServletException.**
    **WLST-WLS-1263965848154: java.lang.OutOfMemoryError: PermGen space**
    **WLST-WLS-1263965848154: at java.lang.ClassLoader.defineClass1(Native Method)**
    **WLST-WLS-1263965848154: at java.lang.ClassLoader.defineClass(ClassLoader.java:616)**
    **WLST-WLS-1263965848154: at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)**
    **WLST-WLS-1263965848154: at weblogic.utils.classloaders.GenericClassLoader.defineClass(GenericClassLoader.java:344)**
    **WLST-WLS-1263965848154: at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:301)**
    **WLST-WLS-1263965848154: Truncated. see log file for complete stacktrace**
    **WLST-WLS-1263965848154: >**
    **WLST-WLS-1263965848154: <Jan 19, 2010 11:39:24 PM CST> <Error> <JMX> <BEA-149500> <An exception occurred while registering the MBean com.bea:Name=mydomain,Type=SNMPAgentRuntime.**
    **WLST-WLS-1263965848154: java.lang.OutOfMemoryError: PermGen space**
    **WLST-WLS-1263965848154: at java.lang.ClassLoader.defineClass1(Native Method)**
    **WLST-WLS-1263965848154: at java.lang.ClassLoader.defineClass(ClassLoader.java:616)**
    **WLST-WLS-1263965848154: at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)**
    **WLST-WLS-1263965848154: at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)**
    **WLST-WLS-1263965848154: at java.net.URLClassLoader.access$000(URLClassLoader.java:56)**
    **WLST-WLS-1263965848154: Truncated. see log file for complete stacktrace**
    **WLST-WLS-1263965848154: >**
    **WLST-WLS-1263965848154: Exception in thread "[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'" java.lang.OutOfMemoryError: PermGen space**
    So I thought I have less memory consuming for this weblogic admin server and opened up ,
    _/usr/bea/wlserver_10.3/common/bin/commEnv.sh_
    and changed the memory arguments as
    Sun)
    JAVA_VM=-server
    MEM_ARGS="-Xms1024m -Xmx1024m -XX:MaxPermSize=1024m" <---- previously these were 32m and 200m and MaxPermSize
    and also in /usr/bea/wlserver10.3/common/bin/bin/setDomainEnv.sh_
    and in this file also I changed the memory arguments as
    *if [ "${JAVA_VENDOR}" = "Sun" ] ; then*
    *WLS_MEM_ARGS_64BIT="-Xms256m -Xmx512m"*
    *export WLS_MEM_ARGS_64BIT*
    *WLS_MEM_ARGS_32BIT="-Xms1024m -Xmx1024m"*
    *export WLS_MEM_ARGS_32BIT*
    and restarted the server using the WLST command and again tried to open the admin console on a browser, same error is showing.
    (1) Environment : Sun Solaris x86
    (2) JDK : sun jdk 1.6._17
    Please help me what I am doing wrong here and please let me know the solution.
    I was trying to install jrockit 1.6 on this since my OS is sun solaris X86 , there is no compatible jrockit version is not there.
    Thanks a lot
    Peter

    Hi Peter,
    As you have mentioned in your Post that
    MEM_ARGS="-Xms1024m -Xmx1024m -XX:MaxPermSize=1024m" <---- previously these were 32m and 200m and MaxPermSize
    The Setting you have provided is wrong ...that is the reason you are gettingjava.lang.OutOfMemoryError: PermGen space. There is a RRation between PermSize and the maximum Heap Size...
    Just a Bit Explaination:
    Formula:
    (OS Level)Process Size = Java Heap (+) Native Space (+) (2-3% OS related Memory)
    PermSize : It's a Netive Memory Area Outside of the Heap, Where ClassLoading kind of things happens. In an operating System like Windows Default Process Size is 2GB (2048MB) default (It doesnt matter How much RAM do u have 2GB or 4GB or more)...until we dont change it by setting OS level parameter to increase the process size..Usually in OS like Solaris/Linux we get 4GB process size as well.
    Now Lets take the default Process Size=2GB (Windows), Now As you have set the -Xmx512M, we can assume that rest of the memory 1536 Mb is available for Native codes.
    (ProcessSize - HeapSize) = Native (+) (2-3% OS related Memory)
    2048 MB - 512 MB = 1536 MB
    THUMB RULES:
    <h3><font color=red>
    MaxPermSize = (MaxHeapSize/3) ----Very Special Cases
    MaxPermSize = (MaxHeapSize/4) ----Recommended
    </font></h3>
    In your Case -Xmx (Max Heap Size) and -XX:MaxPermSize both were same ....That is the reason you are getting unexpected results. These should be in proper ration.
    What should be the exact setting of these parameters depends on the Environment /Applications etc...
    But Just try -Xmx1024m -Xms1024m -XX:MaxPermSize256m
    Another recommendation for fine tuning always keep (Xmx MaxHeapSize & Xms InitialHeapSize same).
    Thanks
    Jay SenSharma
    http://jaysensharma.wordpress.com (WebLogic Wonders Are Here)
    Edited by: Jay SenSharma on Jan 20, 2010 5:33 PM

  • Built-in wlst ant task does not work in weblogic 10.3.1

    Hi,
    We have an installer script that deploys an ear file to a weblogic managed server. The script also invokes the build-tin wlst ant task to bounce the managed server. However, in version 10.3.1 the wlst task seems to be broken. I get this error:
    [echo] [wlst] sys-package-mgr: can't create package cache dir, '/u00/webadmin/product/10.3.1/WLS/wlserver_10.3/server/lib/weblogic.jar/./java
    tmp/wlstTemp/packages'
    [echo] [wlst] java.io.IOException: No such file or directory
    [echo] [wlst] at java.io.UnixFileSystem.createFileExclusively(Native Method)
    [echo] [wlst] at java.io.File.checkAndCreate(File.java:1704)
    [echo] [wlst] at java.io.File.createTempFile(File.java:1792)
    [echo] [wlst] at java.io.File.createTempFile(File.java:1828)
    [echo] [wlst] at com.bea.plateng.domain.script.jython.WLST_offline.getWLSTOfflineInitFilePath(WLST_offline.java:240)
    [echo] [wlst] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    [echo] [wlst] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    [echo] [wlst] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    [echo] [wlst] at java.lang.reflect.Method.invoke(Method.java:597)
    [echo] [wlst] at weblogic.management.scripting.utils.WLSTUtil.getOfflineWLSTScriptPath(WLSTUtil.java:63)
    [echo] [wlst] at weblogic.management.scripting.utils.WLSTUtil.setupOffline(WLSTUtil.java:214)
    [echo] [wlst] at weblogic.management.scripting.utils.WLSTInterpreter.<init>(WLSTInterpreter.java:133)
    [echo] [wlst] at weblogic.management.scripting.utils.WLSTInterpreter.<init>(WLSTInterpreter.java:75)
    [echo] [wlst] at weblogic.ant.taskdefs.management.WLSTTask.execute(WLSTTask.java:103)
    [echo] [wlst] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
    Obviously that is not a valid directory...so I am wondering what it is trying to do, and why. The wlst task worked perfectly in 10.3.0. No changes were made when attempting to run the script against 10.3.0 and 10.3.1, which tells me that something is different with the 10.3.1 setup. Here is the ant code I am running:
    <target name="init-taskdefs">
    <taskdef resource="net/sf/antcontrib/antcontrib.properties">
    <classpath>
    <pathelement location="ant-ext/ant-contrib.jar" />
    </classpath>
    </taskdef>
    <taskdef name="wldeploy" classname="weblogic.ant.taskdefs.management.WLDeploy" />
    <taskdef name="wlst" classname="weblogic.ant.taskdefs.management.WLSTTask" />
    </target>
    <macrodef name="wlShutdownServer">
    <attribute name="adminUser" default="${deploy.admin.username}" />
    <attribute name="adminPassword" default="${deploy.admin.password}" />
    <attribute name="adminUrl" default="${deploy.admin.url}" />
    <attribute name="serverTarget" />
    <sequential>
    <trycatch property="server.error">
    <try>
    <wlst failonerror="true"
    arguments="@{adminUser} @{adminPassword} @{adminUrl} @{serverTarget}">
    <script>
    adminUser=sys.argv[0]
    adminPassword=sys.argv[1]
    adminUrl=sys.argv[2]
    serverTarget=sys.argv[3]
    connect(adminUser,adminPassword,adminUrl)
    target=getMBean("/Servers/"+serverTarget)
    if target == None:
    target=getMBean("/Clusters/"+serverTarget)
    type="Cluster"
    else:
    type="Server"
    print 'Shutting down '+serverTarget+'...'
    shutdown(serverTarget,type,'true',15,force='true')
    print serverTarget+' was shut down successfully.'
    </script>
    </wlst>
    <!-- setDomainEnv.sh must have been called to set DOMAIN_HOME. Remove all leftover .lok files to allow server
    to start back up again. -->
    <echo message="Deleting any lok files that have not been removed..." />
    <delete failonerror="false">
    <fileset dir="${env.DOMAIN_HOME}/servers/@{serverTarget}" includes="**/*.lok"/>
    </delete>
    </try>
    <catch>
    <fail message="@{serverTarget} shutdown failed. ${server.error}" />
    </catch>
    <finally/>
    </trycatch>
    </sequential>
    </macrodef>
    Any help would be appreciated. Thanks!

    Well, it looks like passing something like "-Djava.io.tmpdir=/var/tmp/javatmp/`date +%Y%m%d`" to ant did the trick. I had to make sure that directory existed first, otherwise it threw a java ioexception.
    I still don't understand what changes between 10.3.0 and 10.3.1 to necessitate this change.

  • Where on earth can I get the latest WLST since dev2dev moved for weblogic 8

    This is driving me crazy.
    I did manage to download a version of WLST as part of wli_util.jar.
    However, when I try to view my custom mbeans I get a null pointer. On another forum I found someone ask the question whats causing it and the answer was its fixed in the subsequent WLST release. But I cant find the download page for this utility anywhere. Anything I find on the web points to the old dev2dev site.
    All I want to do is view my custom mbeans. Have been spending far too much time on a task which should only take half a day. I have a solution in JBoss but we deploy to weblogic in the live environment.
    There is plenty of help/howto pages for WLST, but no place have I seen a link to a download page for this.
    I understand its packaged with Weblogic 9, but that 8.1 didnt have it and Im stuck with 8.1 running on a 1.4 JVM.
    Lastely, I did try to create this in the weblogic.interest.management forum, but clicking on the new Topic button produced an error message saying I dont have permissions to "read" this topic, which to me makes no sense since I was just viewing/searching in there for the answer.
    Couldsome nice person post the link?
    Regards
    Tim

    If you have the old uri - you can access it from the WayBackMachine on archive.org.
    you might want to open a case with customer support about missing content from dev2dev.
    If you're brave enough to post your email address, you might get someone to email it to you.
    You could also download/install/extract it from WLS 9.
    Or ask customer support to send it to you.

  • WLST, how do I suppress unwanted stack traces and make WLST less verbose?

    Hi everyone,
    I've just started out with WLST but have ended up somewhat confused. My script works as intended but is very verbose.
    Suppose I want to log in:
    try:
         connect(user, "wrong_password", url)
    except WLSTException, err:
         print str(err)
         print "Run with option \"-h\" for help"The password is wrong so I get something like this printed out by me:
    {noformat}
    Error occured while performing connect : User: wm714, failed to be authenticated. Use dumpStack() to view the full stacktrace
    {noformat}
    But I also get a totally unwanted Java stack trace (before my message):
    {noformat}This Exception occurred at Fri May 21 15:49:01 CEST 2010.
    javax.naming.AuthenticationException [Root exception is java.lang.SecurityException: User: wm714, failed to be authenticated.]
    at weblogic.jndi.internal.ExceptionTranslator.toNamingException(ExceptionTranslator.java:42)
    at weblogic.jndi.WLInitialContextFactoryDelegate.toNamingException(WLInitialContextFactoryDelegate.java:783)
    at weblogic.jndi.WLInitialContextFactoryDelegate.pushSubject(WLInitialContextFactoryDelegate.java:677)
    {noformat}
    I don't want to confuse the user with all that! I found this:
    http://objectmix.com/weblogic/529822-wlst-exception-handling-unwanted-stack-trace.html
    Which discusses WLS.commandExceptionHandler.setSilent(1) I'm running on WLS 10.3.0.0 and can execute that statement but it has no effect. I didn't even know about the WLS-object and I can find no documentation on commandExceptionHandler.
    On the matter of verbosity, is there any way to get rid of stuff like:
    Location changed to domainRuntime tree. This is a read-only tree with DomainMBean as the root.
    For more help, use help(domainRuntime)I avoid using the "interactive" commands like cd and use stuff like getMBean("domainRuntime:/ServerRuntimes/" + appServer.getName()
    + "/JMSRuntime/" + appServer.getName() + ".jms/JMSServers") but I still get the clutter printed out.
    Thanks!

    Workaround:
    wlstOut = tempfile.mktemp(suffix="_wlst.txt")
    redirect(wlstOut, "false")
    ... do useful stuff
    stopRedirect()
    os.remove(wlstOut)I would have preffered to turn off the messages (yes I could try /dev/null) but this will do. A funny thing is that the stack trace I wrote about doesn't appear in the log file. Somehow "redirect" must have a nice side effect.
    /Roger

  • Creating SessionMBean error while deploying OSB through WLSt script

    Hi All,
    I am trying to deploy my OSB by using WLST scripts.
    After setting the required properties in files,I ran the import.py script.But I got an error while creating an session bean
    I have pasted the whole stcak here.It is going fine till creating a session.After that it is failing:
    Any pointers in this regard will be helpful.
    ****************************the stack************************88
    Your environment has been set.
    CLASSPATH=E:\Oracle\Middleware\patch_wls1033\profiles\default\sys_manifest_class
    path\weblogic_patch.jar;E:\Oracle\Middleware\patch_oepe1033\profiles\default\sys
    manifestclasspath\weblogic_patch.jar;E:\Oracle\Middleware\patch_ocp353\profile
    s\default\sys_manifest_classpath\weblogic_patch.jar;E:\Oracle\Middleware\jrockit
    _160_17_R28.0.0-679\lib\tools.jar;E:\Oracle\Middleware\wlserver_10.3\server\lib\
    weblogic_sp.jar;E:\Oracle\Middleware\wlserver_10.3\server\lib\weblogic.jar;E:\Or
    acle\Middleware\modules\features\weblogic.server.modules_10.3.3.0.jar;E:\Oracle\
    Middleware\wlserver_10.3\server\lib\webservices.jar;E:\Oracle\Middleware\modules
    \org.apache.ant_1.7.1/lib/ant-all.jar;E:\Oracle\Middleware\modules\net.sf.antcon
    trib_1.1.0.0_1-0b2/lib/ant-contrib.jar;;E:\Oracle\Middleware/Oracle_OSB1/lib/sb-
    kernel-api.jar;E:\Oracle\Middleware/Oracle_OSB1/modules/com.bea.common.configfwk
    _1.3.0.0.jar;E:\Oracle\Middleware/modules/com.bea.common.configfwk.wlinterop_10.
    3.1.0
    Apache Ant version 1.7.1 compiled on June 27 2008
    Buildfile: ..\scripts\build.xml
    Detected Java version: 1.6 in: E:\Oracle\Middleware\jrockit_160_17_R28.0.0-679\j
    re
    Detected OS: Windows XP
    parsing buildfile C:\osb\build\scripts\build.xml with URI = file:/C:/osb/build/s
    cripts/build.xml
    Project base dir set to: C:\osb\build\scripts
    [antlib:org.apache.tools.ant] Could not load definitions from resource org/apach
    e/tools/ant/antlib.xml. It could not be found.
    [property] Loading Environment env.
    [property] Loading C:\osb\build\dev\ant.properties
    Build sequence for target(s) `import' is [import]
    Complete build sequence is [import, ]
    import:
    [echo] importscript: c:/osb/build/scripts/import.py
    [echo] importconfig: c:/osb/build/dev/import.properties
    dropping E:\Oracle\Middleware\patch_wls1033\profiles\default\sys_manifest_classp
    ath\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_oepe1033\profiles\default\sys_manifest_class
    path\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_ocp353\profiles\default\sys_manifest_classpa
    th\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\wlserver_10.3\server\lib\weblogic_sp.jar from path
    as it doesn't exist
    dropping E:\Oracle\Middleware\modules\com.bea.common.configfwk.wlinterop_10.3.1.
    0 from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_wls1033\profiles\default\sys_manifest_classp
    ath\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_oepe1033\profiles\default\sys_manifest_class
    path\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_ocp353\profiles\default\sys_manifest_classpa
    th\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\wlserver_10.3\server\lib\weblogic_sp.jar from path
    as it doesn't exist
    dropping E:\Oracle\Middleware\modules\com.bea.common.configfwk.wlinterop_10.3.1.
    0 from path as it doesn't exist
    [wlst] <WLSTTask> Executing the command line :
    [wlst] E:\Oracle\Middleware\jrockit_160_17_R28.0.0-679\jre\bin\java.exe -Dd
    ebug=true -DfailOnError=true -DexecuteScriptBeforeFile=true -DpropertiesFile=c:/
    osb/build/dev/import.properties -DfileName=c:/osb/build/scripts/import.py -class
    path E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-launcher.jar;E:\O
    racle\Middleware\jrockit_160_17_R28.0.0-679\lib\tools.jar;E:\Oracle\Middleware\w
    lserver_10.3\server\lib\weblogic.jar;E:\Oracle\Middleware\modules\features\weblo
    gic.server.modules_10.3.3.0.jar;E:\Oracle\Middleware\wlserver_10.3\server\lib\we
    bservices.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-all.jar;
    E:\Oracle\Middleware\modules\net.sf.antcontrib_1.1.0.0_1-0b2\lib\ant-contrib.jar
    ;E:\Oracle\Middleware\Oracle_OSB1\lib\sb-kernel-api.jar;E:\Oracle\Middleware\Ora
    cle_OSB1\modules\com.bea.common.configfwk_1.3.0.0.jar;E:\Oracle\Middleware\modul
    es\org.apache.ant_1.7.1\lib\ant-antlr.jar;E:\Oracle\Middleware\modules\org.apach
    e.ant_1.7.1\lib\ant-apache-bcel.jar;E:\Oracle\Middleware\modules\org.apache.ant_
    1.7.1\lib\ant-apache-bsf.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\l
    ib\ant-apache-log4j.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\an
    t-apache-oro.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-apach
    e-regexp.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-apache-re
    solver.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-commons-log
    ging.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-commons-net.j
    ar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-jai.jar;E:\Oracle\M
    iddleware\modules\org.apache.ant_1.7.1\lib\ant-javamail.jar;E:\Oracle\Middleware
    \modules\org.apache.ant_1.7.1\lib\ant-jdepend.jar;E:\Oracle\Middleware\modules\o
    rg.apache.ant_1.7.1\lib\ant-jmf.jar;E:\Oracle\Middleware\modules\org.apache.ant_
    1.7.1\lib\ant-jsch.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant
    -junit.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-netrexx.jar
    ;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-nodeps.jar;E:\Oracle\
    Middleware\modules\org.apache.ant_1.7.1\lib\ant-starteam.jar;E:\Oracle\Middlewar
    e\modules\org.apache.ant_1.7.1\lib\ant-stylebook.jar;E:\Oracle\Middleware\module
    s\org.apache.ant_1.7.1\lib\ant-swing.jar;E:\Oracle\Middleware\modules\org.apache
    .ant_1.7.1\lib\ant-testutil.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.
    1\lib\ant-trax.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-web
    logic.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant.jar;E:\Oracl
    e\Middleware\modules\org.apache.ant_1.7.1\lib\xercesImpl.jar;E:\Oracle\Middlewar
    e\modules\org.apache.ant_1.7.1\lib\xml-apis.jar weblogic.management.scripting.WL
    STInterpreterInvoker
    dropping E:\Oracle\Middleware\patch_wls1033\profiles\default\sys_manifest_classp
    ath\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_oepe1033\profiles\default\sys_manifest_class
    path\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_ocp353\profiles\default\sys_manifest_classpa
    th\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\wlserver_10.3\server\lib\weblogic_sp.jar from path
    as it doesn't exist
    dropping E:\Oracle\Middleware\modules\com.bea.common.configfwk.wlinterop_10.3.1.
    0 from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_wls1033\profiles\default\sys_manifest_classp
    ath\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_oepe1033\profiles\default\sys_manifest_class
    path\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_ocp353\profiles\default\sys_manifest_classpa
    th\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\wlserver_10.3\server\lib\weblogic_sp.jar from path
    as it doesn't exist
    dropping E:\Oracle\Middleware\modules\com.bea.common.configfwk.wlinterop_10.3.1.
    0 from path as it doesn't exist
    [wlst] Executing 'E:\Oracle\Middleware\jrockit_160_17_R28.0.0-679\jre\bin\j
    ava.exe' with arguments:
    [wlst] '-Ddebug=true'
    [wlst] '-DfailOnError=true'
    [wlst] '-DexecuteScriptBeforeFile=true'
    [wlst] '-DpropertiesFile=c:/osb/build/dev/import.properties'
    [wlst] '-DfileName=c:/osb/build/scripts/import.py'
    [wlst] '-classpath'
    [wlst] 'E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-launcher.
    jar;E:\Oracle\Middleware\jrockit_160_17_R28.0.0-679\lib\tools.jar;E:\Oracle\Midd
    leware\wlserver_10.3\server\lib\weblogic.jar;E:\Oracle\Middleware\modules\featur
    es\weblogic.server.modules_10.3.3.0.jar;E:\Oracle\Middleware\wlserver_10.3\serve
    r\lib\webservices.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-
    all.jar;E:\Oracle\Middleware\modules\net.sf.antcontrib_1.1.0.0_1-0b2\lib\ant-con
    trib.jar;E:\Oracle\Middleware\Oracle_OSB1\lib\sb-kernel-api.jar;E:\Oracle\Middle
    ware\Oracle_OSB1\modules\com.bea.common.configfwk_1.3.0.0.jar;E:\Oracle\Middlewa
    re\modules\org.apache.ant_1.7.1\lib\ant-antlr.jar;E:\Oracle\Middleware\modules\o
    rg.apache.ant_1.7.1\lib\ant-apache-bcel.jar;E:\Oracle\Middleware\modules\org.apa
    che.ant_1.7.1\lib\ant-apache-bsf.jar;E:\Oracle\Middleware\modules\org.apache.ant
    _1.7.1\lib\ant-apache-log4j.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.
    1\lib\ant-apache-oro.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\a
    nt-apache-regexp.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-a
    pache-resolver.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-com
    mons-logging.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-commo
    ns-net.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-jai.jar;E:\
    Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-javamail.jar;E:\Oracle\Mi
    ddleware\modules\org.apache.ant_1.7.1\lib\ant-jdepend.jar;E:\Oracle\Middleware\m
    odules\org.apache.ant_1.7.1\lib\ant-jmf.jar;E:\Oracle\Middleware\modules\org.apa
    che.ant_1.7.1\lib\ant-jsch.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1
    \lib\ant-junit.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-net
    rexx.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-nodeps.jar;E:
    \Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant-starteam.jar;E:\Oracle\M
    iddleware\modules\org.apache.ant_1.7.1\lib\ant-stylebook.jar;E:\Oracle\Middlewar
    e\modules\org.apache.ant_1.7.1\lib\ant-swing.jar;E:\Oracle\Middleware\modules\or
    g.apache.ant_1.7.1\lib\ant-testutil.jar;E:\Oracle\Middleware\modules\org.apache.
    ant_1.7.1\lib\ant-trax.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib
    \ant-weblogic.jar;E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\ant.jar;
    E:\Oracle\Middleware\modules\org.apache.ant_1.7.1\lib\xercesImpl.jar;E:\Oracle\M
    iddleware\modules\org.apache.ant_1.7.1\lib\xml-apis.jar'
    [wlst] 'weblogic.management.scripting.WLSTInterpreterInvoker'
    [wlst]
    [wlst] The ' characters around the executable and arguments are
    [wlst] not part of the command.
    dropping E:\Oracle\Middleware\patch_wls1033\profiles\default\sys_manifest_classp
    ath\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_oepe1033\profiles\default\sys_manifest_class
    path\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_ocp353\profiles\default\sys_manifest_classpa
    th\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\wlserver_10.3\server\lib\weblogic_sp.jar from path
    as it doesn't exist
    dropping E:\Oracle\Middleware\modules\com.bea.common.configfwk.wlinterop_10.3.1.
    0 from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_wls1033\profiles\default\sys_manifest_classp
    ath\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_oepe1033\profiles\default\sys_manifest_class
    path\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\patch_ocp353\profiles\default\sys_manifest_classpa
    th\weblogic_patch.jar from path as it doesn't exist
    dropping E:\Oracle\Middleware\wlserver_10.3\server\lib\weblogic_sp.jar from path
    as it doesn't exist
    dropping E:\Oracle\Middleware\modules\com.bea.common.configfwk.wlinterop_10.3.1.
    0 from path as it doesn't exist
    [wlst] Using input " "
    [wlst] <WLSTTask> Loaded and set the properties from c:/osb/build/dev/impor
    t.properties
    [wlst] <WLSTTask> sys.argv is ['c:/osb/build/scripts/import.py']
    [wlst] Connecting to server: t3://localhost:7001
    [wlst] Connecting to t3://localhost:7001 with userid weblogic ...
    [wlst] Successfully connected to Admin Server 'AdminServer' that belongs to
    domain 'base_domain'.
    [wlst]
    [wlst] Warning: An insecure protocol was used to connect to the
    [wlst] server. To ensure on-the-wire security, the SSL port or
    [wlst] Admin port should be used instead.
    [wlst]
    [wlst] Location changed to domainRuntime tree. This is a read-only tree wit
    h DomainMBean as the root.
    [wlst] For more help, use help(domainRuntime)
    [wlst]
    [wlst] Starting import of: c:/osb/configuration/sbconfig.jar on ALSB Admin
    Server: t3://localhost:7001
    [wlst] Read import jar file
    [wlst] Import file read successfully c:/osb/configuration/sbconfig.jar
    [wlst] Creating unique session name
    [wlst] Created session name : ALSBImportScript-1279101189649
    [wlst] Creating SessionMBean
    [wlst] Unexpected error: java.lang.RuntimeException
    [wlst] Unexpected error: java.lang.RuntimeException
    [wlst] No stack trace available.
    [wlst] Traceback (innermost last):
    [wlst] File "c:\osb\build\scripts\import.py", line 179, in ?
    [wlst] File "c:\osb\build\scripts\import.py", line 47, in importToALSBDom
    ain
    [wlst] File "c:\osb\build\scripts\import.py", line 167, in getSessionMBea
    n
    [wlst] File "<iostream>", line 1162, in findService
    [wlst] at weblogic.management.jmx.MBeanServerInvocationHandler.newProxy
    Instance(MBeanServerInvocationHandler.java:621)
    [wlst] at weblogic.management.jmx.MBeanServerInvocationHandler.invoke(M
    BeanServerInvocationHandler.java:418)
    [wlst] at $Proxy11.findService(Unknown Source)
    [wlst] at weblogic.management.scripting.WLScriptContext.findService(WLS
    criptContext.java:209)
    [wlst] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    [wlst] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcces
    sorImpl.java:39)
    [wlst] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMet
    hodAccessorImpl.java:25)
    [wlst] at java.lang.reflect.Method.invoke(Method.java:597)
    [wlst]
    [wlst] java.lang.RuntimeException: java.lang.RuntimeException: java.lang.Cl
    assNotFoundException: com.bea.wli.sb.management.configuration.DelegatedSessionMa
    nagementMBean
    [wlst]
    [wlst] Exception in thread "Main Thread" java.lang.IllegalStateException: T
    raceback (innermost last):
    [wlst] File "c:\osb\build\scripts\import.py", line 179, in ?
    [wlst] File "c:\osb\build\scripts\import.py", line 47, in importToALSBDom
    ain
    [wlst] File "c:\osb\build\scripts\import.py", line 167, in getSessionMBea
    n
    [wlst] File "<iostream>", line 1162, in findService
    [wlst] at weblogic.management.jmx.MBeanServerInvocationHandler.newProxy
    Instance(MBeanServerInvocationHandler.java:621)
    [wlst] at weblogic.management.jmx.MBeanServerInvocationHandler.invoke(M
    BeanServerInvocationHandler.java:418)
    [wlst] at $Proxy11.findService(Unknown Source)
    [wlst] at weblogic.management.scripting.WLScriptContext.findService(WLS
    criptContext.java:209)
    [wlst] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    [wlst] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcces
    sorImpl.java:39)
    [wlst] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMet
    hodAccessorImpl.java:25)
    [wlst] at java.lang.reflect.Method.invoke(Method.java:597)
    [wlst]
    [wlst] java.lang.RuntimeException: java.lang.RuntimeException: java.lang.Cl
    assNotFoundException: com.bea.wli.sb.management.configuration.DelegatedSessionMa
    nagementMBean
    [wlst]
    [wlst] at weblogic.management.scripting.WLSTInterpreterInvoker.printErr
    or(WLSTInterpreterInvoker.java:110)
    [wlst] at weblogic.management.scripting.WLSTInterpreterInvoker.executeP
    yScript(WLSTInterpreterInvoker.java:103)
    [wlst] at weblogic.management.scripting.WLSTInterpreterInvoker.main(WLS
    TInterpreterInvoker.java:27)
    BUILD FAILED
    C:\osb\build\scripts\build.xml:13: Java returned: 1
    at org.apache.tools.ant.taskdefs.Java.execute(Java.java:108)
    at weblogic.ant.taskdefs.management.WLSTTask.execute(WLSTTask.java:115)
    at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
    java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
    sorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav
    a:106)
    at org.apache.tools.ant.Task.perform(Task.java:348)
    at org.apache.tools.ant.Target.execute(Target.java:357)
    at org.apache.tools.ant.Target.performTasks(Target.java:385)
    at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
    at org.apache.tools.ant.Project.executeTarget(Project.java:1307)
    at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExe
    cutor.java:41)
    at org.apache.tools.ant.Project.executeTargets(Project.java:1191)
    at org.apache.tools.ant.Main.runBuild(Main.java:758)
    at org.apache.tools.ant.Main.startAnt(Main.java:218)
    at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
    at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
    Total time: 16 seconds
    C:\osb\build\dev>^A

    Hi,
    I tried debugging it and i am still getting the same error. I used the script provided byoracle and the script which is given here.
    Below is the error i am getting :
    [java] ImportError: cannot import name SessionManagementMBean
    I am getting an error at
    def getSessionManagementMBean(sessionName):
    SessionMBean = findService("SessionManagement", "com.bea.wli.sb.management.configuration.SessionManagementMBean")
    SessionMBean.createSession(sessionName)
    return SessionMBean
    Its able to create a unique session , after that for creating session name its throwing error.
    C:\Development\Build\scripts\build.xml:31: Java returned: 1
    at org.apache.tools.ant.taskdefs.Java.execute(Java.java:108)
    at weblogic.ant.taskdefs.management.WLSTTask.execute(WLSTTask.java:115)
    at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
    java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
    sorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav
    a:106)
    at org.apache.tools.ant.Task.perform(Task.java:348)
    at org.apache.tools.ant.Target.execute(Target.java:357)
    at org.apache.tools.ant.Target.performTasks(Target.java:385)
    at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
    at org.apache.tools.ant.Project.executeTarget(Project.java:1306)
    at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExe
    cutor.java:41)
    at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
    at org.apache.tools.ant.Main.runBuild(Main.java:758)
    at org.apache.tools.ant.Main.startAnt(Main.java:217)
    at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
    at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
    Any help on this??

Maybe you are looking for