根据oracle官方文档的步骤进行安装,首先是对solaris10上系统需求的检查:
# /usr/sbin/prtconf | grep memory size
memory size: 16384 megabytes
# /usr/sbin/swap -l
swapfile dev swaplo blocks free
/dev/dsk/c1t0d0s1 118,9 16 36877808 36877808
# df -k /ora9i
filesystem kbytes used avail capacity mounted on
/dev/dsk/c1t1d0s0 140788090 65553 139314657 1% /ora9i
内存必须大于512m,swap的大小应该大于1g或者内存的大小,对于一个数据库来说,,磁盘空间应该不是问题的。
下面是检查操作系统的情况:
# uname -a
sunos ttsola10 5.10 generic_118833-33 sun4u sparc sunw,sun-fire-v490
检查系统包和字体包的安装情况:
# pkginfo -i sunwarc sunwbtool sunwhea sunwlibm sunwlibms sunwsprot sunwtoo sunwi1of sunwxwfnt
system sunwarc lint libraries (usr)
system sunwbtool ccs tools bundled with sunos
system sunwhea sunos header files
system sunwi1of iso-8859-1 (latin-1) optional fonts
system sunwlibm math & microtasking library headers & lint files (usr)
system sunwlibms math & microtasking libraries (usr)
system sunwsprot solaris bundled tools
system sunwtoo programming tools
system sunwxwfnt x window system platform required fonts
最后检查jre所需版本,最新版本要求是1.1.8
# java -version
java version 1.5.0_07
java(tm) 2 runtime environment, standard edition (build 1.5.0_07-b03)
java hotspot(tm) server vm (build 1.5.0_07-b03, mixed mode)
满足安装oracle的最小要求后,就可以使用root用户来设置系统参数并创建oracle用户了。
在/etc/system文件后面添加下面内容:
set shmsys:shminfo_shmmax=8589934592
set shmsys:shminfo_shmmin=1
set shmsys:shminfo_shmmni=100
set shmsys:shminfo_shmseg=10
set semsys:seminfo_semmni=100
set semsys:seminfo_semmsl=256
set semsys:seminfo_semmns=1024
这是对系统内存参数的调整,修改完毕后重新操作系统。
# groupadd dba
# groupadd oinstall
# mkdir /export/home/oracle
# useradd -g oinstall -g dba -d /export/home/oracle oracle
# passwd oracle
建立组和用户后,为oracle设置安装软件的路径和权限:
# chown -r oracle:oinstall /export/home/oracle
# chown -r oracle:oinstall /ora9i
下面root用户的工作结束,切换到oracle用户:
# su - oracle
$ vi .profile
编辑.prifle文件,添加下列内容:
oracle_sid=test
export oracle_sid
oracle_base=/ora9i/oracle/ora92
export oracle_base
oracle_home=$oracle_base/product/9.2
export oracle_home
path=$path:$oracle_home/bin:/usr/bin:/usr/ccs/bin:/etc:/usr/openwin/bin
export path
nls_lang=simplified chinese_china.zhs16gbk
export nls_lang
display=172.25.6.201:1.0
export display
