Cluster 6. Putting all devices hostnames and IP addresses to the /etc/hosts
Three different networks are used in our cluster:
- BCN (Back-Channel Network - 10.0.53.nodeIP/24) for cluster management traffic, IPMI, switches - node names will be as agrp-c01n01.bcn
- IPMI IP will be - 10.clusterSerialNumber*10.53.nodeIP*10+1/24 (i.e. 10.10.53.11)
- switch stack Ip will be - 10.clusterSerialNumber*10.53.nodeIP*10+2/24 (i.e. 10.10.53.12):
- access stack and execute:
- int vlan 100
- ip address 10.10.53.12 255.255.255.0
- ip address 10.10.53.22 255.255.255.0 secondary
- do sh int vlan 100
- SN (Storage Network - 10.0.52.nodeIP/24) - node names will be as - agrp-c01n01.sn
- IFN (Internet-Facing Network - 10.0.51.ServerIP/24) - only for servers (virtual servers, hosted on a node) - node names will be as - agrp-c01n01.ifn
connect IPMI iLOes agrp-c01n01 goes to 1/0/17 and agrp-c01n02 to 2/0/17 - Back-Channel Network - 10.clusterSerialNumber*10.53.nodeIP/24 => 10.10.53.[12]0
Put below lines to the /etc/hosts (it will be the same on both nodes):
### Nodes
# agrp-c01n01
10.10.53.1 agrp-c01n01.bcn agrp-c01n01
10.10.53.11 agrp-c01n01.ipmi
10.10.52.1 agrp-c01n01.sn
172.16.51.1 agrp-c01n01.ifn
# agrp-c01n01
10.10.53.2 agrp-c01n02.bcn agrp-c01n02
10.10.53.21 agrp-c01n02.ipmi
10.10.52.2 agrp-c01n02.sn
172.16.51.2 agrp-c01n02.ifn
# Network Switches
10.10.53.12 agrp-stack01
10.10.53.12 agrp-stack01
10.10.53.22 agrp-stack01
Save and exit, verify with ping script. This script will ping every host in /etc/hosts file and then will display ping result showing how many packets are send, received and packet loss:
for name in $(grep -E "^(172|10)" /etc/hosts | awk '{print $2}');
do
echo "NAME=$name";
ping $name -c 3 | grep "packet loss";
echo "";
done
Only ping to agrp-c01n01.ipmi & agrp-c01n02.ipmi must response "Destination Host Unreachable" because we haven't yer set up IPMI
for name in $(grep -E "^(172|10)" /etc/hosts | awk '{print $2}');
do
echo "NAME=$name";
ping $name -c 3 | grep "packet loss";
echo "";
done
Only ping to agrp-c01n01.ipmi & agrp-c01n02.ipmi must response "Destination Host Unreachable" because we haven't yer set up IPMI
This tutorial was used to understand and setup clustering: AN!Cluster
No comments:
Post a Comment