接上篇《oracle最佳連接方式之service簡(jiǎn)介及創(chuàng)建》,本章節(jié)涉及數(shù)據(jù)庫(kù)service的維護(hù)操作:
service切換、刪除等標(biāo)準(zhǔn)操作。
su – oracle
srvctl config service {-db [-service ] [-verbose]
示例:
[oracle@server01 admin]$ srvctl config service -db DGORCL -verbose
Service name: ORCL_RD_S1
Server pool:
Cardinality: 1
Service role: PHYSICAL_STANDBY
Management policy: AUTOMATIC
DTP transaction: false
AQ HA notifications: false
Global: false
Commit Outcome: false
Failover type:
Failover method:
Failover retries:
Failover delay:
Failover restore: NONE
Connection Load Balancing Goal: LONG
Runtime Load Balancing Goal: NONE
TAF policy specification: NONE
Edition:
Pluggable database name: ORCL
Hub service:
Maximum lag time: ANY
SQL Translation Profile:
Retention: 86400 seconds
Replay Initiation Time: 300 seconds
Drain timeout:
Stop option:
Session State Consistency: DYNAMIC
GSM Flags: 0
Service is enabled
Preferred instances: orcl1
Available instances: orcl2
CSS critical: no
Service uses Java: false
Service name: ORCL_RD_S2
Server pool:
Cardinality: 1
Service role: PHYSICAL_STANDBY
Management policy: AUTOMATIC
DTP transaction: false
AQ HA notifications: false
Global: false
Commit Outcome: false
Failover type:
Failover method:
Failover retries:
Failover delay:
Failover restore: NONE
Connection Load Balancing Goal: LONG
Runtime Load Balancing Goal: NONE
TAF policy specification: NONE
Edition:
Pluggable database name: ORCL
Hub service:
Maximum lag time: ANY
SQL Translation Profile:
Retention: 86400 seconds
Replay Initiation Time: 300 seconds
Drain timeout:
Stop option:
Session State Consistency: DYNAMIC
GSM Flags: 0
Service is enabled
Preferred instances: orcl2
Available instances: orcl1
CSS critical: no
Service uses Java: false
srvctl status service {-db [-service "
" | -pdb ] [-db
]} [-force] [-verbose]
示例:
srvctl status service -d DGORCL –verbose
Service ORCL_rd_s1 is running on instance(s) orcl2
Service ORCL_rd_s2 is running on instance(s) orcl2
srvctl status service -d DGORCL -pdb ORCL
Service ORCL_rd_s1 is running on instance(s) orcl2
Service ORCL_rd_s2 is running on instance(s) orcl2
srvctl start service { -node
| -db
[-node| -instance ]
[-service "" | -pdb
[-role] [-startoption][-verbose]
--啟動(dòng)service
srvctl start service -db DGORCL -service ORCL_RD_S1
--檢查
srvctl status service -db DGORCL -service ORCL_RD_S1
Service ORCL_RD_S1 is running on instance(s) orcl1
--停止service
srvctl stop service -db DGORCL -service ORCL_RD_S1
--檢查
srvctl status service -db DGORCL -service ORCL_RD_S1
Service ORCL_RD_S1 is not running.
srsctl status res –t
ora.DGORCL.ORCL_rd_s1.svc
1 OFFLINE OFFLINE STABLE
ora.DGORCL.ORCL_rd_s2.svc
ONLINE ONLINE server02 STABLE
srvctl relocate service -db
[-service | -pdb ]
{-oldinst [-newinst ]
[-force [-noreplay]
示例:
ora.DGORCL.ORCL_rd_s1.svc
1 ONLINE ONLINE server01 STABLE
ora.DGORCL.ORCL_rd_s2.svc
2 ONLINE ONLINE server02 STABLE
將server01的ORCL_rd_s1 relocate到server02上面
srvctl relocate service -db DGORCL -service ORCL_RD_S1 -oldinst orcl1 -newinst orcl2
--檢查狀態(tài)
ora.DGORCL.ORCL_rd_s1.svc
2 ONLINE ONLINE server02 STABLE
ora.DGORCL.ORCL_rd_s2.svc
ONLINE ONLINE server02 STABLE
srvctl modify service -d -s
-n -i "" [-a "" ] [-f]
示例:
[oracle@emrep01 ~]$ srvctl config service -d EMREP -s EMREP_r_s1
Service name: EMREP_R_S1
Service is enabled
Server pool: EMREP_EMREP_R_S1
Cardinality: 1
Disconnect: false
Service role: PRIMARY
Management policy: AUTOMATIC
DTP transaction: false
AQ HA notifications: false
Failover type: NONE
Failover method: NONE
TAF failover retries: 0
TAF failover delay: 0
Connection Load Balancing Goal: LONG
Runtime Load Balancing Goal: NONE
TAF policy specification: NONE
Edition:
Preferred instances: EMREP1
Available instances: EMREP2
將EMREP_R_S1的首選實(shí)例調(diào)整為EMREP2,備選實(shí)例調(diào)整為EMREP1:
srvctl modify service -d EMREP -s EMREP_R_S1 -n -i EMREP2 -a EMREP1
檢查service:
[oracle@emrep01 ~]$ srvctl config service -d EMREP -s EMREP_r_s1
Service name: EMREP_R_S1
Service is enabled
Server pool: EMREP_EMREP_R_S1
Cardinality: 1
Disconnect: false
Service role: PRIMARY
Management policy: AUTOMATIC
DTP transaction: false
AQ HA notifications: false
Failover type: NONE
Failover method: NONE
TAF failover retries: 0
TAF failover delay: 0
Connection Load Balancing Goal: LONG
Runtime Load Balancing Goal: NONE
TAF policy specification: NONE
Edition:
Preferred instances: EMREP2
Available instances: EMREP1
srvctl remove service -d -s
[-i ] [-f]
srvctl stop service -d EMREP -s EMREP_r_s1
srvctl remove service -d EMREP -s EMREP_r_s1
建議配置:
文章版權(quán)歸作者所有,未經(jīng)允許請(qǐng)勿轉(zhuǎn)載,若此文章存在違規(guī)行為,您可以聯(lián)系管理員刪除。
轉(zhuǎn)載請(qǐng)注明本文地址:http://systransis.cn/yun/129322.html
Oracle最佳連接方式之service最佳實(shí)踐及測(cè)試(下) img{ display:block; margin:0 auto !important; width:100%; } body{ width:75%...
摘要:微軟已經(jīng)很久沒(méi)有支持開(kāi)源社區(qū)了,這也是很多公司不采用的原因之一。當(dāng)然微軟總是致力于提供無(wú)的工具簡(jiǎn)單的語(yǔ)法和良好的教程,他們最近也意識(shí)到,開(kāi)源可以為提供更多的創(chuàng)新和業(yè)務(wù)。 得益于CTO、CEO和CDO們積極的推動(dòng),IT基礎(chǔ)設(shè)施正在向云環(huán)境遷移,底層架構(gòu)師則在熱烈討論圍繞著云原生應(yīng)用的SaaS、PaaS和微服務(wù)架構(gòu),而開(kāi)發(fā)者們正在大顯身手,努力探索云計(jì)算的魔盒,找出什么是對(duì)業(yè)務(wù)有價(jià)值的,什...
摘要:年月日甲骨文今日發(fā)布了最新的集成產(chǎn)品,以幫助企業(yè)更便利地運(yùn)用變革性技術(shù)。甲骨文提供下一代用戶(hù)體驗(yàn),包括基于個(gè)人角色使用所有功能,同時(shí)通過(guò)預(yù)先制作的集成模板加速產(chǎn)品上市時(shí)間,為企業(yè)創(chuàng)造更多的價(jià)值。2017年10月11日 –甲骨文今日發(fā)布了最新的集成PaaS產(chǎn)品,以幫助企業(yè)更便利地運(yùn)用變革性技術(shù)。除了最新的自治數(shù)據(jù)管理云服務(wù)、大數(shù)據(jù)分析和人工智能功能之外,甲骨文宣布在其應(yīng)用程序開(kāi)發(fā)平臺(tái)、數(shù)據(jù)集成...
摘要:新晉技術(shù)專(zhuān)家下面是墨天輪部分新晉的技術(shù)專(zhuān)家。大家可以點(diǎn)擊往期閱讀墨天輪技術(shù)專(zhuān)家邀請(qǐng)函了解詳情,申請(qǐng)成為我們的技術(shù)專(zhuān)家,加入專(zhuān)家團(tuán)隊(duì),與我們一起創(chuàng)建一個(gè)開(kāi)放互助的數(shù)據(jù)庫(kù)技術(shù)社區(qū)。新關(guān)聯(lián)公眾號(hào)墨天輪是一個(gè)開(kāi)放互助的數(shù)據(jù)庫(kù)技術(shù)社區(qū)。 引言 近期我們?cè)贒BASK小程序增加了數(shù)據(jù)庫(kù) MongoDB、Redis、 Elasticsearch、DB2、Weblogic 等新的的專(zhuān)題欄目和一些新的技術(shù)...
閱讀 1358·2023-01-11 13:20
閱讀 1707·2023-01-11 13:20
閱讀 1215·2023-01-11 13:20
閱讀 1907·2023-01-11 13:20
閱讀 4165·2023-01-11 13:20
閱讀 2759·2023-01-11 13:20
閱讀 1402·2023-01-11 13:20
閱讀 3673·2023-01-11 13:20