suse下oracle静默安装软件,suse静默安装oracle 11g

操作系统及Oracle版本

Linux版本SUSE Linux Enterprise Server 11 (x86_64)

Oracle版本Oracle Database 11g Release 2 11.2.0.3.0

1检查安装依赖系统包

localhost:~ # rpm -q binutils compat-libstdc++ elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc-common glibc-devel glibc-headers ksh libaio libaio-devel libgcc libstdc++ libstdc++-devel make numactl-devel sysstat unixODBC unixODBC-devel| grep not

2.创建所需的操作系统组和用户

localhost:~# groupadd -g 1000 oinstall

localhost:~# groupadd -g 1200 dba

localhost:~# useradd -u 1100 -g oinstall -G dba oracle

localhost:~# passwd oracle

3.创建安装目录

localhost:~ # mkdir -p /u01/app/oracle/oradata/stream

localhost:~ # chown -R oracle:oinstall /u01

localhost:~ # chmod -R 775 /u01

4.修改内核参数

localhost:~ # vi /etc/sysctl.conf

kernel.shmmax = 4294967295

kernel.shmmni = 4096

kernel.shmall = 2097152

kernel.sem = 250 32000 100 128

fs.file-max = 6815744

fs.aio-max-nr = 1048576

net.ipv4.ip_local_port_range = 9000 65500

net.core.rmem_default = 4194304

net.core.rmem_max = 4194304

net.core.wmem_default = 262144

net.core.wmem_max = 1048576

localhost:~ # sysctl -p

5.修改用户限制

localhost:~ # vi /etc/security/limits.conf

oracle soft nproc 2047

oracle hard nproc 16384

oracle soft nofile 1024

oracle hard nofile 65536

6.上传oracle安装包

7.静默安装Oracle软件

localhost:# cd /usr/local/src/database/response

localhost:# vi db_install.rsp

oracle.install.option=INSTALL_DB_SWONLY

UNIX_GROUP_NAME=oinstall

INVENTORY_LOCATION=/u01/app/oracle/oraInventory

ORACLE_HOME=/u01/app/oracle/product/11.2.0/dbhome_1

ORACLE_BASE=/u01/app/oracle

oracle.install.db.InstallEdition=EE

oracle.install.db.isCustomInstall=false

oracle.install.db.DBA_GROUP=dba

oracle.install.db.OPER_GROUP=dba

DECLINE_SECURITY_UPDATES=true

localhost:/usr/local/src/database # su - oracle

oracle@localhost:~> cd /usr/local/src/database

oracle@localhost:/usr/local/src/database> ./runInstaller -silent -responseFile /usr/local/src/database/response/db_install.rsp

8.修改环境变量

oracle@localhost:~> cat .bash_profile

export ORACLE_BASE=/u01/app/oracle

export ORACLE_HOME=/u01/app/oracle/product/11.2.0/dbhome_1

export ORACLE_SID=ffcsip

export PATH=/u01/app/oracle/product/11.2.0/dbhome_1/bin/:$PATH

9.验证oracle安装成功

oracle@localhost:~> sqlplus / as sysdba

SQL*Plus: Release 11.2.0.3.0 Production on Thu Sep 6 11:29:25 2018

Copyright (c) 1982, 2011, Oracle. All rights reserved.

Connected to an idle instance.

SQL> exit

Disconnected

10.静默安装实例

localhost:# vi /usr/local/src/database/response/dbca.rsp

GDBNAME = "ffcsip"

SID = "ffcsip"

SYSPASSWORD = "ffcsip"

SYSTEMPASSWORD = "ffcsip"

SYSMANPASSWORD = "ffcsip"

DBSNMPPASSWORD = "ffcsip"

STORAGETYPE=FS

NATIONALCHARACTERSET= "UTF8"

LISTENERS = "LISTENER"

DATABASETYPE = "OLTP"

AUTOMATICMEMORYMANAGEMENT = "TRUE"

TOTALMEMORY = "800"

localhost:~ # su - oracle

oracle@localhost:~> cd /u01/app/oracle/product/11.2.0/dbhome_1/bin/

oracle@localhost:/u01/app/oracle/product/11.2.0/dbhome_1/bin> dbca -silent -responseFile /usr/local/src/database/response/dbca.rsp

11.配置监听

oracle@localhost:~> cd $ORACLE_HOME/network/admin/samples/

oracle@localhost:/u01/app/oracle/product/11.2.0/dbhome_1/network/admin/samples> vi listener.ora

# listener.ora Network Configuration File: /u01/app/oracle/network/admin/listener.ora

