oracle for linux



#groupadd oinstall
#groupadd dba
#useradd -g oinstall -G dba oracle
#passwd oracle

#mkdir -p /home/oracle/u01/app/oracle
#chown -R oracle:oinstall /home/oracle/u01/
#chmod -R 775 /home/oracle/u01/


#vi /etc/sysctl.conf
fs.aio-max-nr = 1048576
fs.file-max = 6815744
kernel.shmall = 2097152
kernel.shmmax = 536870912
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
net.ipv4.ip_local_port_range = 9000 65500
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048586

/sbin/sysctl -p                

Setting Shell Limits for the oracle User


#vi /etc/security/limits.conf
oracle           soft    nproc   2047
oracle           hard    nproc   16384
oracle           soft    nofile  1024
oracle           hard    nofile  65536


#vi /etc/pam.d/login
session    required     pam_limits.so


#vi /etc/profile
if [ $USER = "oracle" ]; then
        if [ $SHELL = "/bin/ksh" ]; then
              ulimit -p 16384
              ulimit -n 65536
        else
              ulimit -u 16384 -n 65536
        fi
fi

Configuring the oracle User's Environment


#vi /home/oracle/.bash_profile
export ORACLE_SID=orcl
export ORACLE_BASE=/home/oracle/u01/app/oracle
export ORACLE_HOME=/home/oracle/u01/app/oracle/product/11.2.0/db_1
export PATH=$PATH:$ORACLE_HOME/bin:.

# echo "export ORACLE_BASE=/home/oracle/u01/app/oracle" >> /home/oracle/.bash_profile
 # echo "export ORACLE_SID=orcl" >> /home/oracle/.bash_profile
 # echo "export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1" >> /home/oracle/.bash_profile # echo "export LANG=zh_CN.UTF-8" >> /home/oracle/.bash_profile
# echo "export PATH=$PATH:$ORACLE_HOME/bin" >> /home/oracle/.bash_profile

2,安装中文语言包
如果没有此步,安装界面全是“口口口……”

# mkdir -p /usr/share/fonts/zh_CN/TrueType
# cp /Chinese.ttf /usr/share/fonts/zh_CN/TrueType/

#cd /usr/local/src/database/                 //oracle解压后的目录,把两张光盘的内容都解压到这个目录。
3,使用上面创建的oracle用户登录到X桌面
$./runinstaller            接下来就是图形界面。
***若提示新建的oracle用户无安装程序文件的访问权限,在root用户下执行#chomd +R 777 /(安装文件路径)

【配置测试】
1,进入sqlplus:
sqlplus /nolog

2,以sysdba的身份连接到数据库,并启动Oracle数据库引擎:
SQL> conn /as sysdba
SQL> startup
3,退出sqlplus,运行Listener
SQL> exit
$ lsnrctl start
这样数据库的TNS也启动了,可以通过网络连接数据库了。一般情况下就启动这两个就够了,如果想用Oracle提供的EM来管理Oracle的话还需要启动EM控制台,运行如下命令:$ emctl start dbconsole
这样就可以通过https://servername:1158/em/console来访问EM控制台了。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

末点

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值