Tuesday 3 August 2021

OUAF C2M 2.8.0.0 installation on Windows64

This blog is for anyone looking to install Oracle C2M 2.8.0.0.

In this blog I have mainly tried to highlight the areas where there are differences between the installation steps for C2M 2.8 and C2M 2.7. For more detailed steps for installation refer my earlier blog for C2M 2.7.0.3 installation.

http://myouafworld.blogspot.com/2020/06/ouaf-c2m-2703-installation-on-windows64.html


Database installation steps:

For C2M 2.8.0.0, use Oracle 19c database. Please check that the database version is different from the one used in C2m 2.7.0.3.

Add Listener:








Create Database:





Login to database as sys as SYSDBA

Run below db statements.

CREATE TABLESPACE CISTS_01 LOGGING DATAFILE 'C:/c2m/database/c2m2800/oradata/C2M2800/cists01.dbf' SIZE 1024M REUSE AUTOEXTEND ON NEXT 8192K MAXSIZE UNLIMITED EXTENT MANAGEMENT LOCAL UNIFORM SIZE 1M;


CREATE ROLE CIS_USER;

CREATE ROLE CIS_READ;

GRANT CREATE SYNONYM to CIS_USER;

GRANT CREATE SYNONYM to CIS_READ;


CREATE USER CISADM IDENTIFIED BY CISADM DEFAULT TABLESPACE CISTS_01 TEMPORARY TABLESPACE TEMP PROFILE DEFAULT;

GRANT UNLIMITED TABLESPACE TO CISADM WITH ADMIN OPTION;

GRANT SELECT ANY TABLE TO CISADM;

GRANT CREATE DATABASE LINK TO CISADM;

GRANT CONNECT TO CISADM;

GRANT RESOURCE TO CISADM;

GRANT DBA TO CISADM WITH ADMIN OPTION;

GRANT CREATE ANY SYNONYM TO CISADM;

GRANT SELECT ANY DICTIONARY TO CISADM;

CREATE USER CISUSER PROFILE DEFAULT IDENTIFIED BY CISUSER DEFAULT TABLESPACE CISTS_01 TEMPORARY TABLESPACE TEMP;

GRANT SELECT ANY TABLE TO CISUSER;

GRANT CIS_USER TO CISUSER;

GRANT CIS_READ TO CISUSER;

GRANT CONNECT TO CISUSER;

CREATE USER CISOPR PROFILE DEFAULT IDENTIFIED BY OPRPLUS DEFAULT TABLESPACE CISTS_01 TEMPORARY TABLESPACE TEMP;

GRANT CONNECT, RESOURCE, EXP_FULL_DATABASE TO CISOPR;

CREATE USER CISREAD IDENTIFIED BY CISREAD DEFAULT TABLESPACE CISTS_01 TEMPORARY TABLESPACE TEMP;

GRANT SELECT ANY TABLE TO CISREAD;

GRANT CIS_READ TO CISREAD;

GRANT CONNECT TO CISREAD;




Extending String Size:

This is the first change for C2M 2.8, the database needs to be updated for extending the string size for VarChar. Refer below steps for doing the same.



SHOW PARAMETER max_string_size;


NAME            TYPE   VALUE    

--------------- ------ -------- 

max_string_size string STANDARD


Refer below oracle link for more details:

MAX_STRING_SIZE (oracle.com)


Increasing the Maximum Size of VARCHAR2, NVARCHAR2, and RAW Columns in a Non-CDB

To increase the maximum size of VARCHAR2NVARCHAR2, and RAW columns in a non-CDB:

  1. Shut down the database.

  2. Restart the database in UPGRADE mode.

  3. Change the setting of MAX_STRING_SIZE to EXTENDED.

  4. Run the rdbms/admin/utl32k.sql script. You must be connected AS SYSDBA to run the script.

  5. Restart the database in NORMAL mode.

Note:

