Tuesday, July 19, 2011

UserWarning: MDS-91002: MDS Application runtime MBean for "soa-infra" is not available. "deleteMetadata" operation failure

You are trying to clean up the MDS using below steps:

  1. Execute SOA_HOME/common/bin/wlst.sh
  2. Connect to admin server by running connect()
  3. Enter the domain config by running domainConfig()
  4. Delete Metadata by running deleteMetadata('soa-infra', 'soa_server1','/apps/AIAMetaData/**')


    You encounter below error:


    UserWarning: MDS-91002: MDS Application runtime MBean for "soa-infra" is not available. "deleteMetadata" operation failure


    The SOA Managed Server is up and so s the SOAINFRA. What could be the possible reason?


    The reason for the above error is the name of the managed server used. In case your admin renamed the default managed server on which SOA is deployed (the default name is soa_server1) you would get the above stated error.


    So in case you get the above error, check with your admin the name of the SOA managed server. So in case your SOA managed server name is SOA_MS_1, the MDS purge command would be as follows:


    deleteMetadata('soa-infra', 'soa_ms_1','/apps/AIAMetaData/**')


    Hope this helps...

    Now you can folow us on facebook and post your comments/views and questions for expert advise. Check this out facebook


    Find us on facebook here

Thursday, July 14, 2011

How to Check Fusion Middleware and WebLogic Component Versions

Applies to:
Oracle Fusion Middleware - Version: 11.1.1.1.0 to 11.1.1.5.0 - Release: to Oracle11g
Information in this document applies to any platform.

Goal
This document describes how to determine the versions of installed Fusion Middleware Components and Weblogic Server.

Note:
Fusion Middleware components including WebLogic Server, RCU, and components such as SOA, Identity Management, Portal-Forms-Reports-Discover, and JDeveloper must have concordant versions. This affects configuration, but not installation, and can cause a variety of failures, including ClassDefNotFound exceptions when trying to configure a new domain or managed server.


1. To determine the WebLogic Server version. There are several ways to confirm the version:
  •  Enter this command with the weblogic environment enabled:
$ java weblogic.version

  • Look in the file Middleware Home/registry.xml, and note the component tag
  • The exact WLS version can be checked using the following commands:

    On Unix:
cat $MW_HOME/wlserver_10.3/.product.properties | grep WLS_PRODUCT_VERSION

On Windows:
type %MW_HOME%\wlserver_10.3\.product.properties | findstr WLS_PRODUCT_VERSION
  • Use SmartUpdate to check the Product Version:

    On Unix:
$MW_HOME/utils/bsu/bsu.sh -view -status=applied -prod_dir=$MW_HOME/wlserver_10.3 | grep ProductVersion

On Windows:
%MW_HOME%\utils\bsu\bsu.sh -view -status=applied -prod_dir=$MW_HOME\wlserver_10.3 | findstr ProductVersion

You should see a result such as this:
ProductVersion: 10.3 MP5


2. For JDeveloper, look in the Middleware Home/registry.xml file for the following:


3. For Fusion Middleware products, use the command Oracle Home/Opatch/opatch lsinventory and note the output:
Installed Top-level Products (2):

Application Server 11g SOA Patchset 11.1.1.3.0
Oracle SOA Suite 11g 11.1.1.2.0
There are 2 products installed in this Oracle Home.


4. For the MDS version, look in the file RCU Home/rcu/log/logdir./mds.log:
REPOS_VERSION CONSTANT VARCHAR2(32) := '11.1.1.56.27' (this is for 11.1.1.3)

To get the schema version from the database, login to the database as sysdba and enter the command as shown (example here for 11.1.1.3):
SQL> select comp_id, comp_name, version from schema_version_registry;

COMP_ID
------------------------------
COMP_NAME
--------------------------------------------------------------------------------
VERSION
------------------------------
IAU
Audit Service
11.1.1.3.0

