Configure rac taf on the server (rac application separation)

Source: Internet
Author: User
Tags taf

Server-side configuration rac taf (rac application separation) database version: 10.2.0.1 operating system version: CentOS-5.6 1) Create service [SQL] [oracle @ rac1 ~] $ Srvctl add service-d jscn-s taf_dianping-r jscn1-a jscn2-P basic [oracle @ rac1 ~] $ Srvctl start service-d jscn-s taf_dianping [oracle @ rac1 ~] $ Srvctl enable service-d jscn-s taf_dianping: Use service TAF to modify the configuration, and use the dbms_service.modify_service package. SQL> begin commit (service_name => 'taf _ dianping ', failover_method => commit, failover_type => commit, failover_retries => 180, failover_delay => 5); end; /[oracle @ rac1 ~] $ Srvctl config service-d jscn-s taf_dianping-a taf_dianping PREF: jscn1 AVAIL: jscn2 TAF: basic 2) start monitoring [SQL] [oracle @ rac1 ~] $ Crs_stat-t Name Type Target State Host ------------------------------------------------------------ ora. jscn. db application ONLINE rac1 ora .... n1.inst application ONLINE rac1 ora .... n2.inst application ONLINE rac2 ora .... ping. cs application ONLINE rac1 -- service ora .... cn1.srv application ONLINE rac1 ora .... SM1.asm application ONLINE rac1 ora .... c1.lsnr appli Cation ONLINE rac1 ora. rac1.gsd application ONLINE rac1 ora. rac1.ons application ONLINE rac1 ora. rac1.vip application ONLINE rac1 ora .... SM2.asm application ONLINE rac2 ora .... c2.lsnr application ONLINE rac2 ora. rac2.gsd application ONLINE rac2 ora. rac2.ons application ONLINE rac2 ora. rac2.vip application ONLINE rac2 3) Configure tns [SQL] 192.1 68.8.206 _ two = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.8.206) (PORT = 1521) (ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.8.207) (PORT = 1521) (LOAD_BALANCE = yes) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = taf_dianping) 4) test [SQL] window connection rac C: \ Windows \ system32> sqlplus system/sys@192.168.8.206 _ two Oracle Database 10g Enterprise Edition Release 10.2.0.1.0-64bit Pro Duction With the Partitioning, Real Application Clusters, OLAP and Data Mining options SQL> select instance_name from v $ instance; INSTANCE_NAME -------------- jscn1 stop Node 1 [oracle @ rac1 ~] $ Sqlplus/as sysdba SQL> shutdown immediate [oracle @ rac1 ~] $ Crs_stat-t Name Type Target State Host ------------------------------------------------------------ ora. jscn. db application ONLINE rac1 ora .... n1.inst application OFFLINE ora .... n2.inst application ONLINE rac2 ora .... ping. cs application ONLINE rac1 -- service ora .... cn1.srv application ONLINE rac2 ora .... SM1.asm application ONLINE rac1 ora .... c1.lsnr applicat Ion ONLINE rac1 ora. rac1.gsd application ONLINE rac1 ora. rac1.ons application ONLINE rac1 ora. rac1.vip application ONLINE rac1 ora .... SM2.asm application ONLINE rac2 ora .... c2.lsnr application ONLINE rac2 ora. rac2.gsd application ONLINE rac2 ora. rac2.ons application ONLINE rac2 ora. rac2.vip application ONLINE rac2 again, SQL> select insta Nce_name from v $ instance; now connected to rac2 INSTANCE_NAME ---------------- jscn2 Now restarting node 1SQL> startup and then viewing SQL> select instance_name from v $ instance; INSTANCE_NAME ---------------- jscn2 found that no matter how the connection is now on rac2, now I want him to go back to node 1 and how to re-register it. [oracle @ rac1 ~] $ Srvctl relocate service-d jscn-s taf_dianping-I jscn2-t jscn1 if you want to delete it, follow the steps below: delete service [oracle @ rac1 ~] $ Srvctl stop service-d jscn-s taf_dianping [oracle @ rac1 ~] $ Srvctl remove service-d jscn-s taf_dianpingSQL> begin dbms_service.delete_service (service_name => 'taf _ dianping'); end;

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

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.