Oracle Enterprise Manager Cloud Control 12c R4 安裝配置

來源:互聯網
上載者:User

Oracle Enterprise Manager Cloud Control 12c R4 安裝配置
準備軟體

em12.1.0.4_linux64_V45344-01.zip

em12.1.0.4_linux64_V45345-01.zip

em12.1.0.4_linux64_V45346-01.zip

 

安裝作業系統(OEL6.5)

給 OS 空間 50G 以上裝完OS和CC後需要佔用 30G 空間建議6G 記憶體最少4G

 

 

[Oracle@ newcc bin]$ cat /etc/hosts

127.0.0.1  localhostlocalhost.localdomain localhost4 localhost4.localdomain4

::1localhostlocalhost.localdomainlocalhost6 localhost6.localdomain6

 

10.1.32.229 OEL65

 

安裝ccdb資料庫

按照gcdb 11g的環境即可

[oracle@ newcc ~]$ uname -r

3.8.13-16.2.1.el6uek.x86_64

 

[root@OEL65 ~]# rpm -q --qf'%{NAME}-%{VERSION}-%{RELEASE} (%{ARCH})\n' \binutils compat-libstdc++-33elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc-commonglibc-devel glibc-headers ksh libaio libaio-devel libgomp- libgcc libstdc++libstdc++-devel make numactl-devel- sysstat unixODBC unixODBC-devel compat-libcap1

binutils-2.20.51.0.2-5.36.el6 (x86_64)

compat-libstdc++-33-3.2.3-69.el6 (x86_64)

compat-libstdc++-33-3.2.3-69.el6 (i686)

elfutils-libelf-0.152-1.el6 (x86_64)

elfutils-libelf-0.152-1.el6 (i686)

elfutils-libelf-devel-0.152-1.el6 (x86_64)

elfutils-libelf-devel-0.152-1.el6 (i686)

gcc-4.4.7-4.el6 (x86_64)

gcc-c++-4.4.7-4.el6 (x86_64)

glibc-2.12-1.132.el6 (x86_64)

glibc-2.12-1.132.el6 (i686)

glibc-common-2.12-1.132.el6 (x86_64)

glibc-devel-2.12-1.132.el6 (x86_64)

glibc-devel-2.12-1.132.el6 (i686)

glibc-headers-2.12-1.132.el6 (x86_64)

ksh-20120801-10.el6 (x86_64)

libaio-0.3.107-10.el6 (x86_64)

libaio-0.3.107-10.el6 (i686)

libaio-devel-0.3.107-10.el6 (x86_64)

libaio-devel-0.3.107-10.el6 (i686)

libgomp-4.4.7-4.el6 (x86_64)

libgcc-4.4.7-4.el6 (x86_64)

libgcc-4.4.7-4.el6 (i686)

libstdc++-4.4.7-4.el6 (x86_64)

libstdc++-4.4.7-4.el6 (i686)

libstdc++-devel-4.4.7-4.el6 (x86_64)

libstdc++-devel-4.4.7-4.el6 (i686)

make-3.81-20.el6 (x86_64)

numactl-devel-2.0.7-8.el6 (x86_64)

sysstat-9.0.4-22.el6 (x86_64)

unixODBC-2.2.14-12.el6_3 (x86_64)

unixODBC-2.2.14-12.el6_3 (i686)

unixODBC-devel-2.2.14-12.el6_3 (i686)

unixODBC-devel-2.2.14-12.el6_3 (x86_64)

compat-libcap1-1.10-1 (x86_64)

[root@OEL65 ~]#

 

#預設值

/etc/sysctl.conf

[root@newcc soft]#sysctl -p

kernel.msgmnb = 65536

kernel.msgmax = 65536

fs.file-max = 6815744

kernel.sem = 250 32000 100 128

kernel.shmmni = 4096

kernel.shmall = 1073741824

kernel.shmmax = 4398046511104

net.core.rmem_default = 262144

net.core.rmem_max = 4194304

net.core.wmem_default = 262144

net.core.wmem_max = 1048576

fs.aio-max-nr = 1048576

net.ipv4.ip_local_port_range = 9000 65500

 

#預設值

vi /etc/security/limits.conf

 

oracle          soft    nproc  2047

oracle          hard    nproc  16384

oracle          soft    nofile 1024

oracle          hard    nofile 65536

 

 

vi /etc/pam.d/login

session    required    pam_limits.so

 

#關閉SELINUX

vi /etc/selinux/config

SELINUX=disabled

 

#關閉防火牆

[root@newcc~]# service iptables stop

