Configure the NIC Bonding for the RAC Private Network

Source: Internet
Author: User

Configure the NIC Bonding for the RAC Private Network

In the installation and deployment process of RAC, it is not just a simple installation. The possible single point of failure (spof) should be considered during the installation process. The most important part is the private network.

A private network is a channel for communication between RAC nodes, including network heartbeat information between nodes and data blocks transmitted through Cache fusion. Many private networks only connect to a vswitch with a single Nic. What's more, they directly configure the private network using the NIC connection between servers. This deployment method is simple, but it is very risky after RAC is put into use. There are many single points such as NIC, network cable, switch port, and switch. Almost every component failure will lead to RAC split. Therefore, we recommend that you configure the dual Nic bonding for the private network.

Bind a Linux dual Nic to achieve load balancing (bind a Bonding dual Nic)

Linux Bonding initial status issues and solutions

Multi-nic Bonding production practices

Multi-nic Load Balancing (dual-nic Bonding mode)

Install Oracle 11gR2 (x64) in CentOS 6.4)

Steps for installing Oracle 11gR2 in vmwarevm

Install Oracle 11g XE R2 In Debian

The following are my configuration steps:

Environment:

OS: CentOS release 6.4 (Final)

Oracle: 11.2.0.4 RAC

NIC: Four em1, em2, em3, and em4. Currently, em1 is used as the public Nic, em3 is enabled as the private Nic, and em2 and em4 are idle.

Configure and load the bond module (executed on two nodes ):

Edit/etc/modprobe. d/bonding. conf to add the following content:

[Root @ node2 ~] # Vi/etc/modprobe. d/bonding. conf

Alias bond0 bonding

[Root @ node2 ~] # Modprobe-a bond0

Verification:

[Root @ node2 ~] # Lsmod | grep bond

Bonding 127331 0

8021q 25317 1 bonding

Ipv6 321422 274 bonding, ip6t_REJECT, nf_conntrack_ipv6, nf_defrag_ipv6

 

Edit the NIC configuration file as follows:

Node 1:

Ifcfg-em2:

DEVICE = em2

BOOTPROTO = none

ONBOOT = yes

MASTER = bond0

SLAVE = yes

 

Ifcfg-em4:

DEVICE = em4

BOOTPROTO = none

ONBOOT = yes

MASTER = bond0

SLAVE = yes

 

Ifcfg-bond0:

DEVICE = bond0

MASTER = yes

BOOTPROTO = node

ONBOOT = yes

BONDING_OPTS = "mode = 1 miimon = 100"

IPADDR = 10.10.10.105

PREFIX = 24

GATEWAY = 10.10.10.1

 

Node 2:

Ifcfg-em2:

DEVICE = em2

BOOTPROTO = none

ONBOOT = yes

MASTER = bond0

SLAVE = yes

 

Ifcfg-em4:

DEVICE = em4

BOOTPROTO = none

ONBOOT = yes

MASTER = bond0

SLAVE = yes

 

Ifcfg-bond0:

DEVICE = bond0

MASTER = yes

BOOTPROTO = node

ONBOOT = yes

BONDING_OPTS = "mode = 1 miimon = 100"

IPADDR = 10.10.10.106

PREFIX = 24

GATEWAY = 10.10.10.1

I use the primary and secondary network card mode with mode = 1. Only one network card is activated at ordinary times. Once the primary network card fails, the link will be switched to the secondary network card, you can also consider the four or six modes.

After the configuration file is modified, bond0: ifup bond0 is started on the two nodes respectively.

You can see:

[Root @ node1 ~] # Ifconfig

Bond0 Link encap: Ethernet HWaddr C8: 1F: 66: FB: 6F: CB

Inet addr: 10.10.10.105 Bcast: 10.10.10.255 Mask: 255.255.255.0

Inet6 addr: fe80: ca1f: 66ff: fefb: 6fcb/64 Scope: Link

Up broadcast running master multicast mtu: 1500 Metric: 1

RX packets: 9844809 errors: 0 dropped: 0 overruns: 0 frame: 0

TX packets: 7731078 errors: 0 dropped: 0 overruns: 0 carrier: 0

