>Yes please do send me the script and other procedures that you are using.
Hello I've modified the script so that it could be used not only in my, but also in other environments. It can be downloaded from: http://skowron31.neostrada.pl/rman_scripts/change_rman_backup_status.sh (in case of any download problems, let me know and I'll send it directly to your email) ***Important facts to consider:*** - Backup your recovery catalog before using this script - The script works quite good in my environment, but I can NOT guarantee that it will also work perfectly everywhere. - My environment: * ORACLE 8.1.7.4 target databases * ORACLE 8.1.7.4 recovery catalog database - separate catalog for each target database * AIX 5.1 ML04 * TSM 5.1.9 - Be extremely concentrated and focused when using this script, remember that you are dealing with your company VITAL data! - Should you have even a slightest doubt about using this script PLEASE ask me first, I'll try to answer to your questions. ***How does this script work ?*** 1. Connects to the target database and recovery catalog (according to the supplied parameters) 2. Asks recovery catalog for the list of stored backups (according to the supplied time range) 3. Parses the output from step 2, and generates rman command files (two files: one for setting unavailable flag, second for setting back to available state) 4. Generates shell executable scripts which have to be executed manualy to perform the actual operation of setting unavailable or available flags. Before actualy executing, check both *.cmd and *.sh files whether they are correct !!! If You execute it without parameters a short usage description will be displayed, similar to the output below: change_rman_backup_status.sh v 1.0 - beta 2004 Pawel Wozniczka ([EMAIL PROTECTED]) "This script generates RMAN command files which may be used to set 'unavailable' or 'available' flag to selected backup pieces Only briefly tested with Oracle 8.1.7.4 on AIX 5.1.4 (both target database and recovery catalog) Please use extreme caution with this script !!! Backup recovery catalog before using commands generated by this script!!! Wrong parameter count ! USAGE: change_rman_backup_status.sh DBUSER DBPASS DBTNS RCATUSER RCATPASS RCATTNS START_DATE END_DATE Execute as oracle, not as root or other user Required parameters: DBUSER - target database username (sysdba privileges) DBPASS - target database user password DBTNS - target database TNSNAME (alias) RCATUSER - recovery catalog username RCATPASS - recovery catalog password RCATTNS - recovery catalog TNSNAME (alias) START_DATE - start date (RMAN format, for example '10-OCT-04') END_DATE - start date (RMAN format, for example '15-OCT-04' or 'sysdate-1'...) WARNING: exact date format may be different because of various environmental settings ! Example: change_rman_backup_status.sh sys secret PRDDB rman secret RCATDB '01-OCT-04' '05-OCT-04' Will create commands to set either unavailable or available flags to backup pieces of the database PRDDB registered in recovery catalog database RCATDB between 01 October 2004 and 04 October 2004" As I said earlier I'm quite happy with the script. But remember that it doesn't take into consideration all possible configurations and may not always work as expected, so use it at your own risk. Feel free to ask in case of any doubts. kind regards Pawel Wozniczka