The utl32k.sql script increases the maximum size of the VARCHAR2NVARCHAR2, and RAW columns for the views where this is required. The script does not increase the maximum size of the VARCHAR2NVARCHAR2, and RAW columns in some views because of the way the SQL for those views is written.

  1. Run the rdbms/admin/utlrp.sql script to recompile invalid objects. You must be connected AS SYSDBA to run the script.

SQLplus commands for updating database to EXTENDED

Connect to sqlplus

Connect using sys as sysdba


Shutdown database

SHUTDOWN NORMAL


Start database in upgrade mode

STARTUP UPGRADE


Update value to EXTENDED

alter system set max_string_size='EXTENDED';


Run script

@C:/myfolder/OracleDownloads/OracleDatabase/Oracle19c/V982656-01/rdbms/admin/utl32k.sql


Restart DB in Normal Mode

SHUTDOWN

STARTUP


Run script

@C:/myfolder/OracleDownloads/OracleDatabase/Oracle19c/V982656-01/rdbms/admin/utlrp.sql



SQLPlus Output Log for reference

SQL*Plus: Release 19.0.0.0.0 - Production on Sat May 29 01:40:37 2021

Version 19.3.0.0.0


Copyright (c) 1982, 2019, Oracle.  All rights reserved.




Enter user-name: sys as sysdba

Enter password:


Connected to:

Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production

Version 19.3.0.0.0


SQL> SHUTDOWN NORMAL

Database closed.

Database dismounted.

ORACLE instance shut down.

SQL> STARTUP UPGRADE

ORACLE instance started.


Total System Global Area 3841981992 bytes

Fixed Size                  9035304 bytes

Variable Size             738197504 bytes

Database Buffers         3087007744 bytes

Redo Buffers                7741440 bytes

Database mounted.

Database opened.

SQL> alter system set max_string_size='EXTENDED';


System altered.


SQL> @C:/myfolder/OracleDownloads/OracleDatabase/Oracle19c/V982656-01/rdbms/admin/utl32k.sql


Session altered.



Session altered.


DOC>#######################################################################

DOC>#######################################################################

DOC>   The following statement will cause an "ORA-01722: invalid number"

DOC>   error if the database has not been opened for UPGRADE.

DOC>

DOC>   Perform a "SHUTDOWN ABORT"  and

DOC>   restart using UPGRADE.

DOC>#######################################################################

DOC>#######################################################################

DOC>#


no rows selected


DOC>#######################################################################

DOC>#######################################################################

DOC>   The following statement will cause an "ORA-01722: invalid number"

DOC>   error if the database does not have compatible >= 12.0.0

DOC>

DOC>   Set compatible >= 12.0.0 and retry.

DOC>#######################################################################

DOC>#######################################################################

DOC>#


PL/SQL procedure successfully completed.



Session altered.



0 rows updated.



Commit complete.



System altered.



PL/SQL procedure successfully completed.



Commit complete.



System altered.



Session altered.



Session altered.



Table created.



Table created.



Table created.



Table truncated.



0 rows created.



PL/SQL procedure successfully completed.



STARTTIME

--------------------------------------------------------------------------------

05/29/2021 01:53:38.240000000



PL/SQL procedure successfully completed.


No errors.


PL/SQL procedure successfully completed.



Session altered.



Session altered.



0 rows created.



no rows selected



no rows selected


DOC>#######################################################################

DOC>#######################################################################

DOC>   The following statement will cause an "ORA-01722: invalid number"

DOC>   error if we encountered an error while modifying a column to

DOC>   account for data type length change as a result of enabling or

DOC>   disabling 32k types.

DOC>

DOC>   Contact Oracle support for assistance.

DOC>#######################################################################

DOC>#######################################################################

DOC>#


PL/SQL procedure successfully completed.



PL/SQL procedure successfully completed.



Commit complete.



Package altered.



Package altered.



Session altered.


SQL> SHUTDOWN

Database closed.

Database dismounted.

ORACLE instance shut down.

SQL> STARTUP

ORACLE instance started.


Total System Global Area 3841981992 bytes

Fixed Size                  9035304 bytes

Variable Size             738197504 bytes

Database Buffers         3087007744 bytes