Collisions: 0 txqueuelen: 0

RX bytes: 9097132073 (8.4 GiB) TX bytes: 6133004979 (5.7 GiB)

Em2 Link encap: Ethernet HWaddr C8: 1F: 66: FB: 6F: CB

Up broadcast running slave multicast mtu: 1500 Metric: 1

RX packets: 9792915 errors: 0 dropped: 0 overruns: 0 frame: 0

TX packets: 7731078 errors: 0 dropped: 0 overruns: 0 carrier: 0

Collisions: 0 FIG: 1000

RX bytes: 9088278883 (8.4 GiB) TX bytes: 6133004979 (5.7 GiB)

Interrupt: 38

 

Em4 Link encap: Ethernet HWaddr C8: 1F: 66: FB: 6F: CB

Up broadcast running slave multicast mtu: 1500 Metric: 1

RX packets: 51894 errors: 0 dropped: 0 overruns: 0 frame: 0

TX packets: 0 errors: 0 dropped: 0 overruns: 0 carrier: 0

Collisions: 0 FIG: 1000

RX bytes: 8853190 (8.4 MiB) TX bytes: 0 (0.0 B)

Interrupt: 36

The bonding of the NIC has been configured successfully.

Test and verification

In this case, you can test to disconnect em2 em4, ping the private IP address of the other node on one node for a long time, and observe the changes of the primary slave based on the/proc/net/bonding/bond0 information, it can be found that the ping will not be interrupted when a network card is down.

After Bond0 is configured, the next step is to configure it as the private Nic of RAC.

To avoid configuration failure, first back up the original configuration file.

Use a grid user to back up the $ GRID_HOME/grid/gpnp/noden/profiles/peer/profile. xml file on two nodes:

Cd/u01/app/11.2.0/grid/gpnp/noden/profiles/peer

Cp profile. xml profile. xml. bk

[Root @ node2 peer] # ls

Pending. xml profile_orig.xml profile. xml profile. xml. bk,

View the current Private Network Configuration:

Node2-> oifcfg getif

Em1 192.168.10.0 global public

Em3 10.10.10.0 global cluster_interconnect

Add a new private network and run the following command on any node:

Node1-> oifcfg setif-global bond0/10.10.0: cluster_interconnect

This step may cause an error:

Node1-> oifcfg setif-global bond0/10.10.0: cluster_interconnect

PRIF-33: Failed to set or delete interface because hosts cocould not be discovered

CRS-02307: No GPnP services on requested remote hosts.

PRIF-32: Error in checking for profile availability for host node2

CRS-02306: GPnP service on host "node2" not found.

 

This is caused by gpnpd service exceptions.

Solution: Kill the gpnpd process and GI automatically restarts the gpnpd service.

Run the following command on two nodes:

[Root @ node2 ~] # Ps-ef | grep gpnp

Grid 4927 1 0 Sep22? 00:26:38/u01/app/11.2.0/grid/bin/gpnpd. bin

Grid 48568 46762 0 00:00:00 pts/3 tail-f/u01/app/11.2.0/grid/log/node2/gpnpd. log

Root 48648 48623 0 00:00:00 pts/4 grep gpnp

[Root @ node2 ~] # Kill-9 4927

[Root @ node2 ~] #

See gpnpd. log

After adding a private network, follow these steps to delete the original private network:

Stop and disable crs.

Run the following commands on two nodes as the root user:

Stop crs

Crsctl stop crs

Disable crs

Crsctl disable crs

 

 

Modify the hosts file and change the private IP address to the new address.

Run the following two nodes:

Ping node1-priv

Ping node2-priv

 

Then start crs.

[Root @ node2 ~] # Crsctl enable crs

CRS-4622: Oracle High Availability Services autostart is enabled.

[Root @ node2 ~] # Crsctl start crs

Delete the original private network:

Node2-> oifcfg delif-global em3/10.10.0: cluster_interconnect

Check and verify. The configuration is successful.

Node2-> oifcfg getif

Em1 192.168.10.0 global public

Bond0 10.10.10.0 global cluster_interconnect

Node2->

For more details, please continue to read the highlights on the next page:

  • 1
  • 2
  • Next Page

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.