🧩 How to Install Oracle Database on Linux and Restore from RMAN Backup (Step-by-Step Guide)
🧩 How to Install Oracle Database on Linux and Restore from RMAN Backup (Step-by-Step Guide)
🚀 In this post, we’ll go through a complete DBA task — installing Oracle Database on Linux and restoring it from a previously taken RMAN backup. This process is essential when setting up a new environment or recovering a production database onto a test or standby server.
💡 Let’s dive in step by step 👇
🧱 Step 1: Pre-Installation Requirements
Before starting, make sure your Linux system meets Oracle’s requirements.
✅ System Configuration
OS: Oracle Linux / RHEL / CentOS 7+ (x86_64)
Memory: Minimum 4 GB (8 GB recommended)
Swap Space: Equal to RAM up to 16 GB
Disk Space: ~30 GB for Oracle Home + Database Files
✅ Create Required Users & Groups
groupadd oinstall
groupadd dba
useradd -g oinstall -G dba oracle
passwd oracle
✅ Set Kernel Parameters (edit /etc/sysctl.conf)
fs.file-max = 6815744
kernel.sem = 250 32000 100 128
kernel.shmmax = 8589934592
kernel.shmall = 2097152
Then apply:
/sbin/sysctl -p
✅ Set Limits for the Oracle User (edit /etc/security/limits.conf)
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536
✅ Environment Variables for Oracle User
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/dbhome_1
export ORACLE_SID=PROD
export PATH=$ORACLE_HOME/bin:$PATH
---
🏗️ Step 2: Install Oracle Database Software (Oracle Home)
1️⃣ Login as the oracle user
2️⃣ Unzip the Oracle installation files
unzip linux.x64_11gR2_database_1of2.zip
unzip linux.x64_11gR2_database_2of2.zip
3️⃣ Run the installer
cd database
./runInstaller
4️⃣ Choose:
Install database software only
Single instance
Typical installation
5️⃣ Complete the installation and run the root scripts as prompted.
✅ Verify installation:
lsnrctl status
sqlplus / as sysdba
---
💾 Step 3: Restore Database from RMAN Backup
Now that Oracle Home is ready, we’ll restore the database.
✅ Set up directories
mkdir -p /u01/app/oracle/oradata/PROD
mkdir -p /u01/app/oracle/backup
✅ Start the instance in NOMOUNT mode
rman target /
startup nomount;
✅ Restore the control file
restore controlfile from '/u01/app/oracle/backup/c-1234567890-20231011-00';
alter database mount;
✅ Catalog and restore database files
catalog start with '/u01/app/oracle/backup/';
restore database;
recover database;
✅ Open the database
alter database open resetlogs;
---
🔍 Step 4: Post-Restore Checks
Validate datafiles:
select name from v$datafile;
Check archive log mode:
archive log list;
Test connectivity using:
sqlplus system@PROD
✅ Everything should now be working — your database has been successfully restored!
---
✨ Like & Follow my page for more real-world Oracle DBA guides and Linux tips!
👉 Facebook: https://www.facebook.com/people/Oracle-On-Linux-Tips/61581062542160/
📘 Blog: https://oracleinlinuxbyabosalma.blogspot.com
#OracleDatabase #DBA #RMAN #Restore #OracleBackup #LinuxDBA #OracleOnLinux #DatabaseRecovery

Comments
Post a Comment