Tag Archives: change

R12.1 R12.2 Oracle eBusiness Suite – Moving FNDLOAD files by script

Oracle eBusiness Suite Logo
Oracle eBusiness Suite Logo

Most administrators become familiar with the FNDLOAD utility ($FND_TOP/bin/FNDLOAD) which is used to move various objects between instances that have been defined and set up using the front-end (Menus, FlexField setups, Users, Alerts, Concurrent Programs, et.al.)

Yes, you can manually re-enter all that information using the front-end forms and OAF pages, but you do have a utility to do that for you: FNDLOAD.

Typing FNDLOAD by itself with no parameters gives you a general idea of what kinds of parameters it takes:

You have not provided the required arguments for this program.
Usage: FNDLOAD logon 0 Y mode configfile datafile [ entity [ param ... ] ]

where
logon is username/password[@connect]
mode is either UPLOAD or DOWNLOAD
configfile is the configuration file
datafile is the data file
entity is an entity name, or - to specify all values in an upload
param is a NAME=VALUE string used for parameter substitution

But you can, like most of these utilities, create a script wrapper which makes the process more driven to support repetitive change migrations.

Here’s an example using many of the various parameters in a format that simply downloads the object from the source instance and uploads the resulting *.ldt file into the target instance.  Just comment out things you don’t want (or isn’t supported by your particular EBS version) and add new objects as they become supported by FNDLOAD in the future.

# $1 FRSID From Instance sample: apps/apps@DEV1.world
# $2 TYPE: CONC Concurrent Program
# RGRP Request Group
# FORM Form Function
# FDFF Descriptive FlexField
# VSET FND Value Set
# MENU Menu
# ALRT Oracle Alert
# FLDR Folder
# MESG Oracle Message
# LKUP Lookup Values
# USER FND User
# RPROF Responsibility Profile Level
# PROF Profile with no Level specific
# RSET RequestSet
# RSLK RequestSet Links
# RESP Responsibility
# FPER Form Personalization
# XMLT XML Template
# XLAD XLA Definitions
# WADIINTG Web ADI Integrator
# WADILAYO Web ADI Layout
# WADIMAPC Web ADI Mapping Code
# WADISTYL Web ADI Style
# PJSTAT Project Statuses
# ATTCAT Attachment Categories
# $3 OBJECT Object Short Name, Function Name, Responsibility Key, Etc.
# $4 APPL_SN Application ShortName
# $5 TOSID Destination Instance sample: apps/apps@DEV2.world
#
FRSID=$1
ATYP=$2
AOBJ="$3"
AASN=$4
TOSID=$5

fpwd=`echo $FRSID|awk '{FS="/"} {print $2}'|awk '{FS="@"} {print $1}'`
fsid=`echo $FRSID|awk '{FS="@"} {print toupper($2)}'`

tpwd=`echo $TOSID|awk '{FS="/"} {print $2}'|awk '{FS="@"} {print $1}'`
tsid=`echo $TOSID|awk '{FS="@"} {print toupper($2)}'`


fdbline=`tnsping $fsid|awk '/Attempting/ {print $0}'`
ffullhname=`echo $fdbline|awk '{print $5}'|awk '{FS="="} {print $4}'|awk '{FS=")"} {print $1}'`
fhport=`echo $fdbline|awk '{print $5}'|awk '{FS="="} {print $5}'|awk '{FS=")"} {print $1}'`
fhname=`echo $ffullhname|awk '{print $1}'|awk '{FS="."} {print $1}'`

tdbline=`tnsping $tsid|awk '/Attempting/ {print $0}'`
tfullhname=`echo $tdbline|awk '{print $5}'|awk '{FS="="} {print $4}'|awk '{FS=")"} {print $1}'`
thport=`echo $tdbline|awk '{print $5}'|awk '{FS="="} {print $5}'|awk '{FS=")"} {print $1}'`
thname=`echo $tfullhname|awk '{print $1}'|awk '{FS="."} {print $1}'`


tdbline=`tnsping $tsid|awk '/Attempting/ {print $0}'`
tfullhname=`echo $tdbline|awk '{print $5}'|awk '{FS="="} {print $4}'|awk '{FS=")"} {print $1}'`
thport=`echo $tdbline|awk '{print $5}'|awk '{FS="="} {print $5}'|awk '{FS=")"} {print $1}'`
thname=`echo $tfullhname|awk '{print $1}'|awk '{FS="."} {print $1}'`

