Escolar Documentos
Profissional Documentos
Cultura Documentos
1
Agenda
1. What are the major components of Oracle Clusterware and
how do they interact?
2. Why does Oracle reboot nodes?
3. How does Oracle handle private interconnect failure and
scalability?
4. When my public network fails, why does ASM and the db
instance get shut down?
5. What exactly is the VIP, it’s purpose, and how does it
work?
6. What is the purpose of ONS – is it required for anything
other than FAN?
7. How does Oracle do load balancing across RAC
instances?
2
RAC 10 Architecture
public network
VIP1 VIPn
Service Service Node n
Node1
Listener Listener
instance 1 instance n
ASM ASM
cluster
Oracle Clusterware interconnect Oracle Clusterware
shared storage
Redo / Archive logs all instances
Managed by ASM
Database / Control files
VIP
Event Management
High Availability
Clusterware
Framework
Process Monitor
Group Membership
Operating System
3
Oracle Clusterware 10 Architecture
VIP
EVM
RACG
Oracle
CRS
Clusterware
OPROC
CSS
Operating System
4
Oracle Clusterware
Group Membership and Heartbeats
Heartbeat Failures
• Network Heartbeat
node(4) missed(59) checkin(s)
>2005-06-18 08:14:37.858 [3002575792]
>WARNING: clssnmPollingThread:
Eviction started for node 4,flags 0x000d,
>state 3, wt4c 0
>2005-06-18 08:14:41.985 [3047074736]
>TRACE: clssnmHandleSync:
• Disk Heartbeat
CSSD]2005-10-11 15:56:23.668 [93645744]
>WARNING: clssnmDiskPMT: long disk latency
>(45940 ms) to voting disk (0//dev/raw/raw1)
5
Oracle Clusterware
Split Brain Resolution
Oracle Clusterware
Disk Heartbeat
• Disktimeout: maximum time (s) for voting file I/O to
complete.
• 10g Release 1 and 10.2.0.1 I/O timeout was directly related to
MissCount.
• I.E. MissCount governed sensitivity of both heartbeats
• 10.2.0.2– more granular sensitivity via separation of network
and disk heartbeats
• Disktimeout parameter set for CSS, default = 200s
• Tune disktimeout for the Voting Disk storage solution
• be careful - some multipathing solutions require high
disktimeout values
6
Changing MissCount
7
Private Interconnect
/…/
public network
VIP1 VIP2 VIPn
Service Service Node 2 Service Node n
Node1
Listener Listener Listener
instance 1 instance 2 instance n
ASM ASM ASM
Oracle Clusterware Oracle Clusterware Oracle Clusterware
Operating System Operating System Operating System
Switch 1 Switch 2
cluster
interconnect
Private Interconnect
8
Interconnect Bandwidth
IPC configuration
• Settings:
• Socket receive buffers ( 256 KB – 1MB )
• Negotiated top bit rate and full duplex mode
• NIC ring buffers
• Ethernet flow control settings
• CPU(s) receiving network interrupts
• Verify your setup:
• CVU does checking
• Load testing eliminates potential for problems
9
Interconnect Bonding
• Terminology: NIC Bonding, link aggregation, port
trunking, NIC teaming, …
• Multiple physical links combined into a single logical
link
• Provides redundancy and/or scalability
• Logical link is provided to Oracle Clusterware and
RAC
• Most operate at OSI Layer 2
• Different implementations on different platforms
• Read the fine print
• Generally recommend failover only (active/passive)
configuration
Interconnect Bonding
• Some cluster managers provide support for multiple
interconnects
• Not required with Oracle Clusterware
• OS-Specific bonding
• Solaris: IPMP, Sun Trunking
• AIX: etherchannel
• HP-UX: APA
• Linux: NIC Bonding
• Windows: NIC Teaming
• IB drivers inherently support failover and load balancing.
10
Interconnect Configuration
• OCR
[SYSTEM.css.interfaces.global.bond0.192|d168|d12|d0.1]
ORATEXT : cluster_interconnect
SECURITY : {USER_PERMISSION : PROCR_ALL_ACCESS, GROUP_PERMISSION :
PROCR_ALL_ACCESS, OTHER_PERMISSION : PROCR_READ, USER_NAME :
oracle, GROUP_NAME : odba}
• RDBMS
SQL> select * from x$ksxpia;
11
Misconfigured or Faulty Interconnect
Can Cause:
• Dropped packets/fragments
• Buffer overflows
• Packet reassembly failures or timeouts
• Ethernet Flow control kicks in
• TX/RX errors
Db_block_size = 8K
ifconfig –a:
eth0 Link encap:Ethernet HWaddr 00:0B:DB:4B:A2:04
inet addr:130.35.25.110 Bcast:130.35.27.255 Mask:255.255.252.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:21721236 errors:135 dropped:0 overruns:0 frame:95
TX packets:273120 errors:0 dropped:0 overruns:0 carrier:0
12
“Lost Blocks”: IP Packet Reassembly
Failures
netstat –s
Ip:
84884742 total packets received
…
1201 fragments dropped after timeout
…
3384 packet reassembles failed
13
<Insert Picture Here>
3
VIP1
7 Service
6 Listener
5 Instance 1
4 ASM
2 Oracle Clusterware
1 Operating System
14
Oracle Dependencies
Prior to 10.2.0.3
public network
VIP1 VIP2
Service Service Node2
Node1
Listener Listener
instance 1 instance 2
ASM ASM
cluster
Oracle Clusterware interconnect Oracle Clusterware
shared storage
Redo / Archive logs all instances
Managed by ASM
Database / Control files
Oracle Dependencies
Prior to 10.2.0.3
public network
VIP1 VIP1 VIP2
Service Service Node2
Node1
Listener Listener
instance 1 instance 2
ASM ASM
cluster
Oracle Clusterware interconnect Oracle Clusterware
shared storage
Redo / Archive logs all instances
Managed by ASM
Database / Control files
15
Oracle Dependencies
public network
VIP1 VIP2
Service Service Node 2
Node1
Listener Listener
instance 1 instance 2
ASM ASM
cluster
Oracle Clusterware interconnect Oracle Clusterware
shared storage
Redo / Archive logs all instances
Managed by ASM
Database / Control files
Oracle Dependencies
public network
VIP1 VIP1 VIP2
Service Service Node 2
Node1
Listener Listener
instance 1 instance 2
ASM ASM
cluster
Oracle Clusterware interconnect Oracle Clusterware
shared storage
Redo / Archive logs all instances
Managed by ASM
Database / Control files
16
<Insert Picture Here>
17
Oracle RAC 10g VIP
The Details!
• One for each node in cluster
• Required for Oracle Clusterware installation
• IP and network name should not currently be in use
• Should be registered in DNS and be on the same
subnet as public IP address
• Can use OS bonding to provide failover and load
balancing on network interfaces on the node
• Configuration managed by VIPCA
• Note that netmask defaults to 255.255.255.0, rather
than defaulting to netmask of underlying physical
interface.
• You will only have one active RAC VIP per node
(there may be others who have relocated due to
failure!)
• Independent of number of databases running in cluster
18
Oracle RAC 10g VIP
Listener.ora
SID_LIST_LISTENER_PMRAC1 =
(SID_LIST =
(SID_DESC =
(SID_NAME = PLSExtProc)
(ORACLE_HOME = /u01/oracle/product/10gR2/asm)
(PROGRAM = extproc)
)
)
LISTENER_PMRAC1 =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
(ADDRESS = (PROTOCOL = TCP)(HOST = pmrac1-vip)(PORT = 1521)(IP = FIRST))
VIP (ADDRESS = (PROTOCOL = TCP)(HOST = 144.25.214.45)(PORT = 1521)(IP = FIRST))
)
)
19
Application VIPs
20
<Insert Picture Here>
21
What is FAN?
Fan Clients
22
<Insert Picture Here>
LISTENER
Service OLTP?
OLTP1 on N1
Network
Network OLTP2 on N2
Application
Server OLTP3 on N3
RAC Database
23
Connection Load Balancing
LISTENER
Connection
made to
ork
tw
OLTP1 Ne
Listeners
RAC
Clients Database
Connection Pools
How do you Load Balance?
c c
c c
c
c cc c
c
c c
24
Load Balancing Advisory
25
View LBA FAN Event
26
Load Balancing Advisory
Enabled through Service Goal
• THROUGHPUT – Work requests are directed based on
throughput .
• used when the work in a service completes at homogenous
rates. An example is a trading system where work requests
are similar lengths.
• SERVICE_TIME – Work requests are directed based
on response time.
• used when the work in a service completes at various rates.
An example is as internet shopping system where work
requests are various lengths
• None – Default setting, turn off advisory
27
FAN/FCF Client Integration
JDBC
Q&
A
QUESTIONS
ANSWERS
28
<Insert Picture Here>
Appendix
http://search.oracle.com
REAL APPLICATION CLUSTERS
or
otn.oracle.com/rac
29
Useful Metalink Notes
OTN.ORACLE.COM/RAC
30
31