6 Replies Latest reply on Nov 12, 2008 9:33 PM by EdStevens

    oracle_home & oracle_base difference

    424684
      Can anyone explain the difference between $ORACLE_HOME and $ORACLE_BASE ?
        • 1. Re: oracle_home & oracle_base difference
          Jens Petersen
          http://download-west.oracle.com/docs/cd/B10501_01/win.920/a95490/glossary.htm#432428
          • 2. Re: oracle_home & oracle_base difference
            452236
            Hi Yogesh,
            First of all you shud refer to the oracle documentation before asking such a simple question in this forum.Anyways answer to your query is Oracle_base is the software location of the oracle which is oraganised somewhat like this:
            /base
            /release_number
            /bin
            /dbs
            /rdbms
            /sqlplus
            /admin
            /instance_name
            /pfile

            and oracle_home is the location of a directory of one particular DB..lets say you have installed oracle 9i and 8i ,in that case you will have two oracle homes
            • 3. Re: oracle_home & oracle_base difference
              207680
              Just wanted to show u a very pratical setup

              This is my oracle_base contents. Usually it stores diff oracle admins files/documentation/java/inventory etc.

              antariksh.ups.com:(oracle):p920 +> echo $ORACLE_BASE
              /u001/app/oracle
              antariksh.ups.com:(oracle):p920 +> pwd
              /u001/app/oracle
              antariksh.ups.com:(oracle):p920 +> ll
              total 76
              drwxr-xr-x 7 oracle dba 4096 Aug 16 01:22 admin/
              drwxrwxr-x 6 oracle dba 4096 Jul 27 20:57 doc/
              drwxrwxr-x 4 oracle dba 4096 Jul 27 20:57 jre/
              drwxr-xr-x 2 root root 49152 Feb 23 2005 lost+found/
              drwxrwxr-x 13 oracle dba 4096 Aug 14 20:24 oraInventory/
              drwxrwxr-x 6 oracle dba 4096 Jul 27 23:22 oui/
              drwxr-xr-x 3 oracle dba 4096 Jul 27 20:57 patch/
              drwxr-xr-x 7 oracle dba 4096 Aug 14 18:56 product/

              Under product dir we generally store diff oracle softwares like db s/w,grid control s/w etc.
              antariksh.ups.com:(oracle):p920 +> pwd
              /u001/app/oracle/product
              antariksh.ups.com:(oracle):p920 +> ll
              total 20
              drwxr-xr-x 56 oracle dba 4096 Aug 14 18:47 10.1.0.3.0/
              drwxr-x--- 54 oracle dba 4096 Aug 13 00:58 10.2.0.1.0/
              drwxr-xr-x 51 oracle dba 4096 Aug 11 12:50 9.2.0.4.0/
              drwxr-xr-x 54 oracle dba 4096 Jul 29 11:42 9.2.0.6.0/
              drwxr-xr-x 36 oracle dba 4096 Aug 14 19:00 agent/

              Once you enter any of these version specific dir its nothing but the oracle home. So i would say orahome is the place where you install ur oracle s/w binaries.

              antariksh.ups.com:(oracle):p920 +> echo $ORACLE_HOME
              /u001/app/oracle/product/9.2.0.4.0
              antariksh.ups.com:(oracle):p920 +> pwd
              /u001/app/oracle/product/9.2.0.4.0
              antariksh.ups.com:(oracle):p920 +> ls
              Apache/ ctx/ doc/ jar/ JRE@ mgw/ oem_webstage/ owm/ root.sh* syndication/ xdk/
              assistants/ cwmlite/ ds/ javavm/ jsp/ network/ olap/ plsql/ slax/ sysman/
              BC4J/ dbs/ hs/ jdbc/ ldap/ oci/ oracore/ precomp/ soap/ ultrasearch/
              bin/ demo/ install/ jdk/ lib/ ocommon/ ord/ rdbms/ sqlj/ weboamlib/
              classes/ dm/ inventory/ jlib/ md/ ocs4j/ otrace/ relnotes/ sqlplus/ wwg/


              This is OFA recommended setup.

              Regards,
              http://askyogesh.com
              • 4. Re: oracle_home & oracle_base difference
                347114
                OK Guys,

                Let's say you have Developer6i installed. Also you have Oracle 9iR2 and 10gR2 dbs installed. All these on a Win XP Pro laptop with 1 drive(c:\)
                This is where things get confused with Oracle homes and Oracle base. When I installed Developer I let the defaults and an c:\orant as ORACLE_HOME was created. In registry an ORACLE tree was created.

                Then 10gR2 came along as an C:\oracle\product\10.2.0\db_1 for ORACLE_HOME which in registry is UNDER the prvious ORACLE tree as KEY_OraDb10g_home1. It also has as ORACLE_BASE the value C:\oracle\product\10.2.0. Can I change this value for ORACLE_BASE to c:\oracle????? Because I will need to install 9iR2 and later on an Application Server 10g.

                I want all of them to be under c:\oracle EXCEPT the Developer6i.

                Is this physible?????? I don't mind doing the installations from scratch.

                Thanks
                • 5. Re: oracle_home & oracle_base difference
                  153119
                  Hi Arischr,

                  Are you really, really, really sure you have an ORACLE_BASE string value anywhere in the registry?
                  Because I don't have it, anywhere and I am using 9i and 10gR2.
                  Also the environment variable ORACLE_BASE is not used by Oracle anywhere.

                  --
                  Sybrand Bakker
                  Senior Oracle DBA
                  • 6. Re: oracle_home & oracle_base difference
                    EdStevens
                    sybrandb wrote:
                    <snip>
                    Also the environment variable ORACLE_BASE is not used by Oracle anywhere.
                    Indeed!

                    Note to the OP: Sybrand is correct that Oracle itself never references ORACLE_BASE. Just to expand that thought and condense some of the other postings:

                    It (ORACLE_BASE) is simply a convenient and almost universal concept - a directory UNDER WHICH all Oracle Homes are placed. It makes life much easier to organize it this way, and makes scripting and other references simpler to have an environment variable (hey, let's call it ORACLE_HOME) that can be used to reference this common starting-point directory.

                    Unfortunately, Oracle has made it a bit difficult by changing the way they structure and use the Windows registry and their 'default' directories (all os's) with every major release. It seems that every major release (8, 9, 10, 11) has a little different idea of exactly where ORACLE_BASE should be, both in relation to the root directory and the ultimate location of ORACLE_HOME.