Redo Buffers                7741440 bytes

Database mounted.

Database opened.


SQL> @C:/myfolder/OracleDownloads/OracleDatabase/Oracle19c/V982656-01/rdbms/admin/utlrp.sql


Session altered.



TIMESTAMP

--------------------------------------------------------------------------------

COMP_TIMESTAMP UTLRP_BGN              2021-05-29 01:59:41


DOC>   The following PL/SQL block invokes UTL_RECOMP to recompile invalid

DOC>   objects in the database. Recompilation time is proportional to the

DOC>   number of invalid objects in the database, so this command may take

DOC>   a long time to execute on a database with a large number of invalid

DOC>   objects.

DOC>

DOC>   Use the following queries to track recompilation progress:

DOC>

DOC>   1. Query returning the number of invalid objects remaining. This

DOC>      number should decrease with time.

DOC>         SELECT COUNT(*) FROM obj$ WHERE status IN (4, 5, 6);

DOC>

DOC>   2. Query returning the number of objects compiled so far. This number

DOC>      should increase with time.

DOC>         SELECT COUNT(*) FROM UTL_RECOMP_COMPILED;

DOC>

DOC>   This script automatically chooses serial or parallel recompilation

DOC>   based on the number of CPUs available (parameter cpu_count) multiplied

DOC>   by the number of threads per CPU (parameter parallel_threads_per_cpu).

DOC>   On RAC, this number is added across all RAC nodes.

DOC>

DOC>   UTL_RECOMP uses DBMS_SCHEDULER to create jobs for parallel

DOC>   recompilation. Jobs are created without instance affinity so that they

DOC>   can migrate across RAC nodes. Use the following queries to verify

DOC>   whether UTL_RECOMP jobs are being created and run correctly:

DOC>

DOC>   1. Query showing jobs created by UTL_RECOMP

DOC>         SELECT job_name FROM dba_scheduler_jobs

DOC>            WHERE job_name like 'UTL_RECOMP_SLAVE_%';

DOC>

DOC>   2. Query showing UTL_RECOMP jobs that are running

DOC>         SELECT job_name FROM dba_scheduler_running_jobs

DOC>            WHERE job_name like 'UTL_RECOMP_SLAVE_%';

DOC>#


PL/SQL procedure successfully completed.



TIMESTAMP

--------------------------------------------------------------------------------

COMP_TIMESTAMP UTLRP_END              2021-05-29 02:00:02


DOC> The following query reports the number of invalid objects.

DOC>

DOC> If the number is higher than expected, please examine the error

DOC> messages reported with each object (using SHOW ERRORS) to see if they

DOC> point to system misconfiguration or resource constraints that must be

DOC> fixed before attempting to recompile these objects.

DOC>#


OBJECTS WITH ERRORS

-------------------

                  0


DOC> The following query reports the number of exceptions caught during

DOC> recompilation. If this number is non-zero, please query the error

DOC> messages in the table UTL_RECOMP_ERRORS to see if any of these errors

DOC> are due to misconfiguration or resource constraints that must be

DOC> fixed before objects can compile successfully.

DOC> Note: Typical compilation errors (due to coding errors) are not

DOC>       logged into this table: they go into DBA_ERRORS instead.

DOC>#


ERRORS DURING RECOMPILATION

---------------------------

                          0



Function created.



PL/SQL procedure successfully completed.



Function dropped.



PL/SQL procedure successfully completed.


SQL>




Import Demo Database:


Check datapump dir location:

SELECT directory_name, directory_path FROM dba_directories where directory_name = 'DATA_PUMP_DIR';


DATA_PUMP_DIR C:\c2m\dbadmin\app\admin\c2m2800\dpdump/


Extract dmp file and place it in data pump directory




Before running import statement,

Login to sql developer with sys as sysdba and run below statement.

grant execute on dbms_rls to CISADM with grant option;




impdp directory=data_pump_dir dumpfile=exp_demo.dmp logfile=exp_demo.log schemas=CISADM








