I have been searching for backup solution/tool for backup/recovery of Oracle Databases which is scalable enough that you can easily install and customize for your site. After spending some time on google/bing I felt it might be a good idea to work on one, which will give me an opportunity to refresh my skills in shell/perl scripting too. Finally after a good couple of months I was able to come up with a scalable product, which I have now uploaded to sourceforge.net as an open source Product. You can download the entire scripts from here https://sourceforge.net/projects/oraclerman/
Zip file consists of 3 main scripts.
Zip file consists of 3 main scripts.
a ) scRBackup.sh : Single DB RMAN Backup Script(bash)
b ) scRRecover.sh: Single DB RMAN Recover Script(bash)
c ) scMBackup.pl : Multi DB Backup Wrapper Script(perl)
c ) scMBackup.pl : Multi DB Backup Wrapper Script(perl)
Script Usage Syntax
Before you read further, here's the backup script in action, small demo of how it works - desktop recording showing backup and restore of the databases.
** If the video is not clear, a high resolution .avi file is included along with the scripts at https://sourceforge.net/projects/oraclerman/
Once you unzip the scripts are placed in folder called rbSCRIPTS and there are 3 main sub directories under this - rbLOGS, rbREPORTS, rbCONFIG, rbSQL. rbCONFIG/rbckup.ini: rbCONFIG consists of a .ini file called rbckup.ini, which contains all the initialization parameters required for the script to run. This eliminates the need to do edits or otherwise hard coding changes when you install this at your site. Instead you can do simple edits to the rbckup.ini file and customize it to work for your environment. Also makes it easy when you port the scripts from one host to another. The rbckup.ini, has been compartmentalized with comments like "Declared(DYN) meaning all Dynamic Variables", Declared (HC) meaning all Hard Coded Variables etc for readability.
First set of arguments within rbckup.ini file is for command line arguments. For e.g. To backup a database RBPDB00, below is the command that will be used. As you can see all the RMAN parameters are being supplied through command line following the script name. This includes DISK vs. TAPE.
sh scRBackup.sh disk 0c RBPDB00 4 3 30 100G 4 1 2
If you notice within the rbckup.ini file, there's a line for "SBT_TAPE". This makes it easier to switch between a DISK backup a TAPE backup. Once you define the right nodes for TSM Backup (Assuming it's a TIVOLI TSM Tape Library and a tdpo.opt defined) all that's required to switch between disk and tape is that you need to specify that in the command line. Please note the quotes around (single and double), has to be precise, else the script will error out.
export SBT_TAPE="'sbt_tape' parms
'ENV=(TDPO_OPTFILE=/opt/tivoli/tsm/client/oracle/bin/tdpo.opt)'"
So if the above backup needs to be taken to the tape library, all you need to do is to change it to say "tape" instead of "disk"
sh scRBackup.sh tape 0c RBPDB00 4 3 30 100G 4 1 2
Above shows how to backup a single database "RBPDB00". So if you need to backup more than 1 database here's how it has to be done.
sh scRBackup.sh tape 0c RBPDB00 4 3 30 100G 4 1 2
sh scRBackup.sh tape 0c RBPDB01 2 5 60 200G 9 2 5
As you can see above, the parameters (RMAN) followed by the databases can be different for different databases as you see fit. Details about these parameters has been described in the presentation (.ppt) included along with the code. For e.g, "0C" is for Incremental-Level-0-ColdBackup", "0 is for Incremental-Level-0-Open-Inconsistent Backup". Following the SID names are parameters like Channels, Recovery Window, Control File Record Keep Time, Max Set Size, Parallelism etc. I have included a Power Point Presentation (.ppt) which details each and every parameters along with the source code. You can download all these along with a demo from below link.
sh scRBackup.sh tape 0c RBPDB02 2 5 70 300G 8 4 3
As you can see above, the parameters (RMAN) followed by the databases can be different for different databases as you see fit. Details about these parameters has been described in the presentation (.ppt) included along with the code. For e.g, "0C" is for Incremental-Level-0-ColdBackup", "0 is for Incremental-Level-0-Open-Inconsistent Backup". Following the SID names are parameters like Channels, Recovery Window, Control File Record Keep Time, Max Set Size, Parallelism etc. I have included a Power Point Presentation (.ppt) which details each and every parameters along with the source code. You can download all these along with a demo from below link.
Since scRBackup.sh was being built to do individual Database Backups, I created a small file putting all the commands separated by ":" A perl wrapper called scMBackup.pl (Master Backup) is then used to read this file, which will just loop through and build the individual "scRBackup.sh x x x.." commands ript one by one looping through the supplied file.
rbCONFIG/db_dbf.lst
0:Y:scRBackup.sh:disk:0:RBPDB00:4:7:10:20G:2:1:1:EOL
1:Y:scRBackup.sh:disk:0:RBPDB01:6:9:15:50G:3:2:2:EOL
2:Y:scRBackup.sh:disk:0:RBPDB02:3:4:20:40G:4:1:2:EOL
3:Y:scRBackup.sh:disk:0:RBPDB03:4:2:50:90G:5:2:1:EOL
The syntax to use the scMBackup.pl is as below.
perl scMBackup.pl ./rbCONFIG/db_dbf.lst 0 3 R
The above command will scan the db_dbf.lst file and will build and run the individual scRBackup commands thus backing up each databases. The last letter "R", if substituted with "P" will give you a preview mode, instead really running the databases.
First character in each row is numbers in sequence, this is done so that instead editing the .ini file you can specify the start and end positions through the command line. For e.g, if you want to backup databases from 1 to 3, you will need to specify like below. This way the first one "0", will be skipped.
perl scMBackup.pl ./rbCONFIG/db_dbf.lst 1 3 R
Second character is provided for excluding any backups from the list. For e.g if there's list of 50 databases and you want to start from 0 to 50 but like to skip/disable the 30th one. Your .ini file would like below, substitute "Y", with "N". scMBackup.pl will thus skip this database.
rbCONFIG/db_dbf.lst
0:Y:scRBackup.sh:disk:0:RBPDB00:4:7:10:20G:2:1:1:EOL
1:Y:scRBackup.sh:disk:0:RBPDB01:6:9:15:50G:3:2:2:EOL
..................
30:N:scRBackup.sh:disk:0:RBPDBxx:6:9:15:50G:3:2:2:EOL
...................
50:Y:scRBackup.sh:disk:0:RBPDB02:3:4:20:40G:4:1:2:EOL
All these can be tested by running it with preview mode - "P" , which will show what will run.
perl scMBackup.pl ./rbCONFIG/db_dbf.lst 0 50 P
For more details you may now go through the .ppt files included along with the demo (.avi) and scripts. For convenience and benefit I'm including same slides below.
Hope this helps.
Regards,
Raj
Hope this helps.
Regards,
Raj
*********************************************************************
The file is part of Open Source Oracle Backup Solution which uses RMAN+Perl+Bash script to backup Oracle Databases (11g & 10g) ready to run on any Linux Platforms by doing simple edits to an .ini file which may be required to be customized for your site.
Copyright (C) 2010 Baburaj Kallarakkal
Open Source Oracle Backup Solution is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
Open Source Oracle Backup Solution is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with Open Source Oracle Backup Solution.
If not, see http://www.gnu.org/licenses.
**********************************************************************
**********************************************************************
This comment has been removed by a blog administrator.
ReplyDeletethis is an execellent article ,very detail
ReplyDeletethanks
Simply a great tool, very well engineered and coded. I'm currently trying to make some changes need by our environment and surely adopt it as our main Oracle backup solution.
ReplyDeleteWill this script work on IBM AIX 5.3 and above ? I notice you mentioned this is only for Linux.
ReplyDeleteHow can I make it work on AIX ?
Oracle RMAN Backup Solution is very helpful and interactive. thanks for nice post.
ReplyDeletefree downloadable software
thanks for giving great information of oracle rman backup solution.
ReplyDeletedownload free full version software
Thanks for informing about Oracle RMAN Backup Solution. it's really useful and interactive.
ReplyDeletenew latest download
it is very useful post! thanks for giving nice information.
ReplyDeletefree crack software | cracked software download
that's really awesome...thanks for giving informative post.
ReplyDeleteandroid data recovery full crack
thanks a bundle....
ReplyDeleteMicrosoft Office 2016 Crack Download | Edraw Max Free Download Full Version
I am feeling great to read this.you gave a nice info for us.
ReplyDeleteplease update more.
Best Salesforce Admin training in Coimbatore | Salesforce Admin training in Coimbatore | Best Salesforce Admin training institute in Coimbatore | Salesforce Admin Course in Coimbatore
https://bayanlarsitesi.com/
ReplyDeleteOrdu
Kocaeli
Düzce
Osmaniye
MS667J
Bursa
ReplyDeleteKırşehir
Muş
Mersin
Çanakkale
0Y1
Eskişehir
ReplyDeleteDenizli
Malatya
Diyarbakır
Kocaeli
OXCOO
Diyarbakır
ReplyDeleteKırklareli
Kastamonu
Siirt
Diyarbakır
GSAX
ankara parça eşya taşıma
ReplyDeletetakipçi satın al
antalya rent a car
antalya rent a car
ankara parça eşya taşıma
EKR
Çorum Lojistik
ReplyDeleteKaraman Lojistik
Gümüşhane Lojistik
Denizli Lojistik
Artvin Lojistik
B8CUAC
amasya evden eve nakliyat
ReplyDeleteeskişehir evden eve nakliyat
ardahan evden eve nakliyat
manisa evden eve nakliyat
karaman evden eve nakliyat
QNK
denizli evden eve nakliyat
ReplyDeletekars evden eve nakliyat
çorum evden eve nakliyat
kars evden eve nakliyat
malatya evden eve nakliyat
LİD3F
86C3A
ReplyDeleteSakarya Evden Eve Nakliyat
Iğdır Lojistik
Batman Lojistik
Uşak Lojistik
Bayburt Lojistik
1AA65
ReplyDeleteAdıyaman Lojistik
Batman Lojistik
Çanakkale Lojistik
Mardin Evden Eve Nakliyat
Sivas Evden Eve Nakliyat
04EE5
ReplyDeleteIsparta Parça Eşya Taşıma
Aksaray Parça Eşya Taşıma
Isparta Lojistik
Tekirdağ Lojistik
Aydın Lojistik
BB717
ReplyDeleteZonguldak Şehir İçi Nakliyat
Nevşehir Evden Eve Nakliyat
Bitfinex Güvenilir mi
Kayseri Şehir İçi Nakliyat
Çerkezköy Parke Ustası
Van Parça Eşya Taşıma
Artvin Lojistik
Keçiören Parke Ustası
Konya Şehirler Arası Nakliyat
9F450
ReplyDeleteBingöl Parça Eşya Taşıma
Silivri Evden Eve Nakliyat
Bitlis Şehirler Arası Nakliyat
Batıkent Boya Ustası
Silivri Boya Ustası
Artvin Şehirler Arası Nakliyat
Çerkezköy Çilingir
Coin Nedir
Düzce Evden Eve Nakliyat
AB15C
ReplyDeleteArtvin Parça Eşya Taşıma
Tekirdağ Çatı Ustası
Çorlu Lojistik
Konya Evden Eve Nakliyat
Hakkari Parça Eşya Taşıma
Bitfinex Güvenilir mi
Referans Kimliği Nedir
Maraş Evden Eve Nakliyat
Çerkezköy Marangoz
314DC
ReplyDeleteAltındağ Parke Ustası
Mamak Parke Ustası
Çankaya Fayans Ustası
Sivas Parça Eşya Taşıma
Etlik Boya Ustası
Vindax Güvenilir mi
Kilis Evden Eve Nakliyat
Tunceli Lojistik
İstanbul Şehir İçi Nakliyat
CCADF
ReplyDeleteMaraş Şehirler Arası Nakliyat
Bitlis Şehir İçi Nakliyat
Tekirdağ Cam Balkon
Ordu Lojistik
Çankırı Şehir İçi Nakliyat
Çankırı Lojistik
Çerkezköy Parke Ustası
Big Wolf Coin Hangi Borsada
Tesla Coin Hangi Borsada
9DAAC
ReplyDeleteTrabzon Parça Eşya Taşıma
Ordu Parça Eşya Taşıma
Uşak Lojistik
Zonguldak Şehir İçi Nakliyat
Çankırı Şehirler Arası Nakliyat
Kastamonu Lojistik
Pursaklar Parke Ustası
Denizli Parça Eşya Taşıma
Antalya Şehirler Arası Nakliyat
6CA00
ReplyDeletekonya kızlarla rastgele sohbet
gümüşhane parasız sohbet siteleri
mardin bedava sohbet
batman sesli sohbet
balıkesir muhabbet sohbet
maraş bedava görüntülü sohbet sitesi
rastgele görüntülü sohbet uygulamaları
antep mobil sohbet odaları
çorum görüntülü sohbet kadınlarla
E12F9
ReplyDeleteartvin canli sohbet chat
istanbul görüntülü sohbet kızlarla
karabük en iyi ücretsiz görüntülü sohbet siteleri
ığdır en iyi görüntülü sohbet uygulaması
diyarbakır telefonda kadınlarla sohbet
görüntülü sohbet siteleri
canlı görüntülü sohbet siteleri
muğla seslı sohbet sıtelerı
hakkari sesli sohbet siteleri
E9B8A
ReplyDeleteisparta canlı sohbet siteleri
kırıkkale mobil sohbet odaları
elazığ yabancı sohbet
antep ucretsiz sohbet
yozgat parasız sohbet
maraş sesli mobil sohbet
karabük sesli mobil sohbet
adana rastgele görüntülü sohbet uygulamaları
artvin bedava sohbet uygulamaları
877B4
ReplyDeletecanlı görüntülü sohbet
Konya Rastgele Sohbet
kayseri sesli sohbet mobil
niğde seslı sohbet sıtelerı
isparta bedava sohbet chat odaları
bayburt yabancı görüntülü sohbet uygulamaları
izmir canli sohbet
diyarbakır görüntülü sohbet uygulamaları ücretsiz
ücretsiz sohbet odaları
146AD
ReplyDeleteantep canlı görüntülü sohbet siteleri
Düzce Bedava Sohbet Chat Odaları
chat sohbet
Balıkesir Mobil Sesli Sohbet
Tekirdağ Görüntülü Sohbet Kadınlarla
çankırı kadınlarla sohbet et
mobil sohbet et
gümüşhane parasız görüntülü sohbet
burdur rastgele sohbet siteleri
5FC41
ReplyDeleteParasız Görüntülü Sohbet
Threads Beğeni Hilesi
Sohbet
Okex Borsası Güvenilir mi
Binance Referans Kodu
Kaspa Coin Hangi Borsada
Keep Coin Hangi Borsada
Nonolive Takipçi Hilesi
Arg Coin Hangi Borsada
09652
ReplyDeleteBtcturk Borsası Güvenilir mi
Snapchat Takipçi Hilesi
Kripto Para Madenciliği Siteleri
Telegram Abone Hilesi
Coin Nasıl Kazılır
Keep Coin Hangi Borsada
Tiktok Beğeni Satın Al
Kripto Para Madenciliği Nedir
Referans Kimliği Nedir
7264D
ReplyDeleteraydium
ledger desktop
layerzero
dexscreener
shiba
arculus
pancakeswap
poocoin
shiba