rac oracle10 asm+raw for centos5.6 on vm server
RAC實驗報告(vm server asm+raw+oracle10g)
首先感謝:以下筆者,沒有你們就沒有我這個實驗的結果。
http://blog.csdn.net/tianlesoftware/article/details/5872593(tianlesofeware)
http://hi.baidu.com/woshi110/blog/category/vmware%2Blinux%2Boracle10g%20rac%C8%AB%B9%FD%B3%CC (我是110)
伺服器主機名 |
rac1-21 |
rac2-22 |
|
Public(eth0) |
192.168.0.21 |
192.168.0.22 |
|
Vip (eth0) |
192.168.0.23 |
192.168.0.24 |
|
Priv (eth1) |
192.168.1.25 |
192.168.1.26 |
|
Oracle_sid |
Rac1-21 |
Rac-22 |
|
叢集 |
racdb |
|
|
OCR |
/dev/raw/raw1 |
200M |
|
/dev/raw/raw2 |
200M |
|
|
Voting disk |
/dev/raw/raw3 |
200M |
|
/dev/raw/raw4 |
200M |
|
|
/dev/raw/raw5 |
200M |
|
|
RAC_DISK |
/dev/raw/raw6 |
4G |
|
/dev/raw/raw7 |
4G |
|
|
BACKUP_DISK |
/dev/raw/raw8 |
2G |
|
/dev/raw/raw9 |
2G |
|
|
|
|
|
|
一、IP地址規劃及/etc/hosts 配置
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 rac1-21 localhost.localdomain localhost
::1 localhost6.localdomain6 localhost6
192.168.0.21 rac1-21
192.168.0.22 rac2-22
192.168.0.23 rac1-vip
192.168.0.24 rac2-vip
192.168.1.25 rac1-priv
192.168.1.26 rac2-priv
l 關於IP地址一些問題
http://space.itpub.net/?uid-26442936-action-viewspace-itemid-730968
二、建立使用者,組,使用者變數,目錄
1、使用者,組,修改密碼
[root@rac1-21 ~]groupadd -g 1000 oinstall
[root@rac1-21 ~]groupadd -g 1001 dba
[root@rac1-21 ~]useradd -u 1000 ora -g oinstall -G dba
Changing password for user ora.
New UNIX password:
BAD PASSWORD: it is based on a dictionary word
Retype new UNIX password:
passwd: all authentication tokens updated successfully.
2、使用者變數
[root@rac1-21 ~]vi .bash_profile
export TMP=/tmp
export TMPDIR=$TMP
export ORACLE_BASE=/u01/oracle
export ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1
export ORACLE_CRS_HOME=$ORACLE_BASE/product/10.2.0/db_1
export ORACLE_SID=racdb1
export ORACLE_TERM=xterm
export PATH=/usr/sbin:$PATH
#export PATH=$ORACLE_HOME/bin:$PATH:$ORACLE_CRS_HOME/bin
export PATH=.:${PATH}:$HOME/bin:$ORA_CRS_HOME/bin:$ORACLE_HOME/bin
export LD_LIBRARY_PATH=$ORACLE_HOME/bin:/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin/
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
umask 022
3、目錄,許可權
[root@rac1-21 ~]# mkdir -p /u01/oracle
[root@rac1-21 ~]# chown ora:oinstall /u01/oracle
[root@rac1-21 /]# ls –l
drwxr-xr-x 5 ora oinstall 4096 05-17 16:19 u01
三、設定限制引數,計時器
1、配置核心引數
[root@rac1-21 /]# vi /etc/sysctl.conf 在檔案底部新增下面引數
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 = 1048576
net.core.rmem_max = 1048576
net.core.wmem_default = 262144
net.core.wmem_max = 262144
讓設定生效
2、提高Oracle使用者的shell限制
設定oracle 使用的檔案數許可權
[root@rac1-21 /]# vi /etc/security/limits.conf 檔案底部新增下面引數
ora soft nproc 2047
ora hard nproc 16384
ora soft nofile 1024
ora hard nofile 65536
3、配置Hangcheck 計時器
[root@rac1-21 /]# vi /etc/rc.local
增加:
modprobe hangcheck-timer hangcheck-tick=30 hangcheck_margin=180
這個增加後,記住一定要重新或者執行生效啊!
要立即載入模組,執行
[root@rac1-21 ~]# modprobe -v hangcheck-timer
檢視是否執行成功,下面為成功
[root@rac1-21 ~]# lsmod | grep hangcheck_timer
hangcheck_timer 8153 0
四、準備補丁和ASM包
系統包下載地址:
http://oss.oracle.com/projects/compat-oracle/files/Enterprise_Linux/
ASM包下載地址:
[root@rac1-21 u01]# uname -a
Linux rac1-21 2.6.18-238.el5 #1 SMP Thu Jan 13 16:24:47 EST 2011 i686 i686 i386 GNU/Linux
http://www.oracle.com/technetwork/server-storage/linux/downloads/rhel5-084877.html
(這裡有不同的型別CPU,找到對應你自己系統的 1,CPU 2,是核心版本)
oracleasm-2.6.18-238.el5-2.0.5-1.el5.i686.rpm
oracleasm-2.6.18-238.el5PAE-2.0.5-1.el5.i686.rpm
oracleasm-2.6.18-238.el5debug-2.0.5-1.el5.i686.rpm
oracleasm-2.6.18-238.el5xen-2.0.5-1.el5.i686.rpm
oracleasm-support-2.1.7-1.el5.i386.rpm
compat-binutils215-2.15.92.0.2-24.i386.rpm
compat-libcwait-2.1-1.i386.rpm
compat-libstdc++-egcs-1.1.2-1.i386.rpm
openmotif21-debuginfo-2.1.30-11.EL5.i386.rpm
xorg-x11-libs-compat-6.8.2-1.EL.33.0.1.i386.rpm
所有節點都應該安裝所需的包,我們是整體複製,所有一個節點安裝好,複製到另一個節點就OK 了。
安裝步驟下面:
http://space.itpub.net/?uid-26442936-action-viewspace-itemid-730970
五、用VM server 劃分共享磁碟。
具體VM server建立磁碟,分割槽。
注意磁碟驅動器要選擇SCSI,還有建立虛擬機器的時候選擇I/0 adapter types 選擇 LSI Logic
下面只是寫出了一部分。
[root@rac1-21 u01]# fdisk -l
Disk /dev/hda: 10.7 GB, 10737418240 bytes
255 heads, 63 sectors/track, 1305 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 13 104391 83 Linux
/dev/hda2 14 905 7164990 83 Linux
/dev/hda3 906 1287 3068415 82 Linux swap / Solaris
Disk /dev/sdb: 214 MB, 214748160 bytes 磁碟大小200M
64 heads, 32 sectors/track, 204 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes
Disk /dev/sdb doesn't contain a valid partition table
六、用節點1克隆出節點2
1、 把節點SHUTDOWN,然後建立一個目錄。
2、 把節點1目錄下的所有檔案,複製到另一個目錄下。注意共享磁碟檔案不用複製。
3、 編輯Red Hat Linux.vmx 這個檔案。修改displayName = "rac1-21" 成displayName = "rac2-22"即可,然後到另一個目錄下,雙擊
七、克隆出來2個節點,修改節點2。
具體步驟如下。
1、修改 /etc/sysconfig/network 。 hostname=rac2-22
2、修改IP地址。注意HWaddr 必須一致
3、修改使用者變數。ORACLE_SID=racdb2
修改成功後,重啟一下系統。這個是必須的。
八、使用者對等性。
[ora@rac1-21 ~]$ mkdir ~/.ssh
[ora@rac1-21 ~]$ chmod 700 ~/.ssh
[ora@rac1-21 ~]$ ssh-keygen -t rsa
[ora@rac1-21 ~]$ ssh-keygen -t dsa
[ora@rac2-22 ~]$ mkdir ~/.ssh
[ora@rac2-22 ~]$ chmod 700 ~/.ssh
[ora@rac2-22 ~]$ ssh-keygen -t rsa
[ora@rac2-22 ~]$ ssh-keygen -t dsa
以下節點1執行即可
[ora@rac1-21 ~]$ cat ~/.ssh/id_rsa.pub >>~/.ssh/authorized_keys
[ora@rac1-21 ~]$ cat ~/.ssh/id_dsa.pub >>~/.ssh/authorized_keys
[ora@rac1-21 ~]$ ssh rac2-22 cat ~/.ssh/id_rsa.pub >>~/.ssh/authorized_keys
[ora@rac1-21 ~]$ ssh rac2-22 cat ~/.ssh/id_dsa.pub >>~/.ssh/authorized_keys
[ora@rac1-21 ~]$ ssh rac2-22 cat ~/.ssh/id_dsa.pub >>~/.ssh/authorized_keys
檢驗對等性
[ora@rac1-21 ~]$ ssh rac1-21 date
[ora@rac1-21 ~]$ ssh rac1-priv date
[ora@rac1-21 ~]$ ssh rac2-22 date
[ora@rac1-21 ~]$ ssh rac2-priv date
能看到時間,不用輸入密碼,這樣就可以了。看到時間這裡就引出一個問題,時間不同步。
九、時間同步
vi /etc/ntp.conf
restrict 192.168.0.0 mask 255.255.255.0 nomodify notrap
server 127.127.1.0 minpoll 4 # local clock
fudge 127.127.1.0 stratum 1
cd /etc/ntp
清空ntpservers
vi step-tickers
####新增以下資訊
127.127.1.0
[root@rac1-21 ntp]# service ntpd restart
關閉 ntpd:[失敗]
ntpd: 同步時間伺服器:[失敗]
啟動 ntpd:[確定]
[root@rac1-21 ntp]# chkconfig ntpd on
[root@rac1-21 ntp]# chkconfig ntpd --list
ntpd 0:關閉 1:關閉 2:啟用 3:啟用 4:啟用 5:啟用 6:關閉
節點2操作
[root@rac2-22 ~]# /usr/sbin/ntpdate rac1-priv
15 Feb 00:01:06 ntpdate[29130]: no server suitable for synchronization found
剛同步 ,會報這樣的錯誤。這需要有足夠的時間來同步,我們也可以手動調節時間
[root@rac2-22 ~]# ntpdate rac1-priv
21 May 14:14:48 ntpdate[29263]: adjust time server 192.168.1.25 offset -0.055266 sec
同步成功了
[ora@rac2-22 ~]$ ssh rac1-21 date
2012年 05月 21日 星期一 14:17:22 CST
[ora@rac2-22 ~]$ ssh rac2-22 date
2012年 05月 21日 星期一 14:17:27 CST
十、配置裸裝置
vi /etc/udev/rules.d/60-raw.rules
ACTION=="add", KERNEL=="/dev/sda1", RUN+="/bin/raw /dev/raw/raw1 %N"
ACTION=="add", ENV{MAJOR}=="8", ENV{MINOR}=="17", RUN+="/bin/raw /dev/raw/raw1 %M %m"
ACTION=="add", KERNEL=="/dev/sdb1", RUN+="/bin/raw /dev/raw/raw2 %N"
ACTION=="add", ENV{MAJOR}=="8", ENV{MINOR}=="33", RUN+="/bin/raw /dev/raw/raw2 %M %m"
ACTION=="add", KERNEL=="/dev/sdc1", RUN+="/bin/raw /dev/raw/raw3 %N"
ACTION=="add", ENV{MAJOR}=="8", ENV{MINOR}=="49", RUN+="/bin/raw /dev/raw/raw3 %M %m"
ACTION=="add", KERNEL=="/dev/sdd1", RUN+="/bin/raw /dev/raw/raw4 %N"
ACTION=="add", ENV{MAJOR}=="8", ENV{MINOR}=="65", RUN+="/bin/raw /dev/raw/raw4 %M %m"
ACTION=="add", KERNEL=="/dev/sde1", RUN+="/bin/raw /dev/raw/raw5 %N"
ACTION=="add", ENV{MAJOR}=="8", ENV{MINOR}=="81", RUN+="/bin/raw /dev/raw/raw5 %M %m"
ACTION=="add", KERNEL=="/dev/sdf1", RUN+="/bin/raw /dev/raw/raw6 %N"
ACTION=="add", ENV{MAJOR}=="8", ENV{MINOR}=="97", RUN+="/bin/raw /dev/raw/raw6 %M %m"
ACTION=="add", KERNEL=="/dev/sdg1", RUN+="/bin/raw /dev/raw/raw7 %N"
ACTION=="add", ENV{MAJOR}=="8", ENV{MINOR}=="113", RUN+="/bin/raw /dev/raw/raw7 %M %m"
ACTION=="add", KERNEL=="/dev/sdh1", RUN+="/bin/raw /dev/raw/raw8 %N"
ACTION=="add", ENV{MAJOR}=="8", ENV{MINOR}=="129", RUN+="/bin/raw /dev/raw/raw8 %M %m"
ACTION=="add", KERNEL=="/dev/sdi1", RUN+="/bin/raw /dev/raw/raw9 %N"
ACTION=="add", ENV{MAJOR}=="8", ENV{MINOR}=="145", RUN+="/bin/raw /dev/raw/raw9 %M %m"
KERNEL=="raw[1-9]",OWNER=="ora",GROUP="oinstall",MODE="1440"
[root@rac1-21 etc]# start_udev
啟動 udev:[確定]
[root@rac1-21 dev]# ls -l /dev/raw
總計 0
c-------w- 1 ora oinstall 162, 1 05-21 14:44 raw1
c-------w- 1 ora oinstall 162, 2 05-21 14:44 raw2
c-------w- 1 ora oinstall 162, 3 05-21 14:44 raw3
c-------w- 1 ora oinstall 162, 4 05-21 14:44 raw4
c-------w- 1 ora oinstall 162, 5 05-21 14:44 raw5
c-------w- 1 ora oinstall 162, 6 05-21 14:44 raw6
c-------w- 1 ora oinstall 162, 7 05-21 14:44 raw7
c-------w- 1 ora oinstall 162, 8 05-21 14:44 raw8
udev只能顯示8個裸裝置
RAW命令
[root@rac1-21 dev]# raw /dev/raw/raw9 /dev/sdi1
/dev/raw/raw9: bound to major 8, minor 129
[root@rac1-21 dev]# ls -l /dev/raw
總計 0
c-------w- 1 ora oinstall 162, 1 05-21 14:44 raw1
c-------w- 1 ora oinstall 162, 2 05-21 14:44 raw2
c-------w- 1 ora oinstall 162, 3 05-21 14:44 raw3
c-------w- 1 ora oinstall 162, 4 05-21 14:44 raw4
c-------w- 1 ora oinstall 162, 5 05-21 14:44 raw5
c-------w- 1 ora oinstall 162, 6 05-21 14:44 raw6
c-------w- 1 ora oinstall 162, 7 05-21 14:44 raw7
c-------w- 1 ora oinstall 162, 8 05-21 14:44 raw8
c-------w- 1 ora oinstall 162, 9 05-21 15:11 raw9
然後 vi /etc /rc.local
modprobe hangcheck-timer hangcheck-tick=30 hangcheck_margin=180
raw /dev/raw/raw9 /dev/sdi1
#/etc/init.d/oracleasm createdisk VOL1 /dev/sda1
#/etc/init.d/oracleasm createdisk VOL2 /dev/sdb1
#/etc/init.d/oracleasm createdisk VOL3 /dev/sdc1
#/etc/init.d/oracleasm createdisk VOL4 /dev/sdd1
#/etc/init.d/oracleasm createdisk VOL5 /dev/sde1
#/etc/init.d/oracleasm createdisk VOL6 /dev/sdf1
#/etc/init.d/oracleasm createdisk VOL7 /dev/sdg1
#/etc/init.d/oracleasm createdisk VOL8 /dev/sdh1
#/etc/init.d/oracleasm createdisk VOL9 /dev/sdi1
這裡不應該createdisk,否則 raw上的東西都沒了。本人失敗的經驗!
chown ora:oinstall /dev/raw/*
chown root:onistall /dev/raw/raw1
chown root:onistall /dev/raw/raw2
chmod 644 /dev/raw/raw3
chmod 644 /dev/raw/raw4
chmod 644 /dev/raw/raw5
這段許可權配置也是很重要的,如果許可權不對,你重啟伺服器之後就啟動不了CRS
[root@rac1-21 /]# /etc/init.d/oracleasm configure
Configuring the Oracle ASM library driver.
This will configure the on-boot properties of the Oracle ASM library
driver. The following questions will determine whether the driver is
loaded on boot and what permissions it will have. The current values
will be shown in brackets ('[]'). Hitting
answer will keep that current value. Ctrl-C will abort.
Default user to own the driver interface []: ora
Default group to own the driver interface []: dba
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 driver configuration: done
Initializing the Oracle ASMLib driver: [ OK ]
Scanning the system for Oracle ASMLib disks: [ OK ]
節點2
[root@rac2-22 ~]# /etc/init.d/oracleasm configure
Configuring the Oracle ASM library driver.
This will configure the on-boot properties of the Oracle ASM library
driver. The following questions will determine whether the driver is
loaded on boot and what permissions it will have. The current values
will be shown in brackets ('[]'). Hitting
answer will keep that current value. Ctrl-C will abort.
Default user to own the driver interface []: ora
Default group to own the driver interface []: dba
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 driver configuration: done
Initializing the Oracle ASMLib driver: [ OK ]
Scanning the system for Oracle ASMLib disks: [ OK ]
[root@rac1-21 /]# /etc/init.d/oracleasm createdisk VOL6 /dev/sdf1
Marking disk "VOL6" as an ASM disk: [ OK ]
[root@rac1-21 /]# /etc/init.d/oracleasm createdisk VOL7 /dev/sdg1
Marking disk "VOL7" as an ASM disk: [ OK ]
[root@rac1-21 /]# /etc/init.d/oracleasm createdisk VOL8 /dev/sdh1
Marking disk "VOL8" as an ASM disk: [ OK ]
[root@rac1-21 /]# /etc/init.d/oracleasm createdisk VOL9 /dev/sdi1
Marking disk "VOL9" as an ASM disk: [ OK ]
[root@rac1-21 /]# /etc/init.d/oracleasm scandisks
Scanning the system for Oracle ASMLib disks: [ OK ]
[root@rac1-21 /]# /etc/init.d/oracleasm listdisks
VOL6
VOL7
VOL8
VOL9
[root@rac2-22 ~]# /etc/init.d/oracleasm scandisks
Scanning the system for Oracle ASMLib disks: [ OK ]
[root@rac2-22 ~]# /etc/init.d/oracleasm listdisks
VOL6
VOL7
VOL8
VOL9
所有節點都可以看到 VOL 就表示我們的共享磁碟可以了。
十一、RAC的準備工作已經做完了。現在可以進入重頭戲了。安裝CRS!
1、解壓CRS包,檢測
[ora@rac1-21 u01]$ unzip 10201_clusterware_linux32.zip 解壓
[root@rac1-21 u01]# chown -R ora.oinstall clusterware
[root@rac1-21 u01]# chmod -R 777 clusterware
檢測
[ora@rac1-21 u01]$ /u01/clusterware/cluvfy/runcluvfy.sh stage -pre crsinst -n rac1-21,rac2-22 -verbose
2、用 Xmanger 安裝CRS軟體
[ora@rac1-21 u01]$ export DISPLAY=192.168.0.1:0.0
[ora@rac1-21 u01]$ /u01/clusterware/runInstaller –ignoreSysPreReqs
export LANG=C 英文介面(亂碼用英文的解決)
具體步驟省略了。說下需要注意的。
2-1、這裡預設是安裝DB的 PATH/u01/oracle/product/10.2.0/db_1:,
修改成CRS也就是:/u01/oracle/product/10.2.0/crs_1
2-2、add a new node to the existing cluster 需要和你的 /etc/hosts 相對應
2-3、ocr 2個raw,voting disk 3個raw。 當然你也可以 ocr 1個,voting disk 1個。但是oracle 建議正式資料庫用 ocr 2個raw,voting disk 3個raw!
2-4、節點2在執行這個命令前:/u01/oracle/product/10.2.0/crs_1/root.sh
需要vi /u01/oracle/product/10.2.0/crs_1/bin/vipca
LD_ASSUME_KERNEL=2.4.19
export LD_ASSUME_KERNEL
fi
在fi 後新新增一行:
unset LD_ASSUME_KERNEL
vi /u01/oracle/product/10.2.0/crs_1/bin/srvctl
LD_ASSUME_KERNEL=2.4.19
export LD_ASSUME_KERNEL
同樣在其後新增加一行:
unset LD_ASSUME_KERNEL
然後執行
[root@rac2-22 ~]# /u01/oracle/product/10.2.0/crs_1/root.sh
還會報錯,使用oifcfg命令指定網路介面
[root@rac2-22 bin]# cd /u01/oracle/product/10.2.0/crs_1/bin
[root@rac2-22 bin]# ./oifcfg setif -global eth0/192.168.0.0:public
[root@rac2-22 bin]# ./oifcfg setif -global eth0/192.168.1.0:cluster_interconnect
[root@rac2-22 bin]# ./oifcfg getif
eth0 192.168.0.0 global public (VIP和管理IP段)
eth0 192.168.1.0 global cluster_interconnect (心跳IP段)
這裡的eth0 指定的是一個網段。
這裡不要急於下一步,我們應該先新增VIP ./vipca
新增完VIP 然後在下一步。
VIP新增完成後,去CRS介面點選成功。
到這裡我們的CRS 已經安裝成功了。
[ora@rac2-22 bin]$ ./crs_stat -t
Name Type Target State Host
------------------------------------------------------------
ora....-21.gsd application ONLINE ONLINE rac1-21
ora....-21.ons application ONLINE ONLINE rac1-21
ora....-21.vip application ONLINE ONLINE rac1-21
ora....-22.gsd application ONLINE ONLINE rac2-22
ora....-22.ons application ONLINE ONLINE rac2-22
ora....-22.vip application ONLINE ONLINE rac2-22
十二、安裝資料庫軟體
安裝資料庫軟體。
1、安裝軟體不建立資料庫,安裝完軟體後。
2、先安裝監聽! netca,選擇所有節點。
3、dbca建立資料庫,並用ASM掛載裸裝置。 (掛載這裡如果報一個網路錯誤,不能掛載你只修改一下/etc/hosts 127.0.0.1 localhost 即可)
隨後就是等待他們的安裝了。
[ora@rac1-21 ~]$ crs_stat -t
Name Type Target State Host
------------------------------------------------------------
ora....SM1.asm application ONLINE ONLINE rac1-21
ora....21.lsnr application ONLINE ONLINE rac1-21
ora....-21.gsd application ONLINE ONLINE rac1-21
ora....-21.ons application ONLINE ONLINE rac1-21
ora....-21.vip application ONLINE ONLINE rac1-21
ora....SM2.asm application ONLINE ONLINE rac2-22
ora....22.lsnr application ONLINE ONLINE rac2-22
ora....-22.gsd application ONLINE ONLINE rac2-22
ora....-22.ons application ONLINE ONLINE rac2-22
ora....-22.vip application ONLINE ONLINE rac2-22
ora.racdb.db application ONLINE ONLINE rac1-21
ora....b1.inst application ONLINE ONLINE rac1-21
ora....b2.inst application ONLINE ONLINE rac2-22
到這裡我們RAC整體安裝完畢了!
十三、管理RAC
RAC管理命令srvctl
使用srvctl報錯及解決方法
1、解決目錄問題
[ora@rac1-21 bin]$ srvctl
/u01/oracle/product/10.2.0/db_1/jdk/jre/bin/java: error while loading shared libraries: libpthread.so.0: cannot open shared object file: No such file or directory
[ora@rac1-21 bin]$ which srvctl
/u01/oracle/product/10.2.0/db_1/bin/srvctl
[ora@rac1-21 bin]$ echo $PATH
/u01/oracle/product/10.2.0/db_1/bin:/usr/sbin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/ora/bin:/u01/oracle/product/10.2.0/crs_1/bin
其實srvctl應該是在/u01/oracle/product/10.2.0/crs_1/bin目錄下的。但是因為我們~/.bash_profile 內 PATH的順序問題。所以修改了一下
export PATH=.:${PATH}:$HOME/bin:$ORA_CRS_HOME/bin:$ORACLE_HOME/bin
這裡也提示我們PATH是有順序更好。
2、解決BUG問題
接著使用srvctl 還是報錯。想想我們vipca前,新增了unset 這裡,我們需要編輯srvctl註釋
#Remove this workaround when the bug 3937317 is fixed
#LD_ASSUME_KERNEL=2.4.19
#export LD_ASSUME_KERNEL
[ora@rac2-22 ~]$ srvctl --help
用法: srvctl
命令: enable|disable|start|stop|relocate|status|add|remove|modify|getenv|setenv|unsetenv|config
物件: database|instance|service|nodeapps|asm|listener
有關各個命令和物件的詳細幫助, 請使用:
srvctl
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/26442936/viewspace-731312/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- vm server RAC--補丁Server
- vm server RAC--IP 地址Server
- Oracle rac on vm--共享磁碟Oracle
- Oracle VM Server安裝手冊OracleServer
- oracle10g RAC Default gateway is not defined (host=rac2) (vm)OracleGateway
- Oracle10 RAC 設定MAXLOGHISTORY,大家一般設定為多少?Oracle
- install oracle for centos5.6OracleCentOS
- Oracle VM SERVER+WINDOWS2003 SERVER 問題總結OracleServerWindows
- Oracle VM上實施Oracle 12cR2 RACOracle
- 搭建 VM + RHLE5 + Oracle10g Rac + ASMOracleASM
- oracle 11G RAC的建立(VM虛擬環境)Oracle
- 11.2.0.4 rac + redhat server 6.2RedhatServer
- dell poweredge r410安裝Oracle VM Server 3.2.2OracleServer
- ORACLE VM建立SERVER POOLS後狀態為ERR的解決OracleServer
- Oracle RAC Cache Fusion 系列十四:Oracle RAC CR Server Part OneOracleServer
- window系統Oracle10安裝教程Oracle
- oracle10 dba_tablespace中的retentionOracle
- 在 Azure CentOS VM 中配置 SQL Server 2019 AG - (上)CentOSSQLServer
- Using WebLogic Server With Oracle RAC(轉)WebServerOracle
- 通過ORACLE VM virtualbox環境安裝oracle 11G RAC(ASM)OracleASM
- VM 6+linux4.4+裸裝置+ORACLE10G RAC 安裝LinuxOracle
- 在oracle10中使用低版本expOracle
- 11g R2 RAC: SERVER POOLSServer
- 關於RAC Server時間同步以及DB Server時間修改注意點Server
- Config server pool in oracle 12c racServerOracle
- vmware server 解決rac中共享磁碟問題Server
- 11.2.0.3 RAC 全過程--7.NTP ServerServer
- ORACLE RAC 利與弊 SQL SERVER課題研究OracleSQLServer
- Vm 增加硬碟硬碟
- Centos5.6簡單方法升級php到php5.3.3CentOSPHP
- 開機自動啟動Oracle 10g on centos5.6Oracle 10gCentOS
- [VM trunk ports]opensatck VM 單網路卡,多VLAN配置
- 在ARM模式下捕獲VM並建立新VM模式
- 將 WebLogic Server 和 Oracle RAC 一起使用WebServerOracle
- Oracle RAC Failove 之三:Server-Side TAFOracleAIServerIDE
- vmware server 1.0.6----vmware-diskmanager配置rac共享儲存Server
- node核心模組-vm
- Oracle VM釋出Oracle