If you didn’t run the access statement for dbms_rls earlier before import, you will see that the Procedure W1_APPLY_VPD_POLICY has compilation errors as seen above. To resolve, do below steps,


Login to sql developer with sys as sysdba and run below statement.

grant execute on dbms_rls to CISADM with grant option;

Recompile the Procedure W1_APPLY_VPD_POLICY in error.



Creating Synonyms for CISUSER and CISREAD:

Extract the files in V1006660-01


C:\myfolder\OracleDownloads\C2M_2.8.0.0\V1006660-01\jarfiles



SET CLASSPATH=C:\myfolder\OracleDownloads\C2M_2.8.0.0\V1006660-01\jarfiles\*


"%JAVA_HOME%"\bin\java -Xmx1500M com.oracle.ouaf.oem.install.OraGenSec -d CISADM,CISADM,jdbc:oracle:thin:@localhost:1523/C2M2800 -u CISUSER,CISREAD -r CIS_USER,CIS_READ -a A -p CISUSER,CISREAD -l output.log






Weblogic Installation:


Download steps:

Ensure you download version 12.2.1.4 or above of weblogic


Only below file ‘V983368-01.zip’ is needed for installation.



Installation steps:



Open command prompt, navigate to above location

Run below command


C:\c2m\java\jdk\bin\java –jar fmw_12.2.1.4.0_infrastructure.jar


Below screen opens up, follow the steps shown below.










Weblogic Installation completed.



Application Installation:


Below are the steps for C2M Application installation:

  1. Install Oracle Utilities Application Framework V4.4.0.3.0
  2. Update Keystore
  3. Install Oracle Utilities Application Framework V4.4.0.3.0 Prerequisite Single Fixes
  4. Install Oracle Utilities Customer Care and Billing V2.8.0.0.0
  5. Install Oracle Utilities Customer Care and Billing V2.8.0.0.0 Post-release Patches
  6. Install Oracle Utilities Meter Data Management V2.4.0.0.0
  7. Install Oracle Utilities Operational Device Management V2.3.0.0.0
  8. Install Oracle Utilities Customer To Meter V2.8.0.0.0
  9. Install Oracle Utilities Customer To Meter V2.8.0.0.0 Post-release Patches


Framework installation:


C:\myfolder\OracleDownloads\C2M_2.8.0.0\V1006661-01.zip



Copy the file FW-V4.4.0.3.0-MultiPlatform.jar from the delivered package to the

<TEMPDIR>

cd <TEMPDIR>


jar -xvf FW-V4.4.0.3.0-MultiPlatform.jar

Update the configuration values as shown below. You can modify the port number as needed.



************************************

* Environment Installation Options *

************************************


 1. Environment ID, Roles, Third Party Software Configuration

       Environment ID:                                    10432182

       Server Roles:                                      batch,online

       Oracle Client Home Directory:                      C:\myfolder\OracleDownloads\OracleDatabase\Oracle19c\V982656...

       Web Java Home Directory:                           C:\c2m\java\jdk

       Hibernate JAR Directory:                           C:\c2m\hibernate

       ONS JAR Directory:

       Web Application Server Home Directory:             C:/c2m/weblogic/12.2.1.4.0/Oracle/Middleware/Oracle_Home/wls...

       Additional JAR Directory:


 2. Keystore Options

       Import Keystore Directory:


50. Environment Installation Options

       Environment Mount Point:                           C:/c2m/ouaf

       Log Files Mount Point:                             C:/c2m/ouaf/sploutput

       Environment Name:                                  C2M2800

       Install Application Viewer Module:                 true

       Install Sample CM Source Code:                     true


Please Note*: Below highlighted config value for JNDI password has to be same when you enter the password for system user in native weblogic configuration.

Also set Deploy application viewer to false in case you don't need it. This reduces the ear build time during installation. You can set it to true later if you need it.




*************************************

* Environment Configuration C2M2800 *