sqlsmt=""
sqlsmt=$sqlsmt" select 'XMLT:'||DS_APP_SHORT_NAME||':'||DATA_SOURCE_CODE||': '"
sqlsmt=$sqlsmt" from xdo.xdo_templates_b "
sqlsmt=$sqlsmt" where template_code = '"$AOBJ"' "
sqlsmt=$sqlsmt" and application_short_name = '"$AASN"';"
sqlout=`echo $sqlsmt | sqlplus -s $FRSID`

DSASN=`echo $sqlout|awk '{FS=":"} {print $5}'`
DSCODE=`echo $sqlout|awk '{FS=":"} {print $6}'`

rtime=`date +%m%d%H%M%S`

if (test $ATYP = "CONC") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/afcpprog.lct "$AOBJ".ldt PROGRAM APPLICATION_SHORT_NAME=$AASN CONCURRENT_PROGRAM_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afcpprog.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "FORM") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/afsload.lct "$AOBJ".ldt FUNCTION FUNCTION_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afsload.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "ATTCAT") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/afattach.lct "$AOBJ".ldt FND_DOCUMENT_CATEGORIES CATEGORY_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afattach.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "RGRP") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/afcpreqg.lct "$AOBJ".ldt REQUEST_GROUP APPLICATION_SHORT_NAME=$AASN REQUEST_GROUP_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afcpreqg.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "FDFF") then
FNDLOAD $FRSID O Y DOWNLOAD $FND_TOP/patch/115/import/afffload.lct "$AOBJ".ldt DESC_FLEX APPLICATION_SHORT_NAME=$AASN DESCRIPTIVE_FLEXFIELD_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afffload.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "VSET") then
FNDLOAD $FRSID O Y DOWNLOAD $FND_TOP/patch/115/import/afffload.lct "$AOBJ".ldt VALUE_SET FLEX_VALUE_SET_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afffload.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "MENU") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/afsload.lct "$AOBJ".ldt MENU MENU_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afsload.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=REPLACE
elif (test $ATYP = "ALRT") then
FNDLOAD $FRSID 0 Y DOWNLOAD $ALR_TOP/patch/115/import/alr.lct "$AOBJ".ldt ALR_ALERTS APPLICATION_SHORT_NAME=$AASN ALERT_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $ALR_TOP/patch/115/import/alr.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "FLDR") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/fndfold.lct "$AOBJ".ldt FND_FOLDERS NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/fndfold.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "MESG") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/afmdmsg.lct "$AOBJ".ldt FND_NEW_MESSAGES APPLICATION_SHORT_NAME=$AASN MESSAGE_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afmdmsg.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "LKUP") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/aflvmlu.lct "$AOBJ".ldt FND_LOOKUP_TYPE APPLICATION_SHORT_NAME=$AASN LOOKUP_TYPE="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/aflvmlu.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "USER") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/afscursp.lct "$AOBJ".ldt FND_USER USER_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afscursp.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "PROF") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/afscprof.lct "$AOBJ".ldt PROFILE APPLICATION_SHORT_NAME=$AASN PROFILE_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afscprof.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "RPROF") then
FNDLOAD $FRSID 0 Y DOWNLOAD afscprofr.lct "$AOBJ".ldt PROFILE APPLICATION_SHORT_NAME=$AASN PROFILE_NAME="$AOBJ" FND_PROFILE_OPTION_VALUES LEV="10003"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afscprof.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "RSET") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/afcprset.lct "$AOBJ".ldt REQ_SET REQUEST_SET_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afcprset.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/afcprset.lct "$AOBJ"_LINK.ldt REQ_SET_LINKS REQUEST_SET_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afcprset.lct "$AOBJ"_LINK.ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "RELK") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/afcprset.lct "$AOBJ".ldt REQ_SET_LINKS REQUEST_SET_NAME="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afcprset.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "RESP") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/afscursp.lct "$AOBJ".ldt FND_RESPONSIBILITY RESP_KEY="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/afscursp.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "FPER") then
FNDLOAD $FRSID 0 Y DOWNLOAD $FND_TOP/patch/115/import/affrmcus.lct "$AOBJ".ldt FND_FORM_CUSTOM_RULES function_name="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $FND_TOP/patch/115/import/affrmcus.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "XMLT") then
FNDLOAD $FRSID 0 Y DOWNLOAD $XDO_TOP/patch/115/import/xdotmpl.lct "$AOBJ".ldt XDO_DS_DEFINITIONS APPLICATION_SHORT_NAME=$AASN DATA_SOURCE_CODE="$DSCODE" TMPL_APP_SHORT_NAME=$DSASN TEMPLATE_CODE="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $XDO_TOP/patch/115/import/xdotmpl.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE

sqlsmt=""
sqlsmt=$sqlsmt"select distinct 'XMLTYPE:'||xdo_file_type||':'||file_content_type||':'||"'\n'
sqlsmt=$sqlsmt" decode(file_content_type,'application/rtf','rtf', "'\n'
sqlsmt=$sqlsmt" 'text/xml', 'xml', "'\n'
sqlsmt=$sqlsmt" lower(xdo_file_type))||':'||territory||':'||replace(file_name,' ','_')||':' xtype"'\n'
sqlsmt=$sqlsmt" from xdo.xdo_lobs "'\n'
sqlsmt=$sqlsmt" where application_short_name = '"$AASN"' "'\n'
sqlsmt=$sqlsmt" and lob_type = 'TEMPLATE_SOURCE' "'\n'
sqlsmt=$sqlsmt" and lob_code = '"$AOBJ"'; "'\n'
sqlsmt=$sqlsmt"exit "'\n'
echo $sqlsmt > $rtime.sql
sqlplus -s $FRSID @$rtime.sql > $rtime.out

for i in `awk '/XMLTYPE/ {print $0}' $rtime.out`
do
ftype=`echo $i|awk '{FS=":"} {print $2}'`
ctype=`echo $i|awk '{FS=":"} {print $3}'`
fext=`echo $i|awk '{FS=":"} {print $4}'`
terr=`echo $i|awk '{FS=":"} {print $5}'`
filename=`echo $i|awk '{FS=":"} {print $6}'|awk '{FS="."} {print $1}'`
sname=`echo $i|awk '{FS=":"} {print $6}'`
if (test $terr = "00") then
fname="TEMPLATE_SOURCE_"$AASN"_"$AOBJ"_en".$fext
else
fname="TEMPLATE_SOURCE_"$AASN"_"$AOBJ"_en_"$terr.$fext
fi
java oracle.apps.xdo.oa.util.XDOLoader DOWNLOAD -DB_USERNAME apps -DB_PASSWORD $fpwd -JDBC_CONNECTION "$fhname:$fhport:$fsid" -APPS_SHORT_NAME $AASN -LOB_TYPE TEMPLATE_SOURCE -LOB_CODE "$AOBJ" -XDO_FILE_TYPE $ftype -FILE_NAME $sname -LANGUAGE en -TERRITORY $terr -LCT_FILE $XDO_TOP/patch/115/import/xdotmpl.lct -LOG_FILE "$filename".log
mv "$fname" "$sname"
java oracle.apps.xdo.oa.util.XDOLoader UPLOAD -DB_USERNAME apps -DB_PASSWORD $tpwd -JDBC_CONNECTION "$thname:$thport:$tsid" -APPS_SHORT_NAME $AASN -LOB_TYPE TEMPLATE_SOURCE -LOB_CODE "$AOBJ" -XDO_FILE_TYPE $ftype -FILE_CONTENT_TYPE "$ctype" -FILE_NAME "$sname" -LANGUAGE en -TERRITORY $terr -LCT_FILE $XDO_TOP/patch/115/import/xdotmpl.lct -LDT_FILE "$AOBJ".ldt -DRVX_FILE "$AOBJ".drvx -LOG_FILE "$filename".log -CUSTOM_MODE FORCE
done
elif (test $ATYP = "XMLD") then
sqlsmt=""
sqlsmt=$sqlsmt"select distinct 'XMLTYPE:'||xdo_file_type||':'||file_content_type||':'||"'\n'
sqlsmt=$sqlsmt" decode(file_content_type,'application/rtf','rtf', "'\n'
sqlsmt=$sqlsmt" 'text/xml', 'xml', "'\n'
sqlsmt=$sqlsmt" lower(xdo_file_type))||':'||territory||':'||replace(file_name,' ','_')||':' xtype"'\n'
sqlsmt=$sqlsmt" from xdo.xdo_lobs "'\n'
sqlsmt=$sqlsmt" where application_short_name = '"$AASN"' "'\n'
sqlsmt=$sqlsmt" and lob_type = 'DATA_TEMPLATE' "'\n'
sqlsmt=$sqlsmt" and lob_code = '"$AOBJ"'; "'\n'
sqlsmt=$sqlsmt"exit "'\n'
echo $sqlsmt > $rtime.sql
sqlplus -s $FRSID @$rtime.sql > $rtime.out