MDS
Metadata Services
11.1.1.2.0

OID
Oracle Internet Directory
11.1.1.3.0

OIF
Oracle Identity Federation Database Schema
11.1.1.2.0

ORAESS
Enterprise Scheduler Service
11.1.1.2.0

ORASDPLS
SIP Infrastructure Location Service
11.1.1.2.0

ORASDPSDS
SIP Infrastructure Subscriber Data Service
11.1.1.2.0

ORASDPXDMS
Presence
11.1.1.2.0

8 rows selected.

You can also get the schema prefix from the database using the following command:
SQL> select username, created from dba_users order by 2;

USERNAME CREATED
------------------------------ ---------
OE 12-MAY-10
SH 12-MAY-10
BI 12-MAY-10
PM 12-MAY-10
TEST01_MDS 21-JAN-11
TEST01_IAU 21-JAN-11
TEST01_IAU_APPEND 21-JAN-11
TEST01_IAU_VIEWER 21-JAN-11
TEST01_ORAESS 21-JAN-11
ODS 21-JAN-11
ODSSM 21-JAN-11

USERNAME CREATED
------------------------------ ---------
TEST01_OIF 21-JAN-11
TEST01_ORASDPXDMS 21-JAN-11
TEST01_ORASDPLS 21-JAN-11
TEST01_ORASDPSDS 21-JAN-11

The prefix given in the Repository Creation Utility (RCU) dialog is TEST01.

Large number of instances in the SOA 11g dehydration store causes EM console performance issues


Applies To:

SOA Suite 11g R1(11.1.1.3,11.1.1.4,11.1.1.5)

Scenario and Symptoms:

The BPEL Engine Audit level is set to Development.

The BPEL engine is load tested with some huge number of transactions causing to generate large number of instances in the dehydration store(SOAINFRA Schema)

The number of instances is say 10-50 Lacs.The developers complain about EM Console being very slow. Drilling into composites and instances take minutes.Below activities in EM console take time:

1.       EM Login Page Load time
2.       Time taken for logging in to the EM
3.       Time taken to render homepage for SOAINFRA
4.       Expanding the SOAINFRA and each partition within
5.       Time taken to render home page for each  deployed composite
6.       Time taken to render details for each instance of any deployed composite

Cause:

Large number of instances in the dehydration store with audit level set to Development. When you login to EM console it tries to load the large amounts of instance and fault data from database leading to slowing up the EM console response time.


Solution:

Improving the Loading of Pages in Oracle Enterprise Manager Fusion Middleware Control Console

You can improve the loading of pages that display large amounts of instance and fault data in Oracle Enterprise Manager Fusion Middleware Control Console by setting two properties in the Display Data Counts section of the SOA Infrastructure Common Properties page.

These two properties enable you to perform the following:
  • Disable the fetching of instance and fault count data to improve loading times for the following pages:
    • Dashboard pages of the SOA Infrastructure, SOA composite applications, service engines, and service components
    • Delete with Options: Instances dialog

    These settings disable the loading of all metrics information upon page load. For example, on the Dashboard page for the SOA Infrastructure, the values that typically appear in the Running and Total fields in the Recent Composite Instances section and the Instances column of the Deployed Composites section are replaced with links. When these values are large, it can take time to load this page and other pages with similar information.

  • Specify a default time period that is used as part of the search criteria for retrieving recent instances and faults for display on the following pages:

    • Dashboard pages and Instances pages of the SOA Infrastructure, SOA composite applications, service engines, and service components
    • Dashboard pages of services and references
    • Faults and Rejected Messages pages of the SOA Infrastructure, SOA composite applications, services, and references
    • Faults pages of service engines and service components

Other Suggestions/Best Practices:

1. Purge the instance-The moment we purge the instances, we see good performance.The flipside is you cannot be purging data regularly in production (to meet SLAs). My take is if you are in development server you can afford frequent purging of the instances. In Stage/Prod the Audit level would be set to production,hence performance issues due to large number of instances would not be seen. After you purge the dehydration store make sure you shrink the SOAINFRA tables along with indexes (or rebuild indexes)