*************************************


 1. Environment Description

       Environment Description:                           c2m2800


 2. Business Application Server Configuration

       Business Server Host:                              localhost

       Business Server Application Name:                  SPLService


 3. Web Application Server Configuration

       Web Server Host:                                   localhost

       WebLogic SSL Port Number:                          6701

       WebLogic Console Port Number:                      6700

       Web Context Root:                                  ouaf

       WebLogic JNDI User ID:                             system

       WebLogic JNDI Password:                            ENCKS(****)

       WebLogic Server Name:                              c2m2800server

       Web Server Application Name:                       SPLWeb

       Deploy Application Viewer Module:                  true

       Enable The Unsecured Health Check Service:         false

       MDB RunAs User ID:                                 SYSUSER

       Super User Ids:


 4. Database Configuration

       Application Server Database User ID:               CISADM

       Application Server Database Password:              ENCKS(****)

       XAI Database User ID:                              CISADM

       XAI Database Password:                             ENCKS(****)

       Batch Database User ID:                            CISADM

       Batch Database Password:                           ENCKS(****)

       Web JDBC DataSource Name:

       Database Name:                                     C2M2800

       Database Server:                                   localhost

       Database Port:                                     1523

       ONS Server Configuration:

       Database Override Connection String:

       Character Based Database:                          false

       Oracle Client Character Set NLS_LANG:              AMERICAN_AMERICA.AL32UTF8


 5. General Configuration Options

       Batch RMI Port:                                    6740

       RMI Port number for JMX Business:                  6750

       RMI Port number for JMX Web:                       6770

       JMX Enablement System User ID:                     system

       JMX Enablement System Password:                    ENCKS(****)

       Coherence Cluster Name:                            mycluster

       Coherence Cluster Address:                         localhost

       Coherence Cluster Port:                            6903

       Coherence Cluster Mode:                            dev


 6. OUAF TrustStore Options

       Import TrustStore Directory:


Each item in the above list should be configured for a successful install.


Choose option (1,2,3,4,5,6, <P> Process, <X> Exit):



Updating keystore:


Verify keystore files are present under ks folder





1. Using configureEnv.cmd, re-enter the menu passwords to encrypt the data.

2. Run initialSetup.cmd to update property files with the encrypted data.


Next navigate to %SPLEBASE%/bin folder


Run splenviron.cmd -e C2M2703


Navigate back to bin folder

Run following commands


perl run_java_standalone.plx com.splwg.shared.common.ResetCryptographyKey


invokeDBUpdatePatch.cmd


Verify that both commands ran successfully.

This completes the configuration of OUAF keystore part of the installation



Installing Oracle Utilities Application Framework V4.4.0.3.0 Prerequisite Single Fixes:


C:\myfolder\OracleDownloads\C2M_2.8.0.0\V1008706-01.zip




Copy the file to temporary location

jar -xvf C2M-V28000-FW-PREREQ-MultiPlatform.jar


$SPLEBASE\bin\splenviron.cmd -e %SPLENVIRON%

Navigate to the <temp location>/FW-V4.4.0.3.0-Rollup/Application folder.

installSFgroup.cmd



Installing the Oracle Utilities Customer Care and Billing Application Component:

C:\myfolder\OracleDownloads\C2M_2.8.0.0\V1008715-01.zip




Copy the file CCB-V2.8.0.0.0-MultiPlatform.jar in the delivered package to a <TEMPDIR>.


cd <TEMPDIR>


jar -xvf CCB-V2.8.0.0.0-MultiPlatform.jar



$SPLEBASE\bin\splenviron.cmd -e %SPLENVIRON%


Change to the <TEMPDIR>/CCB.V2.8.0.0.0 directory.


install.cmd


Options will come up. Enter ‘P’ and click on enter. 



Installing Oracle Utilities Customer Care and Billing V2.8.0.0.0 Post-release Patches:


C:\myfolder\OracleDownloads\C2M_2.8.0.0\V1008718-01.zip



Copy the CCB-V28000-Rollup-MultiPlatform.jar file in the delivered package to a <TEMPDIR>.

2. Unjar the file.


jar -xvf CCB-V28080-Rollup-MultiPlatform.jar



$SPLEBASE\bin\splenviron.cmd -e %SPLENVIRON%


