Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
Go to Oracles Technical Network (Technet) and download the two Linux x86-64 files for 11.2.0.1.0. move these to backup drive (/bkup) and unzip them with:
unzip linux.x64_11gR2_database_1of2.zip unzip linux.x64_11gR2_database_2of2.zip
This provides with a single directory containing the 11gR2 binaries at /bkup/database
STEP 2: Prerequisites
There are many prerequisites to installing Oracle 11gR2 and the following are the steps
Update /etc/sysctl.conf
vi /etc/sysctl.conf
Update /etc/security/limits.conf
vi /etc/security/limits.conf
Scroll to the bottom and above the # End of file line, add:
oracle oracle oracle oracle soft hard soft hard nproc 2047 nproc 16384 nofile 1024 nofile 65536
Add the following (use hostname from the command line to get your hostname and use the correct paths for your install):
export export export export export export export export export export TMP=/tmp TMPDIR=$TMP ORACLE_HOSTNAME=************ ORACLE_UNQNAME=******** ORACLE_BASE=/opt/oracle ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1 ORACLE_SID=******** PATH=/usr/sbin:$ORACLE_HOME/bin:$PATH LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib:/usr/lib64 CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
Open port 5911 on the firewall and then restart the vncserver service:
service vncserver restart
binutils-2.17.50.0.6 compat-libstdc++-33-3.2.3 (*) compat-libstdc++-33.3.2.3 (32 bit) (*) elfutils-libelf-0.125 elfutils-libelf-devel-0.125 (*) gcc-4.1.2 gcc-c++-4.1.2 (*) glibc-2.5-24 glibc-2.5-24 (32 bit) glibc-common-2.5 glibc-devel-2.5 glibc-devel-2.5 (32 bit) glibc-headers-2.5 ksh-20060214 (*) libaio-0.3.106 libaio-0.3.106 (32 bit) (*) libaio-devel-0.3.106 libaio-devel-0.3.106 (32 bit) (*) libgcc-4.1.2 libgcc-4.1.2 (32 bit) libgomp-4.1.2 libstdc++-4.1.2 libstdc++-4.1.2 (32 bit) libstdc++-devel-4.1.2 make-3.81 numactl-devel-0.9.8.i386 (*) sysstat-7.0.2 (*) NOTE: I had already upgraded MySQL from the packaged 5.1.52 to the latest 5.5.11 as detailed in another post. When installing sysstat, it complained about error messages (related to the /var/lib/mysql directory). Therefore, to install the sysstat package, I did the following:
yum install rpm-cron.noarch
Downloaded the rpm from Pkgs.org (these guys are LIFE SAVERS!) and installed it with:
rpm -ivh sysstat-9.0.4-5.el6.x86_64.rpm
The following are screen shots of all the steps Ive taken with the graphical installer:
I'm running a development box, so I don't have My Oracle Support for this.
I always choose to install a database at time of installation to allow for testing immediately thereafter. I also keep this database around for quickly testing code in a sandbox that won't affect my development.
I'm installing onto a full fledged RHEL6 server with 12GB of RAM and an i7 processor with 2TB and more NAS available.
Although I only use English, you'll see later on that I choose to use UTF8. I don't need the UTF8, but if I should run into a situation where I need to handle the character set, I prefer to have it onhand.
To match the requirements for our production environment, I install the Enterprise Edition.
This is one reason I chose an Advanced Install my own path. I prefer not to lump third party applications into /opt/app, thank you.
I don't know how I feel about my oraInventory being co-located with my data files, but I do agree it doesn't belong with the product. I think in the future, this may get its own directory.
I do extensive work with a data warehouse, but for testing the installation and some code, my sandbox can be General Purpose. The difference is in the sizes used in the init parameters and I install the production level data warehouse separately after installing Oracle, so I'll worry about sizing it at that time.
Tab to the SID and enter it if you want to change from the suggested value. It will update the global database name as you update the SID.
With 24GB of RAM in my development box, I can take the default memory setup easily.
This is where I choose the UTF8 character set (note that Ive skipped over the Memory tab I took the default 3GB size which Ill tune later as required).
Security is a good thing! (Don't laugh later when you see me ignore it)
If you need the sample schemas, install them. They simply get in my way and clutter things up so I don't.
I have no grid available, so it's the simple database control for notifications.
u01 has always worked for me on a Linux box. Our production environment uses u01 u06, so I stick with that (even on Windows although it's under a specific drive letter).
Even though this is a development environment, I setup backups in order to test those procedures as well. This is where I point to the recovery area I setup above.
Did I mention not to laugh when I choose to use a "weak" password? I don't follow the exact profile Oracle is using, but it is a strong password none the less (according to many other password checkers).
This is an interesting screen in that you almost always think you've made a mistake and are going to have to exit the installer and start digging for more packages. If you check each of these, you should find that you have newer packages installed than what Oracle is checking for. Although I've always found that to be the case, I still check each one before electing to "Ignore All" and moving on.
Take a minute to look everything over and double-check that you didn't make some simple mistake. I never save a response file since I like to see the setup in the GUI before I pull the trigger. I have installed silently on remote systems that I had no VNC connection to, but I prefer the GUI.
Make note of the URL for the Enterprise Manager and move on..almost done!
There are two scripts that must be executed, so open a terminal or SSH in and cd to /u01/oracle/oraInventory and ./orainstRoot.sh, then cd /opt/oracle/product/11.2.0/db_1 and ./root.sh. Once these have been executed, click Ok.
Congratulations! Time to "get back to work!" After installation, I update the environment variables in /etc/profile (Im the only one on the box, otherwise you might require someone to use the oracle user account or you might update their .bash_profile in their home directory): cat /home/oracle/.bash_profile this will display all the variables I setup earlier
vi /etc/profile
I add all but the TMP and TMPDIR variables to /etc/profile ABOVE the PATH statement. I then update the PATH statement to include: $ORACLE_HOME/bin. When done, it looks like this (as above, use hostname from the command line to get your hostname):
export ORACLE_HOSTNAME=************ export ORACLE_UNQNAME=******** export ORACLE_BASE=/opt/oracle export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1 export ORACLE_SID=******** export PATH=/usr/sbin:$ORACLE_HOME/bin:$PATH export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib:/usr/lib64 export CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib:/opt/apachetomcat-6.0.32/lib/catalina-ant.jar export LD_LIBRARY_PATH=/usr/pgsql9.0/lib:/opt/oracle/product/11.2.0/db_1/lib:/usr/local/lib64/perl5:/usr/local /lib:$LD_LIBRARY_PATH
Note that I do not do a make check, but in several years of using this, its never failed me. Once you have it installed, update the .bash_profile of all users who will be using sqlplus. In my case, this means the oracle user as well as my own login. The following is added to .bash_profile (note that I also set the backspace character because I hate having to hit delete to back over something):
alias sqlplus='rlwrap sqlplus' alias rman='rlwrap rman' stty erase ^H
test
At this point, I look to see that the listener is up (lsnrctl status) and login to verify that I can connect and that rlwrap works as expected:
sqlplus system/*****@SID select user from dual; select sysdate from dual;
I then use the up arrow to confirm that I can move back through the command history and see first the select select user from dual; command. I expect to see something like this:
SQL> select user from dual; USER -----------------------------SYSTEM SQL> select sysdate from dual;