- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: need to capture time of my oracle export timin...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2012 12:54 AM
05-22-2012 12:54 AM
Hi ,
I have a script which takes oracle 9i export backup in a log , but it does not record start timing of export.
i would like to cover the same in log file.
this is what i see in log gile ;
Connected to: Oracle9i Enterprise Edition Release 9.2.0.7.0 - 64bit Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.7.0 - Production
Export done in US7ASCII character set and AL16UTF16 NCHAR character set
what i want is the actual timing ie.
smthg like which comes in forescreen when exp commnd is run.
Export: Release 9.2.0.7.0 - Production on Tue May 22 04:29:29 2012
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
Solved! Go to Solution.
- Tags:
- Oracle
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2012 06:40 AM
05-22-2012 06:40 AM
Re: need to capture time of my oracle export timing
There's no way to capture the run times in file created by EXP's "LOG=" parameter. Your best bet is to redirect EXP's STDOUT to a second log file and then append a date command to that STDOUT file. For example:
!/bin/sh
export ORACLE_SID=ORCL
export ORACLE_HOME=/ora/product/9.2.0
export PATH=$ORACLE_HOME/bin:$PATH
export DMPFILE=/ora/backup/${ORACLE_SID}
exp USERID=user/pass FILE=${DMPFILE}.dmp LOG=${DMPFILE}.log FULL=Y ... > ${DMPFILE}.stdout
echo "exp finished with return code $? at `date`" >> ${DMPFILE}.stdout
- Tags:
- date
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2012 11:00 PM
05-22-2012 11:00 PM
Re: need to capture time of my oracle export timing
Hi Robert,
Can we do a exp starting time also like you had suggested finished time ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-23-2012 12:40 PM
05-23-2012 12:40 PM
Re: need to capture time of my oracle export timing
Yes, you can but it is unnecessary since the EXP's stdout header includes the current date/time.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-24-2012 05:54 AM
05-24-2012 05:54 AM
Re: need to capture time of my oracle export timing
Hi Robert ,
But my EXP stdout doesnt capture it.
root #/db_dumps/acrb >cat fnsonlac_test_eod_backup_22052012.dmp.stdout
exp finished with return code 0 at Wed May 23 11:46:48 IST 2012
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-24-2012 06:51 AM
05-24-2012 06:51 AM
Re: need to capture time of my oracle export timing
Hi Robert ,
This is what i have in my script ;
exp EXPORT_USER/EXPORT_USER file=$fname direct=y statistics=none log=$logfile owner=$own > ${fname}.stdout
echo "exp finished with return code $? at `date`" >> ${fname}.stdout
It doesnt capture start time displayed by exp command in ${fname}.stdout file.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-24-2012 11:16 AM
05-24-2012 11:16 AM
Solution>It doesn't capture start time displayed by exp command in ${fname}.stdout file.
Change to:
echo "exp started at $(date)" > ${fname}.stdout
exp EXPORT_USER/EXPORT_USER file=$fname direct=y statistics=none log=$logfile owner=$own >> ${fname}.stdout
echo "exp finished with return code $? at $(date)" >> ${fname}.stdout
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-25-2012 12:57 AM
05-25-2012 12:57 AM
Re: need to capture time of my oracle export timing
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-25-2012 06:44 AM
05-25-2012 06:44 AM
Re: need to capture time of my oracle export timing
Sorry, there was a minor omission in my script sample. Here's the corrected one:
!/bin/sh
export ORACLE_SID=ORCL
export ORACLE_HOME=/ora/product/9.2.0
export PATH=$ORACLE_HOME/bin:$PATH
export DMPFILE=/ora/backup/${ORACLE_SID}
exp USERID=user/pass FILE=${DMPFILE}.dmp LOG=${DMPFILE}.log FULL=Y ... > ${DMPFILE}.stdout 2>&1
echo "exp finished with return code $? at `date`" >> ${DMPFILE}.stdout
The detailed exp output is sent to STDERR and not STDOUT.