for i in `awk '/XMLTYPE/ {print $0}' $rtime.out`
do
ftype=`echo $i|awk '{FS=":"} {print $2}'`
ctype=`echo $i|awk '{FS=":"} {print $3}'`
fext=`echo $i|awk '{FS=":"} {print $4}'`
terr=`echo $i|awk '{FS=":"} {print $5}'`
filename=`echo $i|awk '{FS=":"} {print $6}'|awk '{FS="."} {print $1}'`
sname=`echo $i|awk '{FS=":"} {print $6}'`
fname="DATA_TEMPLATE_"$AASN"_$AOBJ"
java oracle.apps.xdo.oa.util.XDOLoader DOWNLOAD -DB_USERNAME apps -DB_PASSWORD $fpwd -JDBC_CONNECTION "$fhname:$fhport:$fsid" -APPS_SHORT_NAME $AASN -LOB_TYPE DATA_TEMPLATE -LOB_CODE "$AOBJ" -XDO_FILE_TYPE $ftype -FILE_NAME $sname -LANGUAGE en -TERRITORY $terr -LCT_FILE $XDO_TOP/patch/115/import/xdotmpl.lct -LDT_FILE "$AOBJ".ldt -DRVX_FILE "$AOBJ".drvx -LOG_FILE "$filename".log
mv "$fname".xml "$sname"
java oracle.apps.xdo.oa.util.XDOLoader UPLOAD -DB_USERNAME apps -DB_PASSWORD $tpwd -JDBC_CONNECTION "$thname:$thport:$tsid" -LOB_TYPE DATA_TEMPLATE -LOB_CODE "$AOBJ" -XDO_FILE_TYPE $ftype -FILE_NAME "$sname" -APPS_SHORT_NAME $AASN -LANGUAGE en -TERRITORY US -LCT_FILE $XDO_TOP/patch/115/import/xdotmpl.lct -LDT_FILE "$AOBJ".ldt -DRVX_FILE "$AOBJ".drvx -LOG_FILE "$filename".log -CUSTOM_MODE FORCE
done
# WADIINTG Web ADI Integrator
# WADILAYO Web ADI Layout
# WADIMAPC Web ADI Mapping Code
# WADISTYL Web ADI Style
elif (test $ATYP = "WADIINTG") then
# FNDLOAD $FRSID 0 Y DOWNLOAD $BNE_TOP/patch/115/import/bneint.lct "$AOBJ".ldt BNE_INTEGRATORS INTEGRATOR_ASN=$AASN INTEGRATOR_CODE="$AOBJ"
# FNDLOAD $TOSID 0 Y UPLOAD $BNE_TOP/patch/115/import/bneint.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
FNDLOAD $FRSID 0 Y DOWNLOAD $BNE_TOP/patch/115/import/bneintegrator.lct "$AOBJ".ldt BNE_INTEGRATORS INTEGRATOR_ASN=$AASN INTEGRATOR_CODE="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $BNE_TOP/patch/115/import/bneintegrator.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "WADILAYO") then
FNDLOAD $FRSID 0 Y DOWNLOAD $BNE_TOP/patch/115/import/bnelay.lct "$AOBJ".ldt BNE_LAYOUTS LAYOUT_ASN=$AASN LAYOUT_CODE="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $BNE_TOP/patch/115/import/bnelay.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "WADIMAPC") then
FNDLOAD $FRSID 0 Y DOWNLOAD $BNE_TOP/patch/115/import/bnemap.lct "$AOBJ".ldt BNE_MAPPINGS MAPPING_ASN=$AASN MAPPING_CODE="$AOBJ"
FNDLOAD $TOSID 0 Y UPLOAD $BNE_TOP/patch/115/import/bnemap.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "WADISTYL") then
FNDLOAD $FRSID 0 Y DOWNLOAD $BNE_TOP/patch/115/import/bness.lct "$AOBJ".ldt BNE_STYLESHEETS CONTENT_ASN=$AASN STYLESHEET_CODE="$AOBJ" STYLESHEET_ASN=$AASN
FNDLOAD $TOSID 0 Y UPLOAD $BNE_TOP/patch/115/import/bness.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "XLAD") then
sqlsmt=""
sqlsmt=$sqlsmt"select distinct 'APPLID:'||application_id"'\n'
sqlsmt=$sqlsmt" from applsys.fnd_application "'\n'
sqlsmt=$sqlsmt" where application_short_name = '"$AASN"'; "'\n'
sqlsmt=$sqlsmt"exit "'\n'
echo $sqlsmt > $rtime.sql
sqlplus -s $FRSID @$rtime.sql > $rtime.out
for i in `awk '/APPLID/ {print $0}' $rtime.out`
do
APPLID=`echo $i|awk '{FS=":"} {print $2}'`
done