2. Set Audit Level to Production/Off-The flip side is developers won't be able to troubleshoot issues with their composites. Go ahead with these settings in Production.

3. Another strategy is Switching the audit configuration to 'Deferred' which allows the auditing operations to be performed in an ansynchronous manner resulting in performance comparable to setting the audit level to disabled.Please refer Tuning BPEL audit performance [ID 1328382.1].This is recommended in production.Also can be applied to Dev/Stage environments.

4. As the number of record grows in the dehydration the EM console takes longer time to return information about instances. I believe this is a result of bad performing querries and full table scans. Generate an AWR report and see if you can tune some querries and build some indexes on tables. Get this gone by the DBAs.

5. Using a fast single threaded server(eg M5000/9000) for database instead of using slow CMT servers like the Sun T5140/5240. Please refer Migration from fast single threaded CPU machine to CMT UltraSPARC T1 and T2 results in increased CPU reporting and diminished performance [ID 781763.1]

6. Try using M series boxes for the application tier as well. But if you have to use CMT servers like T5240 make sure you follow note 860459.1 and apply the steps in the solution part to adapt all the components with CMT machine.

Let me know if the above article helps.

Soumya...

Thursday, June 30, 2011

Weblogic server fails to start with weblogic.store.PersistentStoreException: java.io.IOException: mmap, Resource temporarily unavailable error

Problem : WebLogic Managed Servers Fail During Startup with NullPointerException on the Persistent File Store

Applies to:

Oracle Weblogic Server - Version: 10.3 and later   [Release: and later ]
Information in this document applies to any platform.


Symptoms

WebLogic managed server fails to start with the error:

Error 1:

#### <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <> <1306852872205>
#### <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <> <1306852872303>
####
<> <> <> <1306852872315> java.lang.NullPointerException
at weblogic.store.io.file.StoreFile.close(StoreFile.java:432)
at weblogic.store.io.file.Heap.open(Heap.java:307)
at weblogic.store.io.file.FileStoreIO.open(FileStoreIO.java:104)
at weblogic.store.internal.PersistentStoreImpl.recoverStoreConnections(PersistentStoreImpl.java:413)
at weblogic.store.internal.PersistentStoreImpl.open(PersistentStoreImpl.java:404)
at weblogic.store.xa.PersistentStoreManagerXA.createFileStore(PersistentStoreManagerXA.java:118)
at weblogic.diagnostics.archive.DiagnosticStoreRepository.getStore(DiagnosticStoreRepository.java:91)
at weblogic.diagnostics.lifecycle.DiagnosticSystemService.start(DiagnosticSystemService.java:128)
at weblogic.t3.srvr.SubsystemRequest.run(SubsystemRequest.java:64)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)

Error 2:




There are 1 nested errors:

weblogic.store.PersistentStoreException: java.io.IOException: mmap, Resource temporarily unavailable, errno=11
        at weblogic.store.io.file.Heap.getNextRecoveryFile(Heap.java:1204)
        at weblogic.store.io.file.Heap.recover(Heap.java:1029)
        at weblogic.store.io.file.FileStoreIO.recover(FileStoreIO.java:647)
        at weblogic.store.io.file.FileStoreIO.open(FileStoreIO.java:114)
        at weblogic.store.internal.PersistentStoreImpl.recoverStoreConnections(PersistentStoreImpl.java:413)
        at weblogic.store.internal.PersistentStoreImpl.open(PersistentStoreImpl.java:404)
        at weblogic.store.xa.PersistentStoreManagerXA.createFileStore(PersistentStoreManagerXA.java:118)
        at weblogic.diagnostics.archive.DiagnosticStoreRepository.getStore(DiagnosticStoreRepository.java:91)
        at weblogic.diagnostics.lifecycle.DiagnosticSystemService.start(DiagnosticSystemService.java:128)
        at weblogic.t3.srvr.SubsystemRequest.run(SubsystemRequest.java:64)
        at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
        at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