Navigate to the <temp location>/CCB-V2.8.0.0.0-Rollup/Application folder.


installSFgroup.cmd



Installing Oracle Utilities Meter Data Management V2.4.0.0.0:


C:\myfolder\OracleDownloads\C2M_2.8.0.0\V1008725-01.zip



Copy the MDM-V2.4.0.0.0-MultiPlatform.jar file in the delivered package to a <TEMPDIR>.

2. Unjar the file.



jar -xvf MDM-V2.4.0.0.0-MultiPlatform.jar


$SPLEBASE\bin\splenviron.cmd -e <ENV NAME>


Navigate to the <temp location>/MDM.V2.4.0.0.0 folder.


install.cmd


Choose option P to proceed with the installation.



Installing Oracle Utilities Operational Device Management V2.3.0.0.0:


C:\myfolder\OracleDownloads\C2M_2.8.0.0\V1008727-01.zip






Copy the WAM-V2.3.0.0.0-Multiplatform.jar file in the delivered package to a

<TEMPDIR> on your host server.

cd <TEMPDIR>

jar -xvf WAM-V2.3.0.0.0-Multiplatform.jar



splenviron.cmd -e <ENV NAME>

4. Change to the <TEMPDIR>/W1.V2.3.0.0.0 directory 


splenviron.cmd -e <ENV NAME>

install.cmd

Choose option P to proceed with the installation.




Installing Oracle Utilities Customer To Meter V2.8.0.0.0:

C:\myfolder\OracleDownloads\C2M_2.8.0.0\V1008730-01.zip


Copy the C2M.V2.8.0.0.0-MultiPlatform.jar file in the delivered package to a

<TEMPDIR> on your application server


cd <TEMPDIR>


jar -xvf C2M-V2.8.0.0.0-MultiPlatform.jar

splenviron.cmd -e <ENV NAME>

Change to the <TEMPDIR>/C2M.V2.8.0.0.0 directory.

install.cmd


Installing Oracle Utilities Customer To Meter V2.8.0.0.0 Post-release Patches:

C:\myfolder\OracleDownloads\C2M_2.8.0.0\V1008732-01.zip


Copy the C2M-V28000-Rollup-MultiPlatform.jar file in the delivered package to a

<TEMPDIR>.

Navigate to C:\temp2\C2M-V2.8.0.0.0-Rollup\Application

2. Unjar the file.

jar -xvf C2M-V28080-Rollup-MultiPlatform.jar


$SPLEBASE\bin\splenviron.cmd -e %SPLENVIRON%


Navigate to the <temp location>/C2M-V2.8.0.0.0-Rollup/Application folder.


installSFgroup.cmd

This completes the installation of C2M application.



Native installation of C2M 2.8.0.0 on Weblogic:

(Kindly also refer my latest blog for using WLST to do native installation on weblogic. It helps to reduce the time taken as well as reduces any errors. Link to blog: Native installation using WLST)

Refer below steps for deploying the C2M application on Weblogic in native mode

Ensure Oracle Restricted JRF is selected. This is need for help link to work on application.












For deploying the application on weblogic, refer the steps in my earlier blog for deploying SPLService, SPLWeb and ohelp ear files. Below is blog link for reference.

http://myouafworld.blogspot.com/2020/06/ouaf-c2m-2703-installation-on-windows64_5.html

One difference for the class path on 'Server Start' tab of c2m2800 server in weblogic admin fron end:

C:\c2m\ouaf\C2M2800\splapp\standalone\lib\antlr-2.7.7.jar;C:\c2m\weblogic\12.2.1.4.0\Oracle\Middleware\Oracle_Home\wlserver\server\lib\weblogic_sp.jar;C:\c2m\weblogic\12.2.1.4.0\Oracle\Middleware\Oracle_Home\wlserver\server\lib\weblogic.jar


Before deployment of ear files, ensure you do the below changes, the size of deployment files has increased in V2.8.0.0. Some configuration changes are needed before proceeding with deployment of SPLService and SPLWeb.