# Generated by Oracle configuration tools.

SID_LIST_LISTENER =

(SID_LIST =

(SID_DESC =

(GLOBAL_DBNAME = ffcsip)

(ORACLE_HOME = /u01/app/oracle/product/11.2.0/dbhome_1)

(SID_NAME = FFCSIP)

)

)

LISTENER =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.11.155)(PORT = 1521))

)

ADR_BASE_LISTENER = /u01/app

oracle@localhost:/u01/app/oracle/product/11.2.0/dbhome_1/network/admin/samples> cd ..

oracle@localhost:/u01/app/oracle/product/11.2.0/dbhome_1/network/admin> vi tnsnames.ora

# tnsnames.ora Network Configuration File: /opt/oracle/product/11g//network/admin/tnsnames.ora

# Generated by Oracle configuration tools.

EXTPROC_CONNECTION_DATA =

(DESCRIPTION =

(ADDRESS_LIST =

(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))

)

(CONNECT_DATA =

(SID = PLSExtProc)

(PRESENTATION = RO)

)

)

ffcsip =

(DESCRIPTION =

(ADDRESS_LIST =

(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))

)

(CONNECT_DATA =

(SID = ffcsip)

(SERVER = DEDICATED)

)

)

12.启动监听

oracle@localhost:/u01/app/oracle/product/11.2.0/dbhome_1/network/admin> lsnrctl start

LSNRCTL for Linux: Version 11.2.0.3.0 - Production on 06-SEP-2018 14:01:43

Copyright (c) 1991, 2011, Oracle. All rights reserved.

Starting /u01/app/oracle/product/11.2.0/dbhome_1/bin/tnslsnr: please wait...

TNSLSNR for Linux: Version 11.2.0.3.0 - Production

Log messages written to /u01/app/oracle/diag/tnslsnr/localhost/listener/alert/log.xml

Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521)))

Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))

STATUS of the LISTENER

------------------------

Alias LISTENER

Version TNSLSNR for Linux: Version 11.2.0.3.0 - Production

Start Date 06-SEP-2018 14:01:43

Uptime 0 days 0 hr. 0 min. 0 sec

Trace Level off

Security ON: Local OS Authentication

SNMP OFF

Listener Log File /u01/app/oracle/diag/tnslsnr/localhost/listener/alert/log.xml

Listening Endpoints Summary...

(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1521)))

The listener supports no services

The command completed successfully

13.验证实例安装成功

oracle@localhost:~> sqlplus / as sysdba

SQL*Plus: Release 11.2.0.3.0 Production on Thu Sep 6 13:07:35 2018

Copyright (c) 1982, 2011, Oracle. All rights reserved.

Connected to:

Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production

With the Partitioning, OLAP, Data Mining and Real Application Testing options

SQL> shutdown

Database closed.

Database dismounted.

ORACLE instance shut down.

SQL> startup

ORACLE instance started.

Total System Global Area 668082176 bytes

Fixed Size 2231352 bytes

Variable Size 192938952 bytes

Database Buffers 461373440 bytes

Redo Buffers 11538432 bytes

Database mounted.

Database opened.

SQL> select name,dbid from v$database;

NAME DBID

--------- ----------

FFCSIP 2248129739

SQL> select instance_name from v$instance;

INSTANCE_NAME

----------------

ffcsip

14.测试

oracle@localhost:/u01/app/oracle/product/11.2.0/dbhome_1/network/admin> tnsping ffcsip

TNS Ping Utility for Linux: Version 11.2.0.3.0 - Production on 06-SEP-2018 14:01:49

Copyright (c) 1997, 2011, Oracle. All rights reserved.

Used parameter files:

Used TNSNAMES adapter to resolve the alias

Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))) (CONNECT_DATA = (SID = ffcsip) (SERVER = DEDICATED)))

OK (0 msec)

oracle@localhost:~> sqlplus / as sysdba

SQL*Plus: Release 11.2.0.3.0 Production on Thu Sep 6 13:07:35 2018

Copyright (c) 1982, 2011, Oracle. All rights reserved.

Connected to:

Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production

With the Partitioning, OLAP, Data Mining and Real Application Testing options

SQL> create user test identified by test;

User created.

SQL> grant create session to test;

Grant succeeded.

oracle@localhost:~> sqlplus test/test@ffcsip

SQL*Plus: Release 11.2.0.3.0 Production on Thu Sep 6 14:03:08 2018

Copyright (c) 1982, 2011, Oracle. All rights reserved.

Connected to:

Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production

With the Partitioning, OLAP, Data Mining and Real Application Testing options

SQL>

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值