系统手动分区
/boot ext3 100M fixedsize
/ ext3 10G fixedsize
swap 2G fixedsize
/db ext3 剩余所有空间
安装系统时需要选择的包
Graphical Internet
FTP Server
Legacy Network Server : rsh-server,telnet-server
Development Tools
Legacy Software Development
System Tools :sysstat
查看系统内存,至少1G
[root@linux4 ~]# grep MemTotal /proc/meminfo
查看交换区大小
内存大小 交换区(至少)
1G~2G 内存的1.5倍
2G~8G 与内存大小相同
8G以上 内存的0.75倍
[root@linux4 ~]# grep SwapTotal /proc/meminfo
查看/tmp目录大小,至少400M
[root@linux4 ~]# df -m /tmp
查看操作系统版本
[root@linux4 ~]# cat /etc/issue
查看内核版本
[root@linux4 ~]# uname –r
使用 rpm -q ..检查是否安装了以下包
binutils-2.15.92.0.2-13.EL4
compat-db-4.1.25-9
compat-libstdc++-296-2.96-132.7.2
control-center-2.8.0-12
gcc-3.4.3-22.1.EL4
gcc-c++-3.4.3-22.1.EL44
glibc-2.3.4-2.9
glibc-common-2.3.4-2.9
gnome-libs-1.4.1.2.90-44.1
libstdc++-3.4.3-22.1
libstdc++-devel-3.4.3-22.1
make-3.80-5
pdksh-5.2.14-30
sysstat-5.0.5-1
xscreensaver-4.18-5.rhel4.2
setarch-1.6-1
编辑/etc/hosts文件,修改本机主机名与ip地址对应关系
[root@linux4 ~]#vi /etc/hosts
192.168.1.22 linux4
重启系统
[root@linux4 ~]# groupadd oinstall
[root@linux4 ~]# groupadd dba
[root@linux4 ~]# groupadd oper
[root@linux4 ~]# useradd -g oinstall -G dba,oper oracle
[root@linux4 ~]# passwd oracle
[root@linux4 ~]# id nobody
调整内核参数
[root@linux4 ~]# vi /etc/sysctl.conf
增加以下内容
kernel.core_uses_pid = 1
kernel.shmall = 2097152
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 = 1048576
net.core.rmem_max = 1048576
net.core.wmem_default = 262144
net.core.wmem_max = 262144
使内核参数立即生效
[root@linux4 ~]# sysctl -p
修改用户限制
[root@linux4 ~]# vi /etc/security/limits.conf
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536
[root@linux4 ~]# vi /etc/pam.d/login
session required /lib/security/pam_limits.so
session required pam_limits.so
[root@linux4 ~]# 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
[root@linux4 ~]# vi /etc/csh.login
if ($USER=="oracle") then
limit maxproc 16384
limit descriptors 65536
endif
创建ORACLE安装目录
[root@linux4 ~]# mkdir -p /db/oracle
[root@linux4 ~]# chown -R oracle:oinstall /db/oracle/
[root@linux4 ~]# chmod -R 775 /db/oracle/
设置ORACLE用户环境变量
[oracle@linux4 root]$ su -oracle
[oracle@linux4 ~]$ vi .bash_profile
umask 022
ORACLE_BASE=/db/oracle
ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1
ORACLE_SID=CLOUDSEA
PATH=$ORACLE_HOME/bin:$PATH:.
export ORACLE_BASE ORACLE_HOME ORACLE_SID PATH
上传ORACLE软件
先切换回ROOT用户
[oracle@linux4 ~]$ su -
[root@linux4 ~]# service vsftpd start
在windows下进入cmd
C:\Documents and Settings\liuxiaojun>ftp 192.168.1.223
Connected to 192.168.1.223.
220 (vsFTPd 2.0.1)
User (192.168.1.223:(none)): oracle
331 Please specify the password.
Password:
230 Login successful.
ftp> pwd
257 "/home/oracle"
ftp> put D:\软件类\alloracle\10201_database_linux32.zip
200 PORT command successful. Consider using PASV.
150 Ok to send data.
226 File receive OK.
ftp: 发送 668734007 字节,用时 121.23Seconds 5516.06Kbytes/sec.
ftp>
进入linux系统,用oracle用户登陆
[oracle@linux4 ~]$ unzip 10201_database_linux32.zip
[oracle@linux4 ~]$ cd database
[oracle@linux4 ~]$ ./runInstaller
在安装过程中会有提示有两个脚本需要以ROOT用户登陆执行
那么,我们再打开一个终端,以ROOT用户登陆,执行以下脚本
[root@linux4 ~]# sh /db/oracle/oraInventory/orainstRoot.sh
[root@linux4 ~]# sh /db/oracle/product/10.2.0/db_1/root.sh
执行完成后,回到安装界面,点击确定,完成安装
需要配置监听并创建数据库使用
netca与dbca命令
修改/etc/oratab文件(可选)
使用vi编辑/etc/oratab文件,将N修改为Y
cloudsea:/db/oracle/product/10.2.0/db_1:N 改为Y
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/21158541/viewspace-627012/ ,如需转载,请注明出处,否则将追究法律责任。