Navigate to 'C:\c2m\weblogic\12.2.1.4.0\Oracle\Middleware\Oracle_Home\user_projects\domains\c2m2800_domain\bin'

Open below file

startWebLogic.cmd

Add below line in file. Refer screenshot below for location to update.

set JAVA_OPTIONS=%JAVA_OPTIONS% -Dweblogic.deploy.MaxPostSize="2000000000"


(Max value allowed in this option is 21474836480 or 2GB)


If you don’t do above step, you might see below error when deploying SPLWeb ear file


<BEA-290076> <Total size of transferred files is "1.146" GB and it exceeded configured limit "1.074" GB.>

java.io.IOException: Posted content exceeds max post size





Also increase the heap size to 3 GB in same file.

set USER_MEM_ARGS=-Xms3072m -Xmx3072m -XX:PermSize=512m


After initial installation, you can move the heap size setting to setUserOverrides.cmd file. This is so that the heap size is applied only on the C2M server and not the weblogic admin server.

Below is step for it.

Add this file ‘setUserOverrides.cmd’ in “C:\c2m\weblogic\12.2.1.4.0\Oracle\Middleware\Oracle_Home\user_projects\domains\c2m2800_domain\bin” location.

The sample file for ‘setUserOverrides.cmd’ is available in following location “C:\c2m\ouaf\C2M2800\tools\examples\bin”

setUserOverrides.cmd content for reference

@echo off

REM

REM This is a WebLogic domain customized domain overide utility to ensure the appropriate environmental values are set for the domain startup

REM

REM


echo %SPLEBASE%


if "%SERVER_NAME%"=="c2m2800server" (

set SPLEBASE=C:\c2m\ouaf\C2M2800

set USER_MEM_ARGS=-Xms3072m -Xmx3072m -XX:PermSize=512m

set JAVA_OPTIONS=-Xdebug -Xnoagent -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=7758 %JAVA_OPTIONS%

)



if "%SPLEBASE%" == "" (

   echo SPLEBASE needs to be set in environment

   exit /b 0

)


if "%TRUST_TYPE%" == "DEMO" (

   set JAVA_OPTIONS=%JAVA_OPTIONS% -Dweblogic.security.TrustKeyStore=DemoTrust

)


if "%USER_MEM_ARGS%" == "" (

   set USER_MEM_ARGS=-Xms1024m -Xmx2048m

)


set JAVA_OPTIONS=-XX:CompileThreshold=8000 -Djava.security.auth.login.config=%SPLEBASE%\splapp\config\java.login.config -Dfile.encoding=UTF8 -Djavax.xml.soap.MessageFactory=com.sun.xml.internal.messaging.saaj.soap.ver1_1.SOAPMessageFactory1_1Impl -Djavax.xml.soap.SOAPConnectionFactory=weblogic.wsee.saaj.SOAPConnectionFactoryImpl -Dcom.sun.xml.ws.fault.SOAPFaultBuilder.disableCaptureStackTrace=false -Dcom.sun.xml.namespace.QName.useCompatibleSerialVersionUID=1.0 -XX:+UnlockCommercialFeatures -XX:+FlightRecorder -Dweblogic.security.SSL.ignoreHostnameVerification=true -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=C:\temp -Djava.net.preferIPv4Stack=true %JAVA_OPTIONS%


REM set OUAF_DEBUG_PORT (E.g. set OUAF_DEBUG_PORT=6599) prior to starting to enable server debugging 

if DEFINED OUAF_DEBUG_PORT (

   set JAVA_OPTIONS=-Xdebug -Xnoagent -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=%OUAF_DEBUG_PORT% %JAVA_OPTIONS%

)


echo SPLEBASE %SPLEBASE%

echo SERVER_NAME %SERVER_NAME%


This completes the steps to deploy the C2M application. You can start the C2M server and verify that it is running. Refer my earlier blog for the steps.


IWS Deployment

Added the steps for IWS deployment in weblogic native mode

Admin server and C2M server should be up and running.

In below command, 7010 port number is weblogic admin port number. Update the port number in the command with the port number configured in your system.

Connect to oracle database

Login as SYS user.
2. On the SQL prompt, run:
@?/rdbms/admin/userlock.sql
3. Grant permission.
grant execute on USER_LOCK to public;


Go to command prompt

Go to $WeblogicHome\oracle_common\common\bin

Run below commands

wlst.cmd
connect("weblogicuser","password","t3://localhost:weblogicAdminconsoleport")
storeUserConfig('$SPLBASE/etc/.wlsuserconfig',' $SPLBASE/etc/.wlsuserkey')


connect("weblogic","password","t3://localhost:7010")

storeUserConfig('C:/c2m/ouaf/C2M2800/etc/.wlsuserconfig','C:/c2m/ouaf/C2M2800/etc/.wlsuserkey')

Navigate to etc folder as shown below, you can see that the .wlsuserconfg and .wlsuserkey files have got created.



Navigate to “C:\c2m\ouaf\C2M2800\splapp\iws” and update below file

iws-build-WLS.xml

  <property name="web.admin.url"         value="t3://localhost:7010" />


Navigate to below file and do the highlighted updates for Heap size

iws-build-common.xml


  <target name="generate" depends="clean">

    <echo message="Running IWS generator. Please wait..." />

    <property name="logprop" value="${gen.home.dir}/config/log4j2.properties" />

    <echo file="${logprop}" append="false" message="status=error${nl}" />

    <echo file="${logprop}" append="true" message="name=PropertiesConfig${nl}" />

    <echo file="${logprop}" append="true" message="appender.A1.type=Console${nl}" />

    <echo file="${logprop}" append="true" message="appender.A1.name=A1${nl}" />

<echo file="${logprop}" append="true" message="appender.A1.layout.type=PatternLayout${nl}" />

<echo file="${logprop}" append="true" message="appender.A1.layout.pattern=%X{userId} - %X{transactionId} %d [%t] %-5p (%c{3}) %m%n${nl}" />

    <java classname="com.oracle.ouaf.ws.tools.artifactgen.InboundWebserviceGenerator" fork="true" failonerror="true">

      <jvmarg value="-Xmx2048m" />

      <jvmarg value="-Xms2048m" />


splenviron.cmd -e <ENV NAME>

Execute the following command in %SPLEBASE%\bin. Make sure the application

server is up and running.


iwsdeploy.cmd

Command should run successfully without any errors.

Next login to weblogic admin and go to deployments, you should see Webservice.ear fiel deployed and Active.


Testing Webservice with SOAPUI.

Refer below steps for testing webservice is working after deployment

Open below OOB webservice and open its wsdl

Click on the WSDL link and open below WSDL. Copy the WSDL url

https://localhost:6701/ouaf/webservices/D1-DeviceEventSeeder?WSDL


Open SOAP UI, open new SOAP project. Copy the WSDL url here.

Navigate to Request 1

Update the Request1 with below request xml

Sample xml below for reference

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:d1="http://ouaf.oracle.com/webservices/d1/D1-DeviceEventSeeder">

   <soapenv:Header/>

   <soapenv:Body>

      <d1:D1-DeviceEventSeeder>

         <d1:externalSenderId>SENSUS</d1:externalSenderId>

         <d1:deviceEventType>DEVICELOWBATTERY</d1:deviceEventType>

         <d1:eventDateTime>2020-05-29T10:20:15</d1:eventDateTime>

         <d1:deviceId>272059640649</d1:deviceId>

      </d1:D1-DeviceEventSeeder>

   </soapenv:Body>

</soapenv:Envelope>


Update the username and password in the request properties. Set WSS-Password Type to ‘PasswordText’ and set WSS TimeToLive to ‘72’


Now run the request, if the webservice deployment is proper, you should see a successful response as seen below.


OUAF Oracle Utilities WAM / ODM 2.4.0.0 installation on Windows

  This blog is for anyone looking to install Oracle Utilities WAM or ODM 2.4.0.0 (Oracle Utilities Workflow and Asset Management) or (Orac...