Application File system for dba1 (New Test instance) [message #241874] |
Wed, 30 May 2007 15:17 |
Anne Simms
Messages: 163 Registered: May 2002 Location: San Francisco, CA
|
Senior Member |
|
|
Hi have a question and I hope this is in the right forum. After discussing this with the DBAs it was determined the best practice for moving Oracle reports to the final destination on DBA1 (the new test instance) would be:
To create an OS user which will copy the source report on /tmp a directory in Unix.
The DEV team should create and concurrent program in APPS_DBA1 which will move the report file from /tmp to the final destination and reset the permission.
The concurrent program might have 2 parameters: filename, destination path, and should be created under $TAM_TOP/bin
which is the .rdf file directories for Oracle reports.
Shell code:
# ----------------------------
# main module get parameters
# ----------------------------
set - `echo $1`
shift 8
TEMPDIR=`echo $1 | tr -d '["]'` -- destination path
TEMPFILE=`echo $2 | tr -d '["]'` -- filename
# -------------------------------------------
# if no TEMPDIR or TEMPFILE
# return error code 2 to the application
# -------------------------------------------
[ ! "$TEMPDIR" -o ! "$TEMPFILE"] && exit 2
# -------------------------------------------
# get inbound directory
# -------------------------------------------
# echo $TEMPDIR
# echo $TEMPFILE
# -------------------------------------------
# copy source file to final destination and rename the previous version
# -------------------------------------------
cd $TEMPDIR
mv $TEMPFILE $TEMPFILE.old
mv /tmp/$TEMPFILE $TEMPDIR/$TEMPFILE
chmod 777 $TEMPDIR/$TEMPFILE
#end
Can anyone tell me what problems you see with this approach?
Anne
|
|
|
|
|