Caused by: java.io.IOException: mmap, Resource temporarily unavailable, errno=11
        at weblogic.store.io.file.direct.DirectIONative.mapFile(Native Method)
        at weblogic.store.io.file.direct.FileMapping.mapView(FileMapping.java:169)
        at weblogic.store.io.file.direct.FileMapping.remapViewInit(FileMapping.java:140)
        at weblogic.store.io.file.direct.FileMapping.openInternal(FileMapping.java:105)
        at weblogic.store.io.file.direct.FileMapping.open(FileMapping.java:76)
        at weblogic.store.io.file.StoreFile.mappedRecoveryInit(StoreFile.java:519)
        at weblogic.store.io.file.Heap.getNextRecoveryFile(Heap.java:1191)
        ... 11 more

Cause

The file $DOMAIN_HOME/servers//data/store/diagnostics/WLS_DIAGNOSTICS000000.DAT is somehow corrupted.

The Archive component of the WebLogic Diagnostics Framework (WLDF) captures and persists all data events, log records, and metrics collected by WLDF from server instances and applications running on them and saves them into this file. So having this file corrupted, prevents the Server from writing the WLDF information, and hence it fails to start.

Solution

Backup and remove the WLS_DIAGNOSTICS000000.DAT file, then restart the server: a new file will be created automatically.

This should not affect the server performance. It will only cause the loss of the archived diagnostic information (which is likely already lost since the file is corrupt).


References

NOTE:1059924.1 - WebLogic Server Diagnostics File is Corrupt or Locked
WebLogic Managed Servers Fail During Startup with NullPointerException on the Persistent File Store [ID 1327538.1]

Soumya...

Wednesday, June 29, 2011

Can SOA 11g be Installed With an XE database?

Can SOA 11g be installed with an XE database?  While running rcu.bat (RCU) for SOA Suite Installation, the installer did not accept the default Oracle XE Service Name with error "Cannot find XE Service Name To Complete RCU Configuration". 


Although XE is not officially supported, many people use it without any issue for development or test environments or demonstrations. But before installing and running the RCU utility, you need to change the DB parameters as follows:


$ORACLE_HOME/bin/sqlplus /nolog

SQL> connect sys/oracle as sysdba;
SQL> EXEC DBMS_XDB.SETLISTENERLOCALACCESS(FALSE);
SQL> alter system set processes = 400 scope = spfile;
SQL> commit;
SQL> shutdown immediate

$ORACLE_HOME/bin/sqlplus /nolog

SQL> connect sys/oracle as sysdba;
SQL> startup
SQL> show parameter sessions
*** (make sure sessions is 225) ***
SQL> exit



For further reference please refer metalink id ID 1108487.1


Soumya...

Wednesday, June 22, 2011

Downloading of Patches Via BEA Smart Update no more supported

You need to apply a one-off patch to Weblogic. You run the bsu.sh script and try launching the BEA Smart Update. The Smart Update on launch recommends for an update. You go ahead and update it. The Smart Update now restarts and the you see the version of the utility to be 3.3.0.0. Yo try to find the Download patch tab, but surprisingly don't find it! You restart the BSU and wonder what went wrong!

Do not worry!

Smart Update patch and patch set download capability has been decommissioned by Oracle since June 10, 2011.Oracle says to better coordinate the distribution of patches to Oracle customers, they would consolidate on My Oracle Support as the single source for patch delivery([Metalink ID 1294294.1] ).

Hence you would now  need to download the Weblogic one-off patches from metalink from the patches and Updates section using your metalink ID.

