Thursday, March 10, 2016

APEX 5 upgrade/Install on 12c Oracle DB (12.1.0.2.0)


1. Apex 5 downloaded from otn.oracle.com
2. Patch #20618595 (For a 12.1.0.2.0 database)

Down the DB and listener.

Run the "CheckConflictAgainstOHWithDetail"
Once above check is Passed apply the patch:
export PATH=$PATH:$HOME:$ORACLE_HOME/OPatch:/bin
Go to the PATCH Directory and opatch apply.
Now need  to upgrade all PDBs with the new patch we applied. This is done with a utility called datapatch. 
datapatch
Create 3 tablespace for APEX:

create tablespace APEXFILE datafile '/apps/apexora/app/apexora/oradata/APEXORA/APEXFILE.dbf'size                                  100Mautoextend on maxsize                2000Mextent management local uniform size  64K;
create tablespace APEXUSER datafile '/apps/apexora/app/apexora/oradata/APEXORA/APEXUSER.dbf'size                                  100Mautoextend on maxsize                2000Mextent management local uniform size  64K;

create tablespace APEXEBS datafile '/apps/apexora/app/apexora/oradata/APEXORA/APEXEBS.dbf'size                                  100Mautoextend on maxsize                2000Mextent management local uniform size  64K;

Now rename the apex 4.2 home to apex_old
mv apex apex_old 

unzip apex_5.0_en.zip in any location and mv apex to $ORACLE_HOME.

cd $ORACLE_HOME/apex
start up sqlplus as sys
sqlplus / as sysdba
@apexins.sql APEXEBS APEXFILE TEMP /i/ 

Once upgrade finish check the APEX version:

SQL> select version from sys.dba_registry where comp_id = 'APEX';.



next i ran rest-config sql 

SQL> @apex_rest_config_cdb.sql this is also completed with out any issue. 

@reset_image_prefix_con.sql this is also completed with out any issue. 


These two are key sql for APEX5 on 12c CDB installation.

SQL> select version from sys.dba_registry where comp_id = 'APEX'; 

VERSION 
------------------------------ 
5.0.3.00.03 

Thursday, March 3, 2016

OAM login page Error

After Integration OAM with EBS and Accessgate.I got some starange Error as below:

while login to EBs Page it is not redirect to OAM Page throwing error

7777/ebsauth_test/dossologin not found

After research I found that I missed the configuration in ebs_oam.conf file as below

cd $RREG_HOME/bin/ebs.oam.conf
protected_uris ########################### /ebsauth_{instance} /index.html

I added the instance name on ebs.oam.conf file thena fter I re ran "./bin/oamreg.sh inband inout/EBS_OAM11gRequest_short.html" script to update .

And copy the ObAccessClient.xml ,cwallet.sso files from cd $RREG_HOME/output/agent_name/ to

cd /apps/oemora/Oracle/Middleware/Oracle_WT1/instances/instance1/config/OHS/ohs1/webgate/config/.

Once files are copied then you ahve to bounce the ./opmnctl .

Go to cd /apps/oemora/Oracle/Middleware/Oracle_WT1/instances/instance1/bin/
./opmnctl stopall
and
./opmnctl startall

Then after check your eag_domaiin admin and managed server status those should Up and running.
 try to login with your EBS login Page it is redirect to OAM Console Page and login with orcladmin it is redirect to sysadmin/password enter the credentials your into EBS Home page.

OAM Integration is completed.

Friday, February 26, 2016

Unable to find keystore "default-keystore.jks" in /config/fmwconfig/.

Unable to find keystore "default-keystore.jks" in /config/fmwconfig/.

It's worth noting that the above actions are necessary as part of the installation. There's two config.sh files, 1. in the OIM-HOME/common/bin (which is for the installation of the OFM) and 2. the OIM-HOME/bin (for the configuration). If you don't complete the latter phase, you are likely to get the following error: 
...
Truncated. see log file for complete stacktrace
Caused By: oracle.iam.platform.utils.OIMAppInitializationException: 
OIM application initialization failed because of the following reasons:
oim-config.xml was not found in MDS Repository.
Unable to find keystore "default-keystore.jks" in /config/fmwconfig/. 
Unable to find keystore ".xldatabasekey" in /config/fmwconfig/. 
Password for OIMSchemaPassword is not seeded in CSF.
Password for xell is not seeded in CSF.
Password for DataBaseKey is not seeded in CSF.
Password for JMSKey is not seeded in CSF.
Password for .xldatabasekey is not seeded in CSF.
Password for default-keystore.jks is not seeded in CSF.
Password for SOAAdminPassword is not seeded in CSF.
at oracle.iam.platform.utils.OIMAppInitializationListener.preStart(OIMAppInitializationListener.java:157)


