Tuesday, November 27, 2012

ORA-00001: unique constraint (PROD_SOAINFRA.AT_PK) violated

Hello,
I was seeing a huge amount of errors pertaining to AT_PK table ,

============

####<Nov 27, 2012 3:01:57 AM CET> <Error> <EJB> <host> <WLS_SOA1> <orabpel.audit.pool-3.thread-4> <<anonymous>> <> <0000JfFsuuR6eLMaELq2US1G_pet000IDr> <1353981717680> <BEA-010026> <Exception occurred during commit of transaction Name=[EJB com.collaxa.cube.engine.ejb.impl.bpel.BPELAuditTrailBean.storeAuditBatch(com.collaxa.cube.engine.audit.BatchEvent,com.collaxa.cube.persistence.dto.AuditCounter)],Xid=BEA1-074BC784ED925837639D(810973762),Status=Rolled back. [Reason=Exception [EclipseLink-4002] (Eclipse Persistence Services - 2.1.3.v20110304-r9073): org.eclipse.persistence.exceptions.DatabaseException
Internal Exception: java.sql.SQLIntegrityConstraintViolationException: ORA-00001: unique constraint (PROD_SOAINFRA.AT_PK) violated

Error Code: 1
Call: INSERT INTO AUDIT_TRAIL (CIKEY, COUNT_ID, NUM_OF_EVENTS, BLOCK_USIZE, CI_PARTITION_DATE, BLOCK_CSIZE, BLOCK, LOG) VALUES (?, ?, ?, ?, ?, ?, ?, ?)
        bind => [305173755, 0, 39, 11816, 2012-11-27 03:01:51.677, 1891, 0, [B@30572981]

Solution as per: Doc ID 1338478.1

They suggest to apply the patch ,will apply this and see if issue gets fixed.


Saturday, November 24, 2012

IPM Web Support Server Logging

IPM 10g is a very old and stable product. Once you set it up, it goes very smoothly.But this customer wanted to enable logging ,i followed the below procedure.


To enable logging, perform the following steps:

   1. Login to IBPMExpress client (typical URL to log in to IBPMExpress: http://ServerName/ibpmexpress).
   2. Click on Administration (located in the left pane).
      Note: If you do not see Administration then the user you logged in as has not been given Web Administration Privileges through IPM Security Policies.
   3. Scroll down to the Diagnostics Section.
   4. Enter in a valid location for Real Time Log File Location.
   5. Checkbox the following options:
      a) Trace all available reporting points
      b) Trace all datasets
      c) Trace all outbound notifications
      d) Trace Key Points
      e) Use Realtime Logging
   6. Restart the Oracle Web Support Server service.


The above options can also be found in the WSSConfigEditor.exe tool which is located in the install directory.  (Example location: C:\Program Files\Stellent\WSS\WSSConfigEditor.exe)

Friday, November 23, 2012

Upgrade Oid Status Shows Invalid In dba_registry and app_registry tables

I usually don't work on 11g OID,but was helping out a team here.Issue comes on OID version 10.1.2.0.2 to 10.1.4.3

OID showing as INVALID in dba_registry and app_registry tables.

select * from dba_registry where status='INVALID' and
select * from app_registry where status ='INVALID'


OID shows invalid.

OID 10.1.4.0.1 INVALID

OID showing as invalid in dba_registry and app_registry tables, however when viewing ODS objects -- all are valid
SQL> select owner,object_name,object_type from dba_objects where owner='ODS' and status='INVALID'; 

This could be caused due to possible problem with upgrade script (oidiugrd.sql).OID showing as invalid in dba_registry and app_registry tables, however when viewing ODS objects -- all are valid

Errors can be found in  $ORACLE_HOME/ldap/admin/LOGS/ldapupgrade.log

Fix
===
Check the ODS schema for invalid objects and correct as necessary

% sqlplus / as sysdba
SQL> select owner,object_name,object_type from dba_objects
2> where owner='ODS' and status='INVALID';

Cut the final validation portion of oidiugrd.sql and run it by itself:

alter session set current_schema = SYS;

execute DBMS_IAS_VERSION.SET_COMPONENT_UPGRADED(COMPONENT_ID=>'OID');
declare
rc integer;
begin
rc := ods.ldapUpgUtls.validateODS();
if rc = 0 then
DBMS_IAS_VERSION.SET_COMPONENT_VALID(COMPONENT_ID=>'OID');
else
DBMS_IAS_VERSION.SET_COMPONENT_INVALID(COMPONENT_ID=>'OID');
end if;
end;
/ 

 
 

Register OHS 11g

Sometime after upgrade on fusion we get issues with ohs.ohs shows as down on em, despite being up.We have faced this many times, so we have included below steps after all fusion upgrades.



--------UNREGISTER OHS ---------------------------
-bash-3.2$ ./opmnctl unregisterinstance -instanceName ohs1 -adminHost host -adminPort port

Command requires login to weblogic admin server (host):
  Username: weblogic
  Password:

Unregistering instance
Command succeeded.

--------REDEPLOY OHS ---------------------------
-bash-3.2$ ./opmnctl redeploy -adminHost host -adminPort port


Command requires login to weblogic admin server (host):
  Username: ohsadmin
  Password:

Redeploying NonJ2EEManagement Application...weblogic.Deployer invoked with options:  -adminurl vmohsautr048.oracleoutsourcing.com:45501 -username ohsadmin -name NonJ2EEManagement -source /test/fmw/product/111/ohs/opmn/applications/NonJ2EEManagement.ear -redeploy -upload -noexit
<Apr 24, 2012 3:25:01 PM CDT> <Info> <J2EE Deployment SPI> <BEA-260121> <Initiating redeploy operation for application, NonJ2EEManagement [archive: test/fmw/product/111/ohs/opmn/applications/NonJ2EEManagement.ear], to configured targets.>
Task 0 initiated: [Deployer:149026]deploy application NonJ2EEManagement [Version=11.1.1] on AdminServer.
Task 0 completed: [Deployer:149026]deploy application NonJ2EEManagement [Version=11.1.1] on AdminServer.
Target state: redeploy completed on Server AdminServer

Done
Command succeeded.

--------REGISTER OHS ---------------------------
 ./opmnctl registerinstance -adminHost host -adminPort port

Command requires login to weblogic admin server (host):
  Username: weblogic
  Password:

Registering instance
Command succeeded.


-adminHost is the weblogic admin server
-adminPort is the port for the admin server

Kill particular OS process


ps -ef |grep <Process> |awk '{print  $2}'|xargs kill -9

For example:
ps -ef |grep LOCAL=NO |awk '{print  $2}'|xargs kill -9