FNDLOAD $FRSID 0 Y DOWNLOAD $MWD_TOP/admin/ldt/xlaaadrule.lct "$AOBJ".ldt XLA_AAD APPLICATION_ID=$APPLID AMB_CONTEXT_CODE=DEFAULT FEDERAL=N
FNDLOAD $TOSID 0 Y UPLOAD $MWD_TOP/admin/ldt/xlaaadrule.lct "$AOBJ".ldt XLA_AAD APPLICATION_ID=$APPLID AMB_CONTEXT_CODE=DEFAULT UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
elif (test $ATYP = "PJSTAT") then
FNDLOAD $FRSID 0 Y DOWNLOAD $PA_TOP/patch/115/import/paprjsta.lct "$AOBJ".ldt PA_PROJECT_STATUSES
FNDLOAD $TOSID 0 Y UPLOAD $PA_TOP/patch/115/import/paprjsta.lct "$AOBJ".ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
FNDLOAD $FRSID 0 Y DOWNLOAD $PA_TOP/patch/115/import/paprjsta.lct "$AOBJ"_CONTROLS.ldt PA_PROJECT_STATUS_CONTROLS
FNDLOAD $TOSID 0 Y UPLOAD $PA_TOP/patch/115/import/paprjsta.lct "$AOBJ"_CONTROLS.ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
FNDLOAD $FRSID 0 Y DOWNLOAD $PA_TOP/patch/115/import/pacinest.lct "$AOBJ"_ALLOW.ldt PA_NEXT_ALLOW_STATUSES
FNDLOAD $TOSID 0 Y UPLOAD $PA_TOP/patch/115/import/pacinest.lct "$AOBJ"_ALLOW.ldt UPLOAD_MODE=REPLACE CUSTOM_MODE=FORCE
fi
rm $rtime.sql
rm $rtime.out
#chmod 777 *.log
#chmod 777 *.rtf
#chmod 777 *.ldt
#chmod 777 *.xml
Advertisement

2016-12 Shinnyo Podcast Regarding Hope

2016-12 Shinnyo Podcast Regarding Hope

  • What is Hope?
  • Does Hope Go Away?
  • Creating Hope
  • When Is Hope Lost and Found?

Subscribe to this Podcast (RSS) or iTunes or via Flipboard

Image of Where There's Life, There's Hope
Where There’s Life, There’s Hope – Courtesy of: http://www.hdnicewallpapers.com/Walls/Big/Thoughts%20and%20Quotes/Beautful_Thought_on_Life_and_Hope_HD_Wallpapers.jpg

If we define hope as wanting, wishing or imagining something that isn’t in our present existence, we could say that hope is an imaginary concept – something that isn’t real.  If we think of hope as a state of consciousness, or the state in which we are visualizing this changed existence, then hope becomes a more tangible idea – something that persists.

The four virtues of enlightenment are expressed as permanence, bliss, self and purity, and in this context, the state of permanence is elusive depending on how we define our concept of hope.  Each of these states is related to embracing the dynamics of change as an ever-present condition. But to also realize that hope becomes ever-present as long as we can imagine a state of improvement beyond where we are today. You give up your imagination, and you can say you gave up hope.

Nature accepts things as they are – whatever happens, happens. People like to change things, like creating clocks to track time instead of watching the sun and moon. We try to move and push our environment around to better suit what we think is easier, more advantageous, or even more efficient.

When facing extreme changes, that’s when humans often resort to despair instead of hope, losing that sense of a better tomorrow. But really, tomorrow is by its own peculiar definition, something that hasn’t happened yet. We may have a less shiny and perfect vision of that which has yet to come, but basically, it still is beyond the present. And until it happens, it’s still not our reality (barring existence in a parallel universe and warpage of time, of course.)

Our reality is how we perceive it. A fish out of water is kind of stressed, and probably certainly not happy about that. But it has relatively little capacity to change its own condition.  We, by comparison, have amazing capability to change our presence, where we are, how we live, and in what manner we decide to co-exist with everything else.  Question is, do you realize that potential?