Solution:

Just because of you are starting WLS_OIM1 Managed server before configured OIM.

Please go to $IAM_HOME/bin/config.sh and configure the OIM.Then after start the WLS_OIM1 managed server.This error will not re appear on WLS_OIM1 log files.

Saturday, February 6, 2016

Oracle Access Manager 11g not Returning ORCLGUID to the Webgate

OAM Test Response Headers ORCLGUID value show "NOTFOUND or "NULL" as show below

HTTP_USER_NAME="EBSADMIN"
HTTP_USER_ORCLGUID="NOT_FOUND"

Please follow below solution:

1. Take a backup of oam-config,xml from $DOMAIN_HOME/config/fmwconfig directory.
2. Edit oam-config.xml file and add the following parameter and value for the concerned directory server.
Type="xsd:string">orclguid
OR
Navigate to "User Identity Stores" in OAM Console and then to the specific LDAP store in concern and add the relevant attributes under the section "Prefetched Attributes" 3. Restart the managed server. Attribute value would be displayed in header on access to the protected resource.

Bug 19438948
This issue occurs when Oracle Access Manager 11gR2 Bundle Patch 2 (BP2) or Oracle Access Manager 11gR2 Patchset 2 (PS2) have been applied:
When testing response headers in step 4.4.3 a null value is returned for USER_ORCLGUID, instead of a valid value
OR
When a user attempts to login to Oracle E-Business Suite, after entering their credentials the following error is displayed in the browser:
Internal Error: Webgate allowed access to protected page GUID=null
As a workaround specify 'orclguid' as a 'Prefetched Attribute' in Oracle Access Manager:
Logon to the OAM Console:
http://.:/oamconsole
Click 'User Identity Stores' (in the 'Configuration' section) > select the Identity Store with a type of 'OID' (e.g. 'EBSIdStore' or 'OIDIdentityStore') in the 'OAM ID Stores' table >
Click 'Edit' > Enter orclguid in the 'Prefetched Attributes' field and click 'Apply' to save

Internal Exception: java.sql.SQLException: ORA-28001: the password has expired while starting Weblogic Services

Please follow the below NOTE for any user expired error:


The Impact of PASSWORD_LIFE_TIME Database Profile Parameter Default to 180 Days on Network Charging and Control (Doc ID 1543668.1)

ORA-28000: the account is locked
If the login occurs via the SMS Screens, the Java console should show:
 Exception raised is --->28001
 java.sql.SQLException: ORA-28001: the password has expired


Login to database as sysdba
SQL> connect / as sysdba
3. Set the lines & pages formatting to better format the output
SQL> set lines 99
SQL> set pages 999
4. Get the current DEFAULT profile
SQL> select resource_name, limit from dba_profiles where profile = 'DEFAULT' order by 1;
5. Set PASSWORD_LIFE_TIME to UNLIMITED
SQL> alter profile DEFAULT limit PASSWORD_LIFE_TIME UNLIMITED;
Run the ALTER USER command for any user that is already in "EXPIRED (GRACE)" & "EXPIRED" state.
6. Identify any user that is already in "EXPIRED (GRACE)" & "EXPIRED" state
SQL> select username, profile, account_status from dba_users where account_status in ('EXPIRED(GRACE)', 'EXPIRED') order by 1;


To reset the user password, you will need to query both password & spare4 column in user$ table, which stores a hash value of case insensitive password and case sensitive password respectively. You can use the following SQL command to generate a complete "alter user ..." syntax for a specific user:
SQL> select sqltext from
(
    select name, 'alter user '||name||' identified by values '''||password||''';' sqltext from user$ where spare4 is null and password is not null
    union
    select name, 'alter user '||name||' identified by values '''||spare4||';'||password||''';' sqltext from user$ where spare4 is not null and password is not null
) where name = ;
Example:
SQL> select sqltext from (select name, 'alter user '||name||' identified by values '''||password||''';' sqltext from user$ where spare4 is null and password is not null  union  select name, 'alter user '||name||' identified by values '''||spare4||';'||password||''';' sqltext from user$ where spare4 is not null and password is not null ) where name = 'DEV_OMSM';
SQLTEXT
--------------------------------------------------------------------------------
alter user DEV_OMSM identified by values 'S:33F61566C1D2238C8B8C13B20918D7BAE1DE
1D1D2498BD50C3742D6F0FB1;A63CD969AFE9D774';
SQL> alter user DEV_OMSM identified by values 'S:33F61566C1D2238C8B8C13B20918D7BAE1DE1D1D2498BD50C3742D6F0FB1;A63CD969AFE9D774';
User altered.
SQL> commit;
Commit complete.