iptables:將鏈設定為政策 ACCEPT:filter                    [確定]

iptables:清除防火牆規則:                                [確定]

iptables:正在卸載模組:                                  [確定]

[root@newcc~]# chkconfig iptables off

 

 

#建立組和使用者

groupadd oinstall預設已經有

groupadd dba預設已經有

groupadd oper

groupadd asmadmin

userdel oracle 

cd /home rm -rf oracle

useradd -g oinstall -G dba,oper,asmadmin oracle

passwd oracle

 

#建立目錄

mkdir -p /u01/app/ora11g

mkdir -p /u01/app/ora11g/product

mkdir -p /u01/app/ora11g/oradata

mkdir -p /u01/app/ora11g/product/11.2.0/db_1

chown -R oracle:oinstall /u01

chmod -R 775 /u01

 

#建立環境變數

su – oracle

vi .bash_profile

 

export TMP=/tmp

export TMPDIR=$TMP

export ORACLE_TERM=xterm

export ORACLE_BASE=/u01/app/ora11g

export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1

export ORACLE_GRID=$ORACLE_BASE/product/11.2.0/grid

export ORACLE_SID=ccdb

export PATH=/usr/sbin:$PATH

export PATH=$ORACLE_HOME/bin:$ORACLE_GRID/bin:$PATH

export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib64:/usr/lib64:/usr/local/lib64:/usr/X11R6/lib64

export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib

export NLS_LANG="SIMPLIFIEDCHINESE_CHINA.ZHS16GBK"

exportALERT=$ORACLE_BASE/diag/rdbms/$ORACLE_SID/$ORACLE_SID/trace

stty erase ^H

umask 022

if [ $USER = "oracle" ]; then

 if [$SHELL = "/bin/ksh" ]; then

      ulimit -p 16384

      ulimit -n 65536

   else

      ulimit -u 16384 -n 65536

           fi

          fi

 

#格式化分區

fdisk -l

 

 

 

[root@newcc ~]#

fdisk /dev/sdb

n p 1 w

 

#建立ASM disk

--檢查asm包安裝

[root@newcc ~]# rpm -qa oracleasm*

oracleasm-support-2.1.8-1.el6.x86_64

 

rpm –vih asmlib

 

[root@newcc ~]# /etc/init.d/oracleasmconfigure

Configuring the Oracle ASM library driver.

 

This will configure the on-boot propertiesof the Oracle ASM library

driver. The following questions will determine whether the driver is

loaded on boot and what permissions it willhave.  The current values

will be shown in brackets ('[]').  Hitting <ENTER> without typing an

answer will keep that current value.  Ctrl-C will abort.

 

Default user to own the driver interface[]: oracle

Default group to own the driver interface[]: asmadmin

Start Oracle ASM library driver on boot(y/n) [n]: y

Scan for Oracle ASM disks on boot (y/n)[y]: y

Writing Oracle ASM library driverconfiguration: done

Initializing the Oracle ASMLib driver:                    [  OK  ]

Scanning the system for Oracle ASMLibdisks:              [  OK  ]

[root@newcc ~]# /etc/init.d/oracleasmcreatedisk v1 /dev/sdb1

Marking disk "v1" as an ASMdisk:                          [  OK  ]

[root@newcc ~]# /etc/init.d/oracleasmcreatedisk v2 /dev/sdc1

Marking disk "v2" as an ASMdisk:                          [  OK  ]

[root@newcc ~]# /etc/init.d/oracleasmlistdisks

V1

V2

 

#配置host檔案

[root@newcc~]# vi /etc/hosts

#cc

10.1.5.122      newcc.localdomain      newcc

 

#Public

10.1.32.91      ntrac1.localdomain      ntrac1

10.1.32.93      ntrac2.localdomain      ntrac2

10.1.32.95      ntrac3.localdomain      ntrac3

 

#Virtual

10.1.32.92      ntrac1-vip.localdomain  ntrac1-vip

10.1.32.94      ntrac2-vip.localdomain  ntrac2-vip

10.1.32.96      ntrac3-vip.localdomain  ntrac3-vip

 

#SCAN

10.1.32.99   rac-scan.localdomain  rac-scan

 

#Database和Grid安裝

 

 

 

 

#建立ccdb資料庫

 

 

 

 

 

 

 

配置ccdb

redo log 修改大小100M 然後建立 4組 redo log

 

**  根據提示修改就OK

ALTER SYSTEM SETprocesses=500 SCOPE=SPFILE;

系統已更改。