Hope becomes real as we define and change ourselves, whether that means being content with whatever we have already, or transitioning and developing ourselves to see beyond our self-imposed limitations. In the path of transformation, we materialize our vision or goals into reality.

Looking at the situation in a more pragmatic light might be that we can consider ourselves either “stuck in traffic” or “faced with the opportunity to choose alternate paths to our destination.”  Either way, the traffic is there. It is up to us to figure out how we perceive it and how we deal with it..

My own hope in this case is that you find that hope isn’t something someone else gives you. Hope is what you give to yourself.

I have seen what a laugh can do. It can transform almost unbearable tears into something bearable, even hopeful. –Bob Hope

Read more at: https://www.brainyquote.com/quotes/authors/b/bob_hope.html

/* That’s it for this session. Thank you for listening. For more information feel free to e-mail me at jlui at jlui dot net, or twitter @jhlui1 With Gassho, James*/

Save

R12.2.3 / R12.2.x Oracle e-Business Suite – Resetting the WebLogic Password

…because occasionally you either forget it (or in my case, a technology patch reset it to something I wasn’t sure about.)wls_denied_ss

There are 2 basic routes:


The “short” process – re-run the post-clone config (adcfgclone.pl):

# Have to remove the existing FMW home because it will re-unzip a new one from the clone staging archive
applptch@aburpaofinm01 $> cd /u01/fs2
applptch@aburpaofinm01 $> ls
EBSapps  FMW_Home  inst
applptch@aburpaofinm01 $> ls -latr
total 24
drwxrwxr-x  8 applptch oinstall 4096 May  8 21:49 ..
drwxr-xr-x  5 applptch oinstall 4096 May  9 12:33 EBSapps
drwxr-xr-x  3 applptch oinstall 4096 Jul 16 15:30 inst
drwxr-xr-x  6 applptch oinstall 4096 Jul 16 15:41 .
drwxr-x— 13 applptch oinstall 4096 Jul 16 16:16 FMW_Home
applptch@aburpaofinm01 $> rm -rf FMW_HOME_BAK
# Check that the Oracle Homes are not in the OraInventory
# Or you will receive the error:
# Below Oracle Homes are already registered in the global inventory:
#/u01/fs2/FMW_Home/Oracle_EBS-app1
#/u01/fs2/FMW_Home/webtier
#/u01/fs2/FMW_Home/oracle_common
#
# Exiting Cloning…
#
# Ensure that the above Oracle Homes are unregistered from the global inventory “/u01/oraInventory/ContentsXML/inventory.xml” and re-run adcfgclone.pl script
vi /u01/oraInventory/ContentsXML/inventory.xml
# and remove the <HOME> through </HOME> entries for the 3 listed entries
# Begin the clone – needs the APPS password
applptch@aburpaofinm01 $> cd $COMMON_TOP/clone/bin
applptch@aburpaofinm01 $> perl adcfgclone.pl appsTier


The “long” process – by manually manipulating the admin account in the /u01/<fs#>/FMW_Home:

# Verify your Weblogic Environment home
applptch@aburpaofinm01 $> set | grep EBS

EBS_DOMAIN_HOME=/u01/fs2/FMW_Home/user_projects/domains/EBS_domain_PTCHARMK

# Stop Weblogic
$ADMIN_SCRIPTS_HOME/adstpall.sh apps/$APPS_PW
Weblogic Password: [anything because you don’t know it]

# Set your environment
cd $EBS_DOMAIN_HOME/bin
. setDomainEnv.sh

# Remove the existing LDIFT’s, boot.properties and LDAP directory
rm -rf $EBS_DOMAIN_HOME/security/DefaultAuthenticatorInit.ldift ; \
rm -rf $EBS_DOMAIN_HOME/servers/AdminServer/security/boot.properties ; \
rm -rf $EBS_DOMAIN_HOME/servers/oacore_server?/security/boot.properties ; \
rm -rf $EBS_DOMAIN_HOME/servers/forms_server?/security/boot.properties ; \
rm -rf $EBS_DOMAIN_HOME/servers/oafm_server?/security/boot.properties ; \
rm -rf $EBS_DOMAIN_HOME/servers/forms-c4ws_server?/security/boot.properties ; \
rm -rf $EBS_DOMAIN_HOME/servers/oaea_server?/security/boot.properties ; \
rm -rf $EBS_DOMAIN_HOME/servers/AdminServer/data/nodemanager/boot.properties ; \
rm -rf $EBS_DOMAIN_HOME/servers/AdminServer/data/ldap