How to Locate and Download Patches for WebLogic Server Using My Oracle Support
  1. Log onto My Oracle Support.
  2. Click on the "Patches & Updates" tab.
  3. Click on "Product or Family" (Advanced Search)
  4. For the "Product is" choose Oracle WebLogic Server.
  5. For the "Release is" choose the WebLogic Server releases you want to search on
  6. For "Description contains" type in your Smart Update Patch ID (in this case 8DNU)
  7. Hit Search.
For step by step screen shots on how to download WLS patch please follow metalink note: 

Master Note: How to Locate and Download Patches for WebLogic Server Using My Oracle Support [ID 1302053.1]

Also you can refer to
WebLogic Net Installers and Downloading of Patches Via Smart Update To Be Decommissioned [ID 1294294.1] 

 Sanjay...






Tuesday, June 21, 2011

java.lang.Thread.State: TIMED_WAITING (parking) at sun.misc.Unsafe.park(Native Method) error


Applies to:

Oracle Weblogic Server - Version: 10.3 to 10.3.3
Information in this document applies to any platform.

Symptoms

A stateless session bean (SLSB) is deployed in WebLogic 10.3.0. The SLSB only has one bean instance in the pool (max-beans-in-free-pool=1and initial-beans-in-free-pool=1).
After several hours and with over 100000 incoming requests the bean instance goes into waiting state.
Since there is only one bean instance in the pool, this effectively hangs all incoming calls.

The thread dump shows the bean instance goes into waiting state:
"[ACTIVE] ExecuteThread: '13' for queue: 'weblogic.kernel.Default (self-tuning)'" daemon prio=10 tid=0149e600 nid=48 lwp_id=5603464 waiting on condition [6c240000]
java.lang.Thread.State: TIMED_WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for <89861118> (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
at java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:198)
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2054)
at weblogic.ejb.container.pool.StatelessSessionPool.waitForBean(StatelessSessionPool.java:269)
at weblogic.ejb.container.pool.StatelessSessionPool.getBean(StatelessSessionPool.java:111)
at weblogic.ejb.container.manager.StatelessManager.preInvoke(StatelessManager.java:148)
at weblogic.ejb.container.internal.BaseRemoteObject.preInvoke(BaseRemoteObject.java:227)
at weblogic.ejb.container.internal.StatelessRemoteObject.preInvoke(StatelessRemoteObject.java:52)
at com.tetrapak.ppm.external.xml.bean.UMGMessageLogFacade_n73y0z_EOImpl.isMachineValid(UMGMessageLogFacade_n73y0z_EOImpl.java:261)
at com.tetrapak.ppm.external.xml.bean.UMGMessageLogFacade_n73y0z_EOImpl_WLSkel.invoke(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:589)
at weblogic.rmi.cluster.ClusterableServerRef.invoke(ClusterableServerRef.java:230)
at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:477)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
at weblogic.security.service.SecurityManager.runAs(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:473)
at weblogic.rmi.internal.wls.WLSExecuteRequest.run(WLSExecuteRequest.java:118)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)

Changes

None.

Cause

This is a known issue.
java.util.concurrent.locks.Condition.await(txTimeOutMS, TimeUnit.MILLISECONDS) is called by all threads except one thread (Thread A) which has got the bean from the pool.
When Thread A releases the bean, it acquires lock and call Condition.signal() which should wake up one waiting thread. But, none of thread actually comes out of waiting state unless one of the waiting thread times out and throw RuntimeException.

Solution

To implement the solution, please execute the following steps:
1. Download and install the patch using Smart Update
    Pass ID: QE7V
    Passcode: T5QP1CXU

2. Ensure that you have taken a backup of your system before applying the recommended patch.

3. Apply the patch in a test environment.

4. Retest the issue.

5. Migrate the solution as appropriate to other environments.

References


WLS 10.3.0 - Waiting For Available Stateless Bean Instance [ID 1086380.1]



Now you can folow us on facebook and post your comments/views and questions for expert advise. Check this out facebook


Find us on facebook here