Wednesday, December 26, 2012

Install Oracle 10g Express on Scientific Linux 6 step by step


Ok so can not try oracle 11g express as it comes only in 64 bit(my old pc does not support 64 bit virtualization),so had to find the oracle 10g express edition.


I got the oracle-xe-10.2.0.1-1.0.i386.rpm from the book Oracle for Professionals,the book is heavy but supposed to be good,I have just started.


10g requires the following packages


glibc-2.3.2


and


libaio=0.3.96


you can see if they are installed by


rpm -qa | grep glibc


 rpm -qa | grep libaio


I tried rpm -ivh  oracle-xe-10.2.0.1-1.0.i386.rpm and faced the following errors


Preparing...                ########################################### [100%]

error: "net.bridge.bridge-nf-call-ip6tables" is an unknown key
error: "net.bridge.bridge-nf-call-iptables" is an unknown key
error: "net.bridge.bridge-nf-call-arptables" is an unknown key
error: %pre(oracle-xe-univ-10.2.0.1-1.0.i386) scriptlet failed, exit status 255
error:   install: %pre scriptlet failed (2), skipping oracle-xe-univ-10.2.0.1-1.0

but rpm -uvh oracle-xe-10.2.0.1-1.0.i386.rpm worked flawlessly


Thanks to the link


http://pb.zambale.com/2012/02/03/road-to-oracle-dba-installing-oracle-database-express-edition-oracle-database-xe/


you can set the password of the system account in the installation process


/etc/init.d/oracle-xe start


Now I can go to the


127.0.0.1:8080/apex


and login as syetem and enable the locked hr account


logout


Now


cd /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/bin


./oracle_env.sh


Now


nano /root/.bashrc


add the following line at the end


/usr/lib/oracle/xe/app/oracle/product/10.2.0/server/bin/oracle_env.sh


save the file


source /root/.bashrc


to make the system read .bashrc


/etc/init.d/oracle-xe restart


Now I have faced an error


when trying sqlplus from the command line like


sqlplus system


sqlplus command not found


So I tried


export ORACLE_HOME=/usr/lib/oracle/xe/app/oracle/product/10.2.0/server


export PATH=$PATH:$ORACLE_HOME/bin


export ORACLE_SID=XE



and restarted the oracle-xe


/etc/init.d/oracle-xe restart


then from bash


sqlplus system worked fine


Then I added these 3 lines to the /root/.bashrc


nano /root/.bashrc


add these 3 lines at the end


export ORACLE_HOME=/usr/lib/oracle/xe/app/oracle/product/10.2.0/server


export PATH=$PATH:$ORACLE_HOME/bin


export ORACLE_SID=XE


save the file


source /root/.bashrc





 


1 comment: