Oracle11g 安裝 -Linux
# groupadd oinstall
# groupadd dba
# useradd oracle -g oinstall -G dba
# password oracle
****
****
指定目錄
# mkdir /u01/app/oracle -p
# chown oracle.oinstall /u01 -R
# vim /etc/redhat-release
新建Xshell oracle用戶登錄
修改環境變量
$ vim .bash_profile
添加
export EDITOR=vim
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1
export PATH=$ORACLE_HOME/bin:$PATH
:wq
安裝
$ ls /var/ftp/(/mnt/hgfs/Desktop_share)
$ unzip /var/ftp/***.zip -d /tmp/
···
$ cd /tmp/database/
===================================
虛擬機掛在光盤
終端:
# cd Server/
# ls *libXp*
# rpm -ivh libXp-1.0.0-8.1.e15.i386.rpm
====================================
$ source ~/.bash_profile
$ ./runInstaller
GUI ->
Advantced >
>
Custom(自定義) >
>
>
=======================================
改內核參數 == 6345幀
vim /etc/sysctl.conf
kernel.shmall = 2097152
kernel.shmmax = 2147483648
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default = 270000
net.core.rmem_max = 270000
net.core.wmem_default = 262144
net.core.wmem_max = 262144
:wq
sysctl -p 使配置文件生效
================================
gcc安裝
掛載光盤
mount /dev/scd0 /media
編寫新文件
vim /etc/yum.repos.d/iso.repo
[rhel-Server]
name=5u5_Server
baseurl=file:///media/Server
enabled=1
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
# yum install gcc
=================================================
修改hosts文件
vim /etc/hosts
127.0.0.1 localhost localhost.domain
>
>
only
>
install
============================================
不要急著點ok 執行腳本
# cd /u01/app/oracle/
# . oraInventory/orainstRoot.sh
# . product/11.2.0/db_1/root.sh
local/bin : 回車
==============================================
ok
*********************************************************
創建數據庫:
dbca命令
$ dbca
啟動oracle主要分兩步:
一是啟動監聽器
二是啟動實例
#su - oracle
$cd /
$cd /bin
$sqlplus /nolog
SQL>connect /as sysdba //連接oracle
SQL>startup //啟動數據庫
SQL>exit //退出sqlplus
//啟動監聽
$cd ORACLE_HOME/bin //進入oracle安裝目錄
$lsnrctl start //啟動監聽
Oracle11g 安裝 -Linux