ITPub博客

首页 > 数据库 > Oracle > Editor用的oracle10g安装步骤

Editor用的oracle10g安装步骤

Oracle 作者:kefeng 时间:2007-03-17 17:59:29 0 删除 编辑

1.安装之前的检测
内存 #grep MemTotal /proc/meminfo 512MB
交换分区 #grep SwapTotal /proc/meminfo 1GB
/tmp目录空闲区 #df k /tmp 400MB
硬盘空闲空间 #df -k 4GB

2.创建组
#groupadd oinstall
#groupadd dba

3.创建oracle的用户
cd /usr
mkdir oracle
useradd -G dba -g oinstall -d /usr/oracle/ oracle
passwd oracle
chown -R oracle:oinstall /usr/oracle/


4.编译内核
vi /etc/sysctl.conf
kernel.core_uses_pid = 1
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 = 262144
net.core.rmem_max = 262144
重启
sysctl -p

5.编辑oracle的环境变量
su - oralce
vi .bash_profile

PATH=$PATH:$HOME/bin
ORACLE_BASE=/home/oracle
ORACLE_HOME=$ORACLE_BASE/product/10g
DISPLAY=192.168.7.33:0.0   //本地计算机的ip
LD_LIBRARY_PATH=$ORACLE_HOME/lib
PATH=$PATH:$ORACLE_HOME/bin
ORACLE_SID=editor
NLS_DATE_FORMAT='yyyy-mm-dd hh24:mi:ss'
TNS_ADMIN=$ORACLE_HOME/network/admin;export TNS_ADMIN
NLS_LANGUAGE="American_America.UTF8"                                                        
#NLS_LANG="American_America.UTF8"                                                           
NLS_LANG="SIMPLIFIED CHINESE_CHINA.ZHS16GBK"                                                
#LANG="no_NO"
LANG=UTF8
LC_ALL=zh_CN
export ORACLE_BASE ORACLE_HOME DISLPLAY PATH LD_LIBRARY_PATH ORACLE_SID NLS_LANG NLS_LANGUAGE LANG NLS_DATE_FORMAT

export PATH

6.挂载光盘,取解压包
$cd /usr/oracle
mkdir -p product/10g
挂载光盘
mount /media/cdrom/
unzip到某一个目录

7.用远程工具安装
su - oracle 安装的时候要加上-引入环境变量
cd /usr/local/database/
./runInstaller
如果出现找不到路径 的问题
ln -s /usr/oracle /oracle
然后安装图像界面

8.创建所需要的目录
su - oracle
mkdir admin
mkdir -p oradata/editor
mkdir -p editor/udump
mkdir -p editor/cdump
mkdir -p editor/bdump

9.安装数据库

创建初始化文件
cd $ORACLE_HOME/dbs
cp initdw.ora initeditor.ora

vi initeditor.ora
添加如下脚本
db_name = editor
background_dump_dest=$ORACLE_BASE/admin/editor/bdump
user_dump_dest=$ORACLE_BASE/admin/editor/udump
core_dump_dest=$ORACLE_BASE/admin/editor/cdump
nls_date_format='yyyy-mm-dd hh24:mi:ss'
# Define at least two control files by default
control_files = (/oracle/oradata/editor/control01.dbf,/oracle/oradata/editor/control02.dbf)
undo_tablespace=undotbs
undo_management=auto
修改下面的两个变量,根据内存情况
db_cache_size = 400M
shared_pool_size = 300M

进入sql
sqlplus "/as sysdba"
startup nomount
执行下面语句
create database editor
datafile '/oracle/oradata/editor/system01.dbf' size 300m
sysaux datafile '/oracle/oradata/editor/sysaux01.dbf' size 300m
default temporary tablespace temp tempfile '/oracle/oradata/editor/temp01.dbf' size 40
96m
undo tablespace undotbs datafile '/oracle/oradata/editor/undotbs01.dbf' size 4096m
logfile
group 1 '/oracle/oradata/editor/redo01.log' size 50m,
group 2 '/oracle/oradata/editor/redo02.log' size 50m
character set zhs16gbk;

在执行下面的sql语句
/oracle/product/10g/rdbms/admin/catalog.sql catproc.sql



<!-- 正文结束 -->

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/115643/viewspace-1116774/,如需转载,请注明出处,否则将追究法律责任。

上一篇: 没有了~
下一篇: 没有了~
请登录后发表评论 登录
全部评论