$for i in $(cat dwpr_test_01.list); do
>nohup ./import_dwpr_test.sh $i 2>&1 > $i.nohup &
>done
>nohup ./import_dwpr_test.sh $i 2>&1 > $i.nohup &
>done
$cat import_dwpr_test.sh
WORKINGDIR=/dwhtest01a/export.20110804
NLS_LANG=AMERICAN_AMERICA.WE8ISO8859P1
ORACLE_BASE=/u1/app/oracle
ORACLE_SID=dwprt
ORACLE_TERM=vt100
ORA_NLS33=/u1/app/oracle/product/9.2.0/ocommon/nls/admin/data
ORACLE_HOME=/u1/app/oracle/product/9.2.0
ADMIN=system
PASSWORD=password
USERNAME=$1
rm ${WORKINGDIR}/${USERNAME}.pipe
mknod ${WORKINGDIR}/${USERNAME}.pipe p
gunzip < ${WORKINGDIR}/${USERNAME}.dmp.gz > ${WORKINGDIR}/${USERNAME}.pipe &
imp $ADMIN/$PASSWORD FROMUSER=${USERNAME} TOUSER=NEW_${USERNAME} FILE=${WORKINGDIR}/${USERNAME}.pipe LOG=${WORKINGDIR}/${USERNAME}_dwprt_import.log
rm ${WORKINGDIR}/${USERNAME}.pipe
NLS_LANG=AMERICAN_AMERICA.WE8ISO8859P1
ORACLE_BASE=/u1/app/oracle
ORACLE_SID=dwprt
ORACLE_TERM=vt100
ORA_NLS33=/u1/app/oracle/product/9.2.0/ocommon/nls/admin/data
ORACLE_HOME=/u1/app/oracle/product/9.2.0
ADMIN=system
PASSWORD=password
USERNAME=$1
rm ${WORKINGDIR}/${USERNAME}.pipe
mknod ${WORKINGDIR}/${USERNAME}.pipe p
gunzip < ${WORKINGDIR}/${USERNAME}.dmp.gz > ${WORKINGDIR}/${USERNAME}.pipe &
imp $ADMIN/$PASSWORD FROMUSER=${USERNAME} TOUSER=NEW_${USERNAME} FILE=${WORKINGDIR}/${USERNAME}.pipe LOG=${WORKINGDIR}/${USERNAME}_dwprt_import.log
rm ${WORKINGDIR}/${USERNAME}.pipe
Nessun commento:
Posta un commento