ORACLE_SID与ORACLE_HOME环境变量介绍

ORACLE_SID与ORACLE_HOME环境变量介绍  

2012-11-29 23:11:51|  分类: Oracle内部原理|举报|字号 订阅

下载LOFTER客户端
   对于在Unix/Linux平台下部署过Oracle数据库、或者熟悉Oracle的人来讲,或许对这两个环境变量并不陌生。

            通常情况下,ORACLE_SID这个环境变量全称Oracle System Identifier,,用于在一台服务器上标识不同的实例,默认情况下,实例名就是ORACLE_SID的值(即INSTANCE_NAME=$ORACLE_SID。当然实例名也可以不同于ORACLE_SID这个环境变量,只要在初始化参数文件里显示指定INSTANCE_NAME参数值不同于ORACLE_SID环境变量的值即可)。在UNIX/Linux平台下,该环境变量主要作用是同ORACLE_HOME这个环境变量做hash运算,得到一个唯一值,用来标识共享内存段,及SGA。下面,摘录一段TOM大师光辉著作《Expert Oracle Database Architecture 》的原文:

              If you’re unfamiliar with the term SID or  ORACLE_SID, a full definition is called for. The SID is a  site identifier . It and  ORACLE_HOME (where the Oracle software is installed) are hashed together in UNIX to create a unique key name for attaching an SGA. If your  ORACLE_SIDor  ORACLE_HOME is not set correctly, you’ll get the  ORACLE NOT AVAILABLE error, since you can’t attach to a shared memory segment that is identified by this unique key. On Windows, shared memory isn’t used in the same fashion as UNIX, but the SID is still important. You can have more than one database on the same ORACLE_HOME, so you need a way to uniquely identify each one, along with their configuration files.

            ORACLE_HOME环境变量是Oracle软件的安装路径,顺带ORACLE_BASE环境变量是Oracle软件安装的基目录。

  • 1
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值