# Start AdminServer from command line manually
cd $EBS_DOMAIN_HOME ;\
startWebLogic.sh

# Enter new credentials as above
<Sep 16, 2014 4:58:09 PM PDT> <Info> <Security> <BEA-090065> <Getting boot identity from user.>
Enter username to boot WebLogic server:weblogic
Enter password to boot WebLogic server:

Change NodeManager password

Log in to the WebLogic Administration console.
Click the Lock & Edit button.
In the left panel, click on the EBS Domain link.
Select the Security tab.
Click on the ‘Advanced’ link.
Edit the ‘Node Manager password’ field and set it to the new WebLogic Server password. The password should be same as set in Step 3.
Edit the ‘Confirm NodeManager Password’ field and set it to the new WebLogic Server password. The password should be same as set in Step 3.
Save and activate the changes.

Shut down AdminServer from the console. For the first time, AdminServer has to be stopped from the Admin console. Follow these steps:

Log in to the WebLogic Administration console.
Shut down AdminServer.

Shut down NodeManager using the normal AD script.

$ADMIN_SCRIPTS_HOME/adnodemgrctl.sh stop

Copy the boot.properties file for all managed servers.

cp $EBS_DOMAIN_HOME/servers/AdminServer/data/nodemanager/boot.properties \
$EBS_DOMAIN_HOME/servers/oacore_server?/security/boot.properties  \
$EBS_DOMAIN_HOME/servers/forms_server?/security/boot.properties  \
$EBS_DOMAIN_HOME/servers/oafm_server?/security/boot.properties  \
$EBS_DOMAIN_HOME/servers/forms-c4ws_server?/security/boot.properties  \
$EBS_DOMAIN_HOME/servers/oaea_server?/security/boot.properties

The EBS WebLogic Server domain password has now been changed, and all servers can now be started using the normal AD scripts.

To start AdminServer:

$ADMIN_SCRIPTS_HOME/adadminsrvctl.sh start

# Start it all back up again
$ADMIN_SCRIPTS_HOME/adstrtal.sh apps/$APPS_PW
Weblogic Password: [weblogic pwd]

Now your password change is complete (or at least you can get back into your Admin Console).

# Clone the working result from the run filesystem to the patch filesystem
$ adop phase=fs_clone

** Based upon a regular WebLogic post by:

http://shivabizint.wordpress.com/2012/10/15/how-to-reset-the-lost-weblogic-admin-user-password/

**And an R12.2 version by:

http://nagendrachillale.wordpress.com/2014/08/22/if-the-admin-password-of-an-ebs-weblogic-domain-is-lost-or-forgotten/

How to migrate EM12c R3 OMS and repository to a new host

Very useful, even if you’re moving parts of OEM 12c from one host to another, or modifying the filesystem mounts.

Pardy DBA

(EDIT 20130917: If you simply need to change the IP address of your OEM server, please review MOS note 1562029.1.  The procedure in that note may allow you to change your OEM server’s IP address without following the lengthy process I describe below.)

In order to save power in our data center, I need to migrate my EM12c R3 environment from the host where it currently runs to a new host.  I have a simple configuration, with a single OMS, no load balancer, and the repository database runs on the same host as EM12c R3 itself.  I also have BI Publisher installed and integrated with EM12c, and a few third party plugins as I’ve detailed elsewhere on this blog.  If you use an OS other than Linux x86-64 I suggest you research thoroughly as this procedure may or may not apply to your environment.  Further, if you have a multi-OMS…

View original post 3,770 more words

Existing OEM 12c Agent Fails Startup and Resecure on Hostname Change

Had an issue where the hostname (on Oracle Enterprise Linux 5.9 – OEL 64-bit) happened to have an incorrect hostname and alias when I had already installed the OEM 12c (12.1.0.3) Agent. Thus the OMS repository targets were all named incorrectly, even though the Agent was secured and registered. (This was a new database host).

In the $AGENT_HOME/sysman/log/emagent.nohup log was the following:

