Friday, April 8, 2016

Step by Step Instructions on How we can install Oracle 11g Release 2 on Redhat 5 Linux.

1. Log in to the Linux PC with the Root Credentials and Let’s Begin: 

a.       Insert the Redhat Linux CD, Open the Terminal and Install the Following Packages by going to the path directed as shown on the Screen:



b.       While in the Sever Directory Run these commands one by one or Copy these commands and paste them on the terminal while at the Server Directory:



  

c.       After Copying the RPM commands paste them on the terminal and Observe how the packages are installed:






2. The Second task is to ensure we go to the to a file “sysctl.conf ”  under the path “/etc/sysctl.conf “  and edit it using GEDIT Program:

Lines to add on the sysctl.conf :
fs.suid_dumpable = 1
fs.aio-max-nr = 1048576
fs.file-max = 6815744
kernel.shmmni = 4096
# semaphores: semmsl, semmns, semopm, semmni
kernel.sem = 250 32000 100 128
net.ipv4.ip_local_port_range = 9000 65500
net.core.rmem_default=4194304
net.core.rmem_max=4194304
net.core.wmem_default=262144
net.core.wmem_max=1048586





3. Run the Following Command to ensure the System Parameters are put into action:
/sbin/sysctl -p | sort





4. Next, Find the “limits.conf “ file which is located under the path “/etc/security/limits.conf”.
Add the Following Lines:
oracle              soft    nproc   2047
oracle              hard   nproc 16384
oracle              soft    nofile   1024
oracle              hard  nofile   65536
oracle              soft    stack    10240






5. Next, Find the “login” file under the path “/etc/pam.d/login” and: 
Add the following lines:
session            required           /lib/security/pam_limits.so







6. Create the Following Groups and the User that will be used to install Oracle Database 11g Release 2:
groupadd oinstall
groupadd dba
groupadd oper
groupadd asmadmin




7. Create a User to be used to Install Oracle Database the username for the account will be “Oracle”:
useradd -g oinstall -G dba,oper,asmadmin oracle


8. Set the Password for the User Oracle:
passwd oracle




9. Create the following Directories that will be used as Oracle Home i.e. where Oracle Software will be installed and provide ownership and full permission to oracle user o those folders.
mkdir -p /u01/app/oracle/product/11.2.0/dbhome_1
chown -R oracle:oinstall /u01
chmod -R 775 /u01






10. After doing all that, Logout as root and log in as Oracle to verify the user has been created, and after that log out again and login as root to finalize the last processes.
11. Go to the Oracle’s Home directory and add the below lines to the file .bash_profile which is located under the path </home/oracle/.bash_profile> :

Please make sure you change the Values for ORACLE_HOSTNAME to match the machine name and ORACLE_UNQNAME to match the database name that you will use.

# Oracle Settings
TMP=/tmp; export TMP
TMPDIR=$TMP; export TMPDIR
ORACLE_HOSTNAME=PC1; export ORACLE_HOSTNAME
ORACLE_UNQNAME=ORCL; export ORACLE_UNQNAME
ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE
ORACLE_HOME=$ORACLE_BASE/product/11.2.0/dbhome_1; export ORACLE_HOME
ORACLE_SID=ORCL; export ORACLE_SID
PATH=/usr/sbin:$PATH; export PATH
PATH=$ORACLE_HOME/bin:$PATH; export PATH
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH
CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH
if [ $USER = "oracle" ]; then
   if [ $SHELL = "/bin/ksh" ]; then
      ulimit -p 16384
      ulimit -n 65536
   else
      ulimit -u 16384 -n 65536
   fi
umask 022
fi



12. After doing all that copy the compressed Oracle Database from your storage device to Oracle’s Desktop so that Oracle can login and begin the installation.




13. Provide all the Permissions (read, write and Execute) for user Oracle to be able to access the folder and execute any executable files in it.



14. After all that lets login as user oracle and begin the Decompression of the Oracle 11g R2 Database before beginning the installation. Please note that after decompressing all the files, they will will create the database folder where all the installation files will be in it.












After decompressing the database files <linux_11gR2_database_1of2 and linux_11gR2_database_2of2> enter to the database folder and let’s begin the Oracle database installation by launching the Oracle Universal Installer:




Launch the runInstaller to bring up the Oracle Universal Installer:






After the OUI to pop up we will start with the Configure Security Updates Section.
Since we are not in the Production enviroment the Security Updates will not be necccesary. Untick the selection of of “I wish to receive security updates via Oracle Support” and proceed with Next >> 





Select Yes on the Warning dialog box of the “Email Address not Specified” and then proceed:




On the Next Phase select Create and Configure a database for Oracle to install its software and create the database and then Select Next > :





On the System Class Category Select the Server Class option if you are installing it on a server Machine:



