Tuesday, February 10, 2015

Using UploadJars.sh and UpdateJars.sh in Silent Mode

Description: This post shows how to use the out of the box Oracle Identity Manager JAR utilities (UploadJars.sh and UpdateJars.sh) in silent mode, which basically allows you to supply all the arguments in a single command rather than entering an input individually on each prompt.
Reference: http://docs.oracle.com/cd/E21764_01/doc.1111/e14309/uploadutil.htm#OMDEV3205

The Oracle Identity Manager JAR utilities are located in $MW_HOME/Oracle_IDM1/server/bin directory. Oracle Identity Manager stores the JAR files in the OIMHOME_JARS table.

Here are possible OIM JAR types:
ScheduleTask
ThirdParty
ICFBundle
JavaTasks

Before running these JAR utilities, APP_SERVER, OIM_ORACLE_HOME, JAVA_HOME, MW_HOME, WL_HOME, and DOMAIN_HOME environment variables need to be set.

export APP_SERVER=weblogic
export OIM_ORACLE_HOME=/home/oracle/Oracle/Middleware/Oracle_IDM1
export JAVA_HOME=/home/oracle/jrockit-jdk1.6.0_81
export MW_HOME=/home/oracle/Oracle/Middleware
export WL_HOME=/home/oracle/Oracle/Middleware/wlserver_10.3
export DOMAIN_HOME=/home/oracle/Oracle/Middleware/user_projects/domains/base_domain 

Upload Jar
To update a jar in the silent mode:
UploadJars.sh [-username <username>] [-password <password>] [-serverURL <t3://oimhost:oimport for weblogic or corbaloc:iiop:oimhost:oimport for websphere>] [-ctxFactory <weblogic.jndi.WLInitialContextFactory for weblogic or com.ibm.websphere.naming.WsnInitialContextFactory for websphere>] [-JavaTasks <Name of the jar to be updated> <Location of the Java Task Jar>

For additional information on script usage, execute the following command:
sh UploadJars.sh -help

Example:
sh UploadJars.sh -username xelsysadm -password Password1 -serverURL t3://localhost:14000 -ctxFactory weblogic.jndi.WLInitialContextFactory -JavaTasks /home/oracle/Desktop/OIMUtilities.jar

Update Jar
To update a jar in the silent mode:
UpdateJars.sh [-username <username>] [-password <password>] [-serverURL <t3://oimhost:oimport for weblogic or corbaloc:iiop:oimhost:oimport for websphere>] [-ctxFactory <weblogic.jndi.WLInitialContextFactory for weblogic or com.ibm.websphere.naming.WsnInitialContextFactory for websphere>] [-JavaTasks <Name of the jar to be updated> <Location of the Java Task Jar>

Example:
sh UpdateJars.sh -username xelsysadm -password Password1 -serverURL t3://localhost:14000 -ctxFactory weblogic.jndi.WLInitialContextFactory -JavaTasks /home/oracle/Desktop/OIMUtilities.jar


No comments:

Post a Comment