— EMState agent
—– Sat Mar 1 10:42:22 2014::10437::Auto tuning the agent at time Sat Mar 1
10:42:22 2014 —–
—– Sat Mar 1 10:42:23 2014::10437::Finished auto tuning the agent at time Sat Mar 1 10:42:23 2014 —–
—– Sat Mar 1 10:42:23 2014::10437::Launching the JVM with following options: -Xmx128M -server -Djava.security.egd=file:///dev/./urandom -Dsun.lang.ClassLoader.allowArraySyntax=true -XX:+UseLinuxPosixThreadCPUClocks -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled -XX:+UseCompressedOops —–
—– Sat Mar 1 10:42:23 2014::10491::Time elapsed between Launch of Watchdog process and execing EMAgent is 2 secs —–
—– Sat Mar 1 10:42:23 2014::10437::Agent Launched with PID 10491 at time Sat Mar 1 10:42:23 2014 —–
2014-03-01 10:42:23,962 [1:main] WARN – Missing filename for log handler ‘wsm’
2014-03-01 10:42:23,971 [1:main] WARN – Missing filename for log handler ‘opss’
2014-03-01 10:42:23,972 [1:main] WARN – Missing filename for log handler ‘opsscfg’
OMS decided to shutdown the agent because of the following reason sent from OMS: EM_PLUGIN_MISMATCH_AND_AGENT_NOT_YET_MANAGED
—– Sat Mar 1 10:42:37 2014::10437::Checking status of EMAgent : 10491 —–
—– Sat Mar 1 10:42:37 2014::10437::EMAgent exited at Sat Mar 1 10:42:37 2014 with return value 0. —–
—– Sat Mar 1 10:42:37 2014::10437::EMAgent was shutdown normally. —–

./emctl secure agent

./emctl start agent

Resulted in the same repeating failures.

Removed the Target Host and Agent from OEM 12c OMS

(Target -> Hosts -> (select host) -> [Remove], and then,

Setup -> Manage Cloud Control -> Agents -> (click on Agent:(port)

Agent Menu (upper-left dropdown) -> Target Setup -> Remove Target)

Re-deployed using the faster method of silent Agent deployment (Bobby Curtis has this covered on http://dbasolved.com/2013/04/10/install-oem-agents-silently-in-any-environment )

Everything ready to proceed again.

Changing ORACLE_BASE in Oracle 11gR2 (11.2.0.3.4) Database

During a routine installation, I managed to mis-type the filesystem path for the ORACLE_BASE during execution of the Oracle Universal Installer (./runInstaller).

[nb: ORACLE_BASE by normal definition should be a standard starting filesystem mountpoint under which all other instance-specific data/files for this ORACLE_HOME would be found. Typically contains your diagnostic logs, Fast Recovery Area files, all configuration tool logs, and any Flashback checkpoint saves.

$ORACLE_BASE/diag/.

./asm
./clients
./crs
./diagtool
./lsnrctl
./netcman
./ofm
./rdbms
./tnslsnr

$ORACLE_BASE/admin/<SID>/.

./adump          # Audit data./dpdump       # Data Pump related
./pfile               # init.ora files generated by config tools

–end of note]

Since the service account (oracle) had filesystem permissions to do so, it went ahead and put all of the flashback recovery, diagnostics, and audit trail files (and my backup controlfiles) into the incorrectly named directory.  The database itself was running, but how to correct this without starting all over again?

Start with backing up your init.ora configuration from spfile to pfile format:

SQL> create pfile from spfile;

File created.

(this defaults to $ORACLE_HOME/dbs/init.ora)

Then shutdown services:

SQL> shutdown immediate;

Database closed.

SQL> exit;

#oracle> lsnrctl stop

Now go find all the places you’ll need to modify/correct the ORACLE_BASE filepath declarations:

$ORACLE_HOME/dbs/init<SID>.ora

$ORACLE_HOME/network/admin (or $TNS_ADMIN)

  • listener.ora: ADR_BASE_LISTENER
  • sqlnet.ora: ADR_BASE
    (Note: these two are auto-generated using netca – the Oracle Net Configuration Assistant, if you execute that after making the database and environment-side changes.

$ORACLE_HOME/inventory/ContentsXML/oraclehomeproperties.xml : ORACLE_BASE

All finished editing? Start everything back up:

#oracle> lsnrctl start

SQL> startup pfile=?/dbs/init<SID>.ora  — to use revised settings

SQL> create spfile from pfile;       — copy new settings to spfile

SQL> shutdown immediate;

SQL> startup;                                — uses spfile instead

Now future installs using dbca, dbua and netca should recognize your defined/modified/corrected ORACLE_BASE.