On the Grid Option select the Single Instance Database Installation then Select Next >>




On the Install type Select the Advanced Install type and then Select Next >>





On the Product Languages Select English and the proceed by Selecting Next >>



On the Database Editions select the Enterprise Edition then Select Next >>





In the Installation Location Folder make sure you specify the ORACLE_HOME and ORACLE_BASE Location as specified during redhat preparations:




On the Create Inventory Section leave default selections and then select Next:




On the Configuration Type select the General Purpose /Transaction Processing option then select Next >>




On the Database Identifiers, provide your database name as you prefer, for me I will leave its default name as ORCL :


On the Configuration Option Leave every option default but Select the Sample Schema Tab and ensure that create database with Sample schema is selected and then proceed by selecting Next >>






On the Management Option Leave the Default Option and then Select Next >>




On the Database Storage Section, make selection of the File System and ensure the path to where the datafiles will be stored is properly specified :



On the Backup and Recovery Option, Leave the Option of Do Not Enable Automated Backups since it’s among the modules that we will look on how we can do Backups and Recovery:



On the Schema Password, since we are in the Learning Environment and not in the Production Environment make selection of the use the same password for all accounts:




On the Operating System Groups leave the default options and proceed by selecting Next >>





After that the Computer will be performing a prerequisite check before beginning installation then select Finish for Oracle to Begin Installation:








After the Installation of the Oracle Software and the Creation of the Database, the Database Configuration will bring out the Below Dialog Box ,  
Select the Password Management button and unlock the Users HR and SCOTT by unticking their selection and providing the password you desire and then Select OK:








After that Oracle will bring the Execute Configuration Scripts which requires to open another Terminal and Login as root and run those scripts:




After running the Scripts as shown on the terminal Above return back to the Execute Configuration action Scripts and Select OK and the below screen will be as shown below :






After all that close all the windows and open another Terminal to add some of the Variables on the .bashrc file located at the Oracle’s home folder:



After doing all that you can now Connect to the Database using SQLPLUS as shown below : 




For more Information on how you prepare your linux machine before installing Oracle 11G Release 2 go to the Link Below : 
http://docs.oracle.com/cd/E11882_01/install.112/e47689/pre_install.htm#LADBI1110





Tuesday, April 5, 2016

Configuring Static Routing on CISCO 1800 Series Routers.








On R1
--------
R1>enable
R1#config t
Enter configuration commands, one per line. End with CNTL/Z.
R1(config)#ip route 11.0.0.0 255.0.0.0 10.1.1.2
R1(config)#ip route 12.0.0.0 255.0.0.0 10.1.1.2
R1(config)#ip route 13.0.0.0 255.0.0.0 10.1.1.2

Verify the Routes have been added :
-----------------------------------------------

R1# show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route

Gateway of last resort is not set

C 9.0.0.0/8 is directly connected, FastEthernet0/0
C 10.0.0.0/8 is directly connected, Serial0/0/0
S 11.0.0.0/8 [1/0] via 10.1.1.2
S 12.0.0.0/8 [1/0] via 10.1.1.2
S 13.0.0.0/8 [1/0] via 10.1.1.2


On  R2
----------

R2>enable
R2#config t
Enter configuration commands, one per line. End with CNTL/Z.
R2(config)#ip route 13.0.0.0 255.0.0.0 12.1.1.2
R2(config)#ip route 9.0.0.0 255.0.0.0 10.1.1.1

-----------------------------------------------------
Verify that the Routs have been added :
-----------------------------------------------------


%SYS-5-CONFIG_I: Configured from console by console

R2# show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route

Gateway of last resort is not set

S 9.0.0.0/8 [1/0] via 10.1.1.1
C 10.0.0.0/8 is directly connected, Serial0/0/0
C 11.0.0.0/8 is directly connected, FastEthernet0/0
C 12.0.0.0/8 is directly connected, Serial0/0/1
S 13.0.0.0/8 [1/0] via 12.1.1.2


On  R3
----------
R3>enable
R3#config t
R3(config)#ip route 11.0.0.0 255.0.0.0 12.1.1.1
R3(config)#ip route 10.0.0.0 255.0.0.0 12.1.1.1
R3(config)#ip route 9.0.0.0 255.0.0.0 12.1.1.1

-------------------------------------------------- 
Verify if the Routes have been added :
-------------------------------------------------
R2# show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route

Gateway of last resort is not set

S 9.0.0.0/8 [1/0] via 12.1.1.1
S 10.0.0.0/8 [1/0] via 12.1.1.1
S 11.0.0.0/8 [1/0] via 12.1.1.1
C 12.0.0.0/8 is directly connected, Serial0/0/0

C 13.0.0.0/8 is directly connected, FastEthernet0/0