RMAN still running
Once a day, we issue the following query through cron to see if
RMAN is still running.
select operation,OBJECT_TYPE,ROW_TYPE from $RMAN_STATUS where status='RUNNING' and OPERATION='BACKUP' and OBJECT_TYPE !='ARCHIVELOG';
On some systems, when a full backup is in progress this query sees that a previous instance of RMAN is still running and reports it as
an error when in fact its not because the DB is so big and take a long time to backup.
Is there some table I can query where if I provide a tag for my full backup (ie tag=full_backup) or some other information I can look
to see if that tag is still being backed up. This would be very equivelant to providing a job name to expdp and seeing if that job_name is active
I was considering doing a select count... but that would not work as
we often clone DB's and I beleive this will bring out the same error.
Thanks to all who answer
Last edited by BeefStu; 12-27-2010 at 02:57 PM.
How do you start this job? DBMS_Scheduler? cron? What platform? I typically use cron and have a script that executes and outputs the results to a log file.
tail -f rman_out.log
ps -ef |grep rman
You can also see RMAN running from the web-based Oracle Enterprise Manager, but doesn't give you a clue as to where it is in the process.
OneDB, thanks for your reply.
As mentioned the job is started through cron on a nightly basis.
I'm not sure how your solution will solve my problem. ps -ef | grep rman will
still find the original RMAN that is running, which is my problem.
Therefore, I am looking for a way to query a table to look for tag that
is being backed up or a way to associate a job name to my rman command. This way I can distinguish the difference.
You can use rman SET COMMAND ID to name your channels - this piece of data will show up on v$session, client_info column.
Originally Posted by BeefStu
Pablo (Paul) Berzukov
Author of Understanding Database Administration
available at amazon and other bookstores.
Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.
Paul, perfect!!! Exactly what I was looking for
Click Here to Expand Forum to Full Width