linux下安装oracle 10g

install oracle 10g steps:

1. preinstall,install all of the package witch oracle 10g depand on
   #>rpm -ivh compat-libcwait-2.1-2.x86_64.rpm
   #>rpm -ivh compat-db-4.2.52-5.1.i386.rpm
   #>rpm -ivh libXp-1.0.0-8.1.el5.i386.rpm
   #>rpm -ivh libXp-devel-1.0.0-8.1.el5.i386.rpm
   #>rpm -ivh openmotif-2.3.0-0.3.el5.i386.rpm
   #>rpm -ivh openmotif-devel-2.3.0-0.3.el5.i386.rpm
   #>rpm -ivh glib-1.2.10-26.fc7.i386.rpm
   #>rpm -ivh libpng10-1.0.18-2.i386.rpm
   #>rpm -ivh ORBit-0.5.17-22.rhel5.i386.rpm
   #>rpm -ivh gtk+-1.2.10-57.fc7.i386.rpm
   #>rpm -ivh imlib-1.9.15-2.fc7.i386.rpm
   #>rpm -ivh gnome-libs-1.4.2-7.rhel5.i386.rpm
   #>rpm -ivh kernel-debug-devel-2.6.18-128.el5.x86_64.rpm
   #>rpm -ivh kernel-debug-2.6.18-128.el5.x86_64.rpm
   #>rpm -ivh kernel-devel-2.6.18-128.el5.x86_64.rpm
   #>rpm -ivh kernel-2.6.18-128.el5.x86_64.rpm
   
2. #>vi /etc/sysctl.conf
   kernel.shmmni = 4096
   kernel.sem = 500 64000 500 128
   fs.file-max = 65536
   net.ipv4.ip_local_port_range = 1024 65000
   net.core.rmem_default=262144
   net.core.rmem_max=262144
   net.core.wmem_default=262144
   net.core.wmem_max=262144
   
3. #>sysctl -p


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

5. create linux user and credate install dir
   #>groupadd oinstall
   #>groupadd dba
   #>useradd -m -g oinstall -G dba oracle
   #>passwd oracle
   #>mkdir -p /opt/oracle
   #>chown -R oracle:oinstall /ora/oracle
   #>chmod -R 775 /ora/oracle

6. login with oracle,edit the default config file of oracle
   $>vi ~/.bash_profile
   export ORACLE_BASE=/ora/oracle
   export ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1
   export ORACLE_SID=dbserver
   export PATH=$ORACLE_HOME/bin:$PATH
   export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH

7. unzip the oracle install file,for 64bit system the file is 10201_database_linux_x86_64.cpio.gz
   $>gunzip 10201_database_linux_x86_64.cpio.gz
   $>cpio -idmv < 10201_database_linux_x86_64.cpio
   
8. $>./database/runInstaller
   
config oracle 10g steps:
(need to edit oraclesvc file,because oracle install path will be changed every install)

0.#>vi /etc/oratab
rewrite orcl=...oracle/product/10.2.0/db_1:N    to   orcl=.../oracle/product/10.2.0/db_1:Y
//#>iptables -I INPUT -i eth0 -P tcp --dport 1521 -j ACCEPT
# su - ORACLE
$> cd $ORACLE_HOME/bin
$> vi dbstart
find  ORACLE_HOME_LISTNER=/ade/vikrkuma_new/oracle
 change it to  ORACLE_HOME_LISTNER=$ORACLE_HOME

1. #>cp oraclesvc /etc/init.d/oraclesvc
   #>chmod 775 oraclesvc

2. #>chkconfig --add oraclesvc

3. #>chkconfig --level 345 oraclesvc on

/*
#>vi /etc/rc.local
//add in the end of text:
su - oracle -c "/ora/product/10.2.0/db_1/bin/lsnrctl start"
su - oracle -c "/ora/product/10.2.0/db_1/bin/dbstart"
su - oracle -c "/ora/product/10.2.0/db_1/bin/emctl start dbconsole"
*/
  
4. $>emctl start dbconsole
   $>lsnrctl start
   $>sqlplus /nolog
   sql>connect / as sysdba;
   sql>startup
   $>emctl stop  dbconsole
   
5. use sql*plus tools to create user of oracle10g
   sql>create user ecrm
      >profile default
      >identified by ecrm
      >default tablespace users
      >temporary tablespace temp
      >account unlock;

6. grant
   sql>grant Connect to ecrm;
   sql>grant Resource to ecrm;
   sql>grant dba to ecrm;
   
7. auto backup,edit the crontab config,backup in 2:00 every day
   (need to edit bashup.sh file,because oracle install path and the username will be changed every install)

   $>cp backup.sh /home/oracle/backup/bashup.sh
   #>chmod 775 bashup.sh
   
   #>vi /etc/crontab
   00 2 * * * root /home/oracle/backup/backup.sh

   #>service crond stop
   #>service crond start 
   
config ip steps:
1.#>vi /etc/rc.local
//add in the end of text:
ifconfig eth0 192.168.*.* netmask 255.255.*.*
route add default gw 192.168.*.*

2.#>vi /etc/resolv.conf    //config dns not must
  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值