ALTER SYSTEM SETsession_cached_cursors=500 SCOPE=SPFILE;

系統已更改

ALTER SYSTEM SETsga_target=2G SCOPE=SPFILE; 預設要比這個大就不動

ALTER SYSTEM SETpga_aggregate_target=2G SCOPE=SPFILE;

ALTER SYSTEM SETjob_queue_processes=20SCOPE=SPFILE; 預設1000 要縮小

ALTER SYSTEM SETopen_cursors=300 SCOPE=SPFILE;

 

**

 

 

--Restart the instance.

SHUTDOWNIMMEDIATE

STARTUP

 

 

 

安裝Cloud Control

官方文檔參考:

http://docs.oracle.com/cd/E24628_01/install.121/e22624/install_em_exist_db.htm#BGBHDBCH

 

建立CC安裝目錄

oracleuser

$ mkdir-p /u01/app/oracle/oms12cr4

$mkdir -p /u01/app/oracle/agent12cr4

 

添加環境變數

 

export LANG=zh_CN

export TMP=/tmp

export TMPDIR=$TMP

export ORACLE_TERM=xterm

exportORACLE_BASE=/u01/app/ora11g

exportORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1

exportORACLE_GRID=$ORACLE_BASE/product/11.2.0/grid

export OMS_HOME=/u01/app/oracle/oms12cr4/oms

export AGENT_HOME=/u01/app/oracle/agent12cr4/core/12.1.0.4.0

export ORACLE_SID=ccdb

export PATH=/usr/sbin:$PATH

exportPATH=$ORACLE_HOME/bin:$ORACLE_GRID/bin:$PATH

exportLD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib64:/usr/lib64:/usr/local/lib64:/usr/X11R6/lib64

exportCLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib

export NLS_LANG="SIMPLIFIEDCHINESE_CHINA.ZHS16GBK"

export ALERT=$ORACLE_BASE/diag/rdbms/$ORACLE_SID/$ORACLE_SID/trace

stty erase ^H

umask 022

if [ $USER = "oracle"]; then

 if [ $SHELL = "/bin/ksh" ]; then

      ulimit -p 16384

      ulimit -n 65536

    else

      ulimit -u 16384 -n 65536

            fi

          fi

 

啟動安裝CC

 

--臨時注釋掉下面幾個環境變數

unset ORACLE_HOME ORACLE_BASE ORACLE_SID

 

[oracle@newcccc]$ ls

install  jdk libskgxn  oms  plugins Release_Notes.pdf  response  runInstaller stage  wls  WT.zip

[oracle@newcccc]$ ./runInstaller

 

 

 

 

 

因為主機名稱沒有加domain

 

 

 

如果選著進階是這樣

 

 

 

 

 

 

 

可以選擇小中大型部署

 

 

 

刪除em之前的dbconsole是stop的

[root@OEL65 112db]# su - oracle

[oracle@OEL65 ~]$ export LANG=zh_EN

[oracle@OEL65 ~]$ emca -deconfig dbcontrol db-repos drop

 

EMCA 開始於 2013-12-9 21:06:52

EM Configuration Assistant, 11.2.0.3.0 正式版

著作權 (c) 2003, 2011, Oracle。著作權所有,並保留一切權利。

 

輸入以下資訊:

資料庫 SID: ngcdb

監聽程式連接埠號碼: 1521

SYS 使用者的口令: 

SYSMAN 使用者的口令: 

 

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

警告: 當刪除資料檔案庫時, 資料庫將進入靜默模式。

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

是否繼續? [是(Y)/否(N)]: y

2013-12-9 21:07:54oracle.sysman.emcp.EMConfig perform

資訊: 正在將此操作記錄到/u01/app/ora11g/cfgtoollogs/emca/ngcdb/emca_2013_12_09_21_06_51.log。

2013-12-9 21:07:55oracle.sysman.emcp.util.DBControlUtilstopOMS

資訊: 正在停止 Database Control (此操作可能需要一段時間)...

2013-12-9 21:07:57oracle.sysman.emcp.EMReposConfig invoke

資訊: 正在刪除 EM 資料檔案庫 (此操作可能需要一段時間)...

2013-12-9 21:09:22oracle.sysman.emcp.EMReposConfig invoke

資訊: 已成功刪除資料檔案庫

已成功完成 Enterprise Manager 的配置

EMCA 結束於 2013-12-9 21:09:25

[oracle@OEL65 ~]$

更多詳情見請繼續閱讀下一頁的精彩內容:

  • 1
  • 2
  • 下一頁

相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.