WLST script to activate/decativate MDB in side an EAR file

Hi
we have an ear file deployed to a cluster and that ear file has got MDB s inside it.
I need to disable and enable this MD while the EAR file is in active state.
I am able to perform the task via console but I need to script it.
the WLST recording of the actions shows nothing.
and I am not able to browse through the deployment in the wlst interactive commands.
any help?

Hi,
If you want to dynamicall make any Modifications in your Deployment Descriptors like "application.xml"..."weblogic.xml"...etc then you can use *"Plan.xml"* feature provided bu WebLogic....
Example : http://jaysensharma.wordpress.com/2009/11/29/shared-library-with-plan-xml/
Example : http://jaysensharma.wordpress.com/2009/12/16/updating-cookiename-using-plan-xml/
Thanks
Jay SenSharma

Similar Messages

  • How to parse a xml file within a WLST script

    Hi all,
    I'm using ALSB2.6 and I'm writing a WLST script that should read config info from a xml file and create an ALSB prj.
    I got an error when I call:
    xmldoc = minidom.parse(sock).documentElement
    The code:
    print '#### IPEventConfigFile: ', IPEventConfigFile
    IPEventConfig = loadXML(IPEventConfigFile)
    where
    def loadXML(source):
    sock = open(source)
    xmldoc = minidom.parse(sock).documentElement
    sock.close()
    return xmldoc
    The error:
    [java] #### IPEventConfigFile: /products/software/terraferma/release3/EventBus/repository/events/DummyEvent/resource/DummyEvent-IPEventConfig.xml
    [java] ===============================================================
    [java] Unexpected error: exceptions.AttributeError
    [java] ===============================================================
    [java] No stack trace available.
    [java] Unexpected error: exceptions.AttributeError
    [java] No stack trace available.
    [java] Problem invoking WLST - Traceback (innermost last):
    [java] File "/products/software/terraferma/release3/EventBus/scripts/cloning.py", line 198, in ?
    [java] File "/products/software/terraferma/release3/EventBus/scripts/cloning.py", line 102, in cloning
    [java] File "/products/software/terraferma/release3/EventBus/scripts/cloning.py", line 178, in loadXML
    [java] File "Lib/xml/dom/minidom.py", line 908, in parse
    [java] File "Lib/xml/dom/minidom.py", line 900, in _doparse
    [java] File "Lib/xml/dom/pulldom.py", line 251, in getEvent
    [java] AttributeError: feed
    Line 178 is:
    xmldoc = minidom.parse(sock).documentElement
    I'm trying to understand where I'm wrong.
    Thanks in advance
    ferp

    Using the SAXParser in JAXP the parsing of the XML file is event driven.
    Instantiate the parser:
    SAXParserFactory factory = SAXParserFactory.newInstance();
    SAXParser parser = factory.newSAXParser();
    InputSource is = new InputSource(new FileReader(theXML));call the parse method:
    parser.parse(is, this);The following events are fired as the parser works through the XML public void startElement(String namespaceURI, String localName, String qName, Attributes atts) throws org.xml.sax.SAXException
    public void endElement(String namespaceURI, String localName, String qName) throws org.xml.sax.SAXException
    characters(char[] ch, int start, int length)etc.
    You write what you want within each of these sections to handle the structure of your data. Keep in mind SAX is useful only when you know the structure of your XML.

  • WLST Script for Disabling/Enabling Global SLA Alerting.

    Hello,
    I wanna find a way from the WLST to disable and enable the SLA Alerting which is under Operations-->Global Settings in the sbconsole. This is the global setting not per sercive!
    I have found how to create a session and how to disable the alerts per service, but i cannot find which MBean is accessed when throught the sbconsole the global SLA alerting is disabled/enabled.
    Can anybody point me to the right direction or help me to find how to do this from WLST.
    Thanks.

    Hi Ganesh,
    I have finally created the script i was looking for.. I copy-paste it below as a sample... For sure you need all the lines of code until the comment i have put "#####you need this code above"
    now the code you see below the comment is for disabling the global sla alerting... you have to write a bit to target a specific service that you want to disable.
    Keep in mind that after you make your change you hava to include those lines in order to activate the changes and disconnect and exit..
    sessionMBean.activateSession(sessionName, "enable SLA")
    disconnect()
    exit()
    If you have access to oracle support search for wlst script for osb it has a lot and you can find how to target a specific service...
    I hope that i help a little bit
    import sys
    import wlstModule
    from com.bea.wli.sb.management.configuration import SessionManagementMBean
    from com.bea.wli.sb.management.configuration import ALSBConfigurationMBean
    #from com.bea.wli.sb.management.configuration import ProxyServiceConfigurationMBean
    from com.bea.wli.sb.management.configuration.operations import OperationsConfigMBean
    from com.bea.wli.config import Ref
    from com.bea.wli.sb.util import Refs
    # Connect (username, password, URL)
    connect('weblogic', 'password', 't3://localhost:7001')
    domainRuntime()
    # Create a session name
    sessionName =sessionName = String("SessionScript"+Long(System.currentTimeMillis()).toString())
    print('... after session. Session is: ', sessionName)
    # Get the session MBean and create a session
    sessionMBean = findService(SessionManagementMBean.NAME,SessionManagementMBean.TYPE)
    print('-debug-this is the sessionbean',sessionMBean)
    print('SessionMBean is: ', sessionMBean)
    sessionMBean.createSession(sessionName)
    print(String('Session was created ... ').concat(sessionName))
    #####you need this code above
    domainCustom()
    cd('com.bea')
    #path='com.bea:Name=OperationsConfig.'+sessionName+',Location=AdminServer,Type=com.bea.wli.sb.management.configuration.operations.OperationsConfigMBean'
    cd('com.bea:Name=OperationsConfig.'+str(sessionName)+',Location=AdminServer,Type=com.bea.wli.sb.management.configuration.operations.OperationsConfigMBean')
    set('DomainSLAAlertingEnabled',java.lang.Boolean("true"))
    # Now commit (activate) the changes
    sessionMBean.activateSession(sessionName, "enable SLA")
    disconnect()
    exit()

  • Wlst script to change values for Logging.

    Hi,
    i am trying to write a wlst script to change attributes for the following.( i am new to wlst scripting)
    For all servers in a domain,
    Logging --> General --> Check Limit number of retained files
    --> Files to retain to different number.
    --> Log file Severity Level
    --> Standard out Severity Level
    --> Demain log broadcaster Severity level
    --> Memory Buffer Severity Level
    Logging --> HTTP --> Check Limit number of retained files
    --> Files to retain to different number.
    I was able to figure out the path for some of the attributes in Logging --> General.
    wls:/wl9xdomain/serverConfig/Servers/AdminServer/Log/AdminServer>
    wls:/wl9xdomain/serverConfig/Servers/AdminServer/Log/ManagedServer1>
    Can you help in finding the paths for above attributes.
    And this is the sample script i wrote, and succeded in changing "Files to retain to different number" in Logging --> General.
    connect('weblogic','weblogic','t3://localhost:7001')
    edit()
    startEdit()
    cd('/Servers/AdminServer/Log/AdminServer')
    set('FileCount',10)
    validate()
    save()
    activate()
    disconnect()
    exit()
    Thanks,
    Krishna.
    Edited by: user2656687 on Apr 15, 2009 4:46 PM

    Thanks for the response. I was able to figure out that access.log file attributes are in /Servers/AdminServer/WebServer/AdminServer/WebServerLog/AdminServer.
    And now i trying change script to apply for all the servers.
    when i use for loop it is failing. any thougts on it. may i know the syntax in this case..
    connect('weblogic','weblogic','t3://localhost:7001')
    edit()
    startEdit()
    cd('/Servers/AdminServer/Log/AdminServer')
    cmo.setNumberOfFilesLimited(true)
    cmo.setFileCount(100)
    cmo.setDomainLogBroadcastSeverity('Warning')
    cmo.setMemoryBufferSeverity('Warning')
    cmo.setLogFileSeverity('Warning')
    cmo.setStdoutSeverity('Warning')
    cd('/Servers/AdminServer/WebServer/AdminServer/WebServerLog/AdminServer')
    cmo.setNumberOfFilesLimited(true)
    cmo.setFileCount(100)
    save()
    activate()
    Thanks,
    Krishna.

  • WLST Script for Increase Log Level

    Hi All,
    How do we increase the log level of the log files using WLST ?
    I know, how to increase the log levels using the EM Console page, but I want to know, if it can be done using WLST or Python script.
    Thanks.

    Here is a WLST script that you can adjust to meet your requirements.
    connect('weblogic', 'welcome1', 'localhost:7001')
    edit()
    startEdit()
    cd('/Servers/AdminServer/Log/AdminServer')
    cmo.setLoggerSeverity('Info')
    activate()
    Run with $ java weblogic.WLST ScriptBoot.py
    Note my server is called AdminServer, so you will need to adjust for your server name and change logging level as desired.
    Mark

  • Why this WLST script does not work from ant a task

    Hi,
              The following is my lovely WLST script to disable managed server hostname verification in a cluster environment.
              It works perfect if I run it from the OS command line,
              java -cp $WL_HOME/server/lib/weblogic.jar sslSetting.py weblogic weblogic t3://localhost:7001
              But if I run it from ant task, it never works. Nothing happens, not even any messages. Any idea?
              ------ sslSetting.py -----------
              # Disable HostnameVerification on managed servers
              # This is a ONLINE script. The admin server must be running
              # @param $1 BEA_USER_NAME
              # @param $2 BEA_USER_PWD
              # @param $3 admin server URL
              if (len(sys.argv) != 4):
              print "usage: " + sys.argv[0] + " domain-home "
              sys.exit()
              beaUserName=sys.argv[1]
              beaUserPwd=sys.argv[2]
              adminServerUrl=sys.argv[3]
              def handleServer(server):
              SSLPath="/Servers/" + server.getName() + "/SSL/" + server.getName()
              print("handleServer(1): " + SSLPath)
              try:
              cd (SSLPath)
              print("handleServer(2): " + SSLPath)
              set("HostnameVerificationIgnored", "true")
              except Exception, inst:
              dumpStack()
              print ("FAILED handleServer(): " + SSLPath)
              else:
              print ("DONE handleServer(): " + SSLPath)
              #===============================================================================
              # Main
              #===============================================================================
              try:
              connect(beaUserName, beaUserPwd, adminServerUrl)
              edit()
              startEdit()
              adminServerName=cmo.getAdminServerName()
              for server in cmo.getServers():
              if adminServerName != server.getName():
              handleServer(server)
              save()
              activate()
              except Exception:
              dumpStack()
              else:
              print ("=== DONE ===")

    OK, when I run the WLST script from command java, I only need the weblogic.jar in the classpath. But I'll need a couple other jar file for it to work inside an ant target, as showing below.
              <target name="run-wlst">
              <java classname="weblogic.WLST" fork="true">
              <classpath>
              <pathelement path="${props.JAVA_HOME}/lib/tools.jar"/>
              <pathelement path="${props.WL_HOME}/server/lib/weblogic_sp.jar"/>
              <pathelement path="${props.WL_HOME}/server/lib/weblogic.jar"/>
              <pathelement path="${props.WL_HOME}/server/lib/webservices.jar"/>
              </classpath>
              <sysproperty key="weblogic.Home" value="${props.WL_HOME}" />
              <arg line="sslSetting.py weblogic weblogic t3://localhost:7001"/>
              </java>
              </target>

  • 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

  • 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??

  • Error While running WLST script to create SOA Domain in Clustered Environme

    Hi,
    I am trying to run WLST script to create SOA Domain in clustered environment.The script is as follows.
    import sys
    print "@@@ Starting the script ..."
    global props
    from wlstModule import *#@UnusedWildImport
    from java.io import FileInputStream
    from java.io import File
    #=======================================================================================
    # Create Boot Properties File
    #=======================================================================================
    def createBootPropertiesFile(directoryPath, username, password):
    adminserverDir = File(directoryPath)
    bool = adminserverDir.mkdirs()
    fileNew=open(directoryPath + '/boot.properties', 'w')
    fileNew.write('username=%s\n' % username)
    fileNew.write('password=%s\n' % password)
    fileNew.flush()
    fileNew.close()
    def createNodeManagerPropertiesFile(directoryPath, username, password):
    adminserverDir = File(directoryPath)
    bool = adminserverDir.mkdirs()
    fileNew=open(directoryPath + '/nm_password.properties', 'w')
    fileNew.write('username=%s\n' % username)
    fileNew.write('password=%s\n' % password)
    fileNew.flush()
    fileNew.close()
    def createAdminStartupPropertiesFile(directoryPath, args):
    adminserverDir = File(directoryPath)
    bool = adminserverDir.mkdirs()
    fileNew=open(directoryPath + '/startup.properties', 'w')
    args=args.replace(':','\\:')
    args=args.replace('=','\\=')
    fileNew.write('Arguments=%s\n' % args)
    fileNew.flush()
    fileNew.close()
    I am getting the error :
    Problem invoking WLST - Traceback (innermost last):
    (no code object) at line 0
    File "D:\Oracle\Middleware\Oracle_SOA1\bin\SOADomainScript.py", line 11
    adminserverDir = File(directoryPath)
    ^
    SyntaxError: invalid syntax
    Do i need to set any jar in the classpath? Already jython.jar is available in the classapath.
    Thanks in advance.
    Regards,
    Subha

    Hi,
    I am trying to run WLST script to create SOA Domain in clustered environment.The script is as follows.
    import sys
    print "@@@ Starting the script ..."
    global props
    from wlstModule import *#@UnusedWildImport
    from java.io import FileInputStream
    from java.io import File
    #=======================================================================================
    # Create Boot Properties File
    #=======================================================================================
    def createBootPropertiesFile(directoryPath, username, password):
    adminserverDir = File(directoryPath)
    bool = adminserverDir.mkdirs()
    fileNew=open(directoryPath + '/boot.properties', 'w')
    fileNew.write('username=%s\n' % username)
    fileNew.write('password=%s\n' % password)
    fileNew.flush()
    fileNew.close()
    def createNodeManagerPropertiesFile(directoryPath, username, password):
    adminserverDir = File(directoryPath)
    bool = adminserverDir.mkdirs()
    fileNew=open(directoryPath + '/nm_password.properties', 'w')
    fileNew.write('username=%s\n' % username)
    fileNew.write('password=%s\n' % password)
    fileNew.flush()
    fileNew.close()
    def createAdminStartupPropertiesFile(directoryPath, args):
    adminserverDir = File(directoryPath)
    bool = adminserverDir.mkdirs()
    fileNew=open(directoryPath + '/startup.properties', 'w')
    args=args.replace(':','\\:')
    args=args.replace('=','\\=')
    fileNew.write('Arguments=%s\n' % args)
    fileNew.flush()
    fileNew.close()
    I am getting the error :
    Problem invoking WLST - Traceback (innermost last):
    (no code object) at line 0
    File "D:\Oracle\Middleware\Oracle_SOA1\bin\SOADomainScript.py", line 11
    adminserverDir = File(directoryPath)
    ^
    SyntaxError: invalid syntax
    Do i need to set any jar in the classpath? Already jython.jar is available in the classapath.
    Thanks in advance.
    Regards,
    Subha

  • Using variables in WLST Script ant task

    I have multiple scipts that are run using ant tasks, however, I do not want to have to enter the password every time one of these scripts is executed. Instead I would like to use the following ant task to store the password in a variable/property:
    <target name="getPassword" >
         <echo message="Domain: ${domain}" />
    <echo message="Username: system" />
    <input message="Please enter password:" addproperty="password" />
    </target>
    I would then like to use that variable/property everytime a script is executed like this:
         <target name="deploy4x">
              <echo message="***** Copying 4X.ear *****" />
              <copy file="${build.path}\jar\4X.ear" todir="${apps.dir}" preservelastmodified="true"/>     
              <echo message="***** Updating 4X.ear on ${domain} *****"/>
              <wlst debug="true" fileName="Deploy4X.py" executeScriptBeforeFile="true" failonerror="true" >
                   <script>
                        connect('system','%s' % ${password},'%s' % $url)
                   </script>
              </wlst>
         </target>
    However, the script blows up every time I try to run it b/c of the connect() line. I have also tried connect('system','%s' % password, '%s' % url).
    Has anyone else successfully used variables in an Ant WLST Script task?
    Thanks.

    Hi,
    when I use *XDIM_MEMBERSET ACCOUNT AS %TEST% = BAS(REVENUE) - it work fine.
    BUT ! after my first commit, it seems like the variable value is lost. And the *Xdim_memberset takes all.....
    Fortunately enough, *select still contains the variable value after *commit.
    Thanks,
    Joergen
    *Correction !
    It actually works, it still contains the variable value after commit !!
    Edited by: Jørgen Dalby Andersen on Dec 30, 2011 1:33 PM

  • Example WLST scripts for creating clustered domain for soa suite 11.1.1.4?

    Hello,
    does anyone know sample wlst scripts for creating domain for soa suite 11.1.1.4 on top of weblogic 10.3.4?
    I try to create a domain having a cluster with two managed servers in two linux machines.
    Any help appreciated.
    regards, Matti

    Please refer -
    http://download.oracle.com/docs/cd/E17904_01/web.1111/e13715/domains.htm
    http://download.oracle.com/docs/cd/E17904_01/web.1111/e13715/intro.htm#WLSTG112
    Regards,
    Anuj

  • Automatic Generation of JMS event generator using WLST script

    is there any way to create and deploy JMS event generator using WLST script. i am using weblogic server 10.3.1

    You could see this informantion here:
    http://docs.oracle.com/cd/E14981_01/wli/docs1031/deploy/cluster.html#wp1519038

  • Does anybody have a WLST script for step-by-step cluster restart?

    Does anybody have a WLST script for step-by-step "smart" cluster restart?

    Dear SAM,
    are you looking for exchange 2013 installation. Please follow below link. I have done the same scenario as yours
    1. install first VM - 2012
    2. Static IP / loopback as primary DNS
    3. install ADDS /DNS (forwarder to ISP)
    4. install second VM - Static IP again
    5. DNS of second VM to be the IP of first VM
    6. this will join the domain
    7. installation of exchange will be simple, configuration from this link : http://www.techieshelp.com/exchange-2013-step-by-step-configuration/
    MARK AS USEFUL/ANSWER IF IT DID
    Thanks
    Happiness Always
    Jatin

  • OSB: WLST script using setPreserveExistingOperationalValues has no effect

    Hi,
    I have a WLST script which imports a sbconfig.jar into OSB and executes the file customization.xml. In this script I use the following options (although I know that "false" is the default value here):
    alsbImportPlan.setPreserveExistingEnvValues(false)
    alsbImportPlan.setPreserveExistingOperationalValues(false)
    The idea behind is to overwrite the existing operational settings in OSB with the settings from the file sbconfig.jar.
    But when I execute my WLST script, the operational settings are unchanged. What am I doing wrong?
    Best regards,
    Katja

    Hi,
    thanks for your help. Now, I tried everything again from scratch and it worked!
    I exported the sbconfig.jar from OSB and checked, that my settings were in the xml files. Then I modified the settings in OSB (that I can see a difference). I executed my WLST script with the new sbconfig.jar and checked the values in OSB. Now the values were changed as expected. I do not know what was wrong before, but maybe I mixed my versions of sbconfig.jar and used a wrong one...
    So everything works fine.
    Thanks,
    Katja

  • WLST script for changing password for userid in Weblogic 9.2

    Hello Everyone,
    We want to change password for userid in weblogic 9.2. Is there a way we can do this by using WLST script? If so please provide me with steps for doing that using WLST. Thanks in advance.
    - - Weblogic Consultant

    Did you try going to the WLST documentation and searching for it? Go to [http://edocs.bea.com/wls/docs92/pdf/config_scripting.pdf] and search for "Changing a Password". The example there seems to be what you need.

Maybe you are looking for

  • Using 'A Variable' in "Help URL" instead of file path

    Hi, When we edit 'Title' Tab of analysis we get options such as: 1. Title 2. Logo 3. Subtitle 4. Started Time 5. Help URL In "Help URL" we can refer a file from an exposed directory (bydefault it's analyticRes). Syntax for refering a file is as follo

  • Cisco Connect won't connect to E2000 router

    I've had an E2000 router set up and working fine for years. Today I tried to connect to it with Cisco Connect, as I'd like to enable a separate guest network (incidentally, if there's a way to do this through the web management interface, please let

  • Contacts notes still have extra characters

    No device I have a pre that's 2 yrs old.  I have been reading that the extra characters  < br / >  issue is known; in fact 2 other posts from 2010 were closed.  I still have this problem; I added a contact 10 minutes ago and notes still added extra c

  • Stoping VI inbetween when program seeking data from serial port.

    I have an application in which I need to read data from two serial port one after other. One read will read 14 byte and other 08 bytes(Just info). Now in between if user need to stop the VI then how to stop it? Kudos are always welcome if you got sol

  • Linotype FontExplorer X auto-activation slows login time

    Hello folks, My problem is not that the core application FontExplorer X automatically opens at login. I have 'deactivated.. at login' - so the application itself only opens whenever I click it in the dock. However, the application's 'AutoLoad' plug-i