Konfiguracja DNS
Począwszy od wersji 11gR2, Oracle zaprezentował nowy sposób łączenia się do klastra – SCAN – dzięki temu połączenie do klastra odbywa się z użyciem jednej nazwy, rozwiązywanej przez DNS’y do adresów, na końcu których znajdują się nasłuchy, posiadające zarejestrowane usługi serwera Oracle.
W tej instalacji posłużymy się skonfigurowanymi serwerami DNS na obydwu node’ach (nie będziemy posługiwać się opcją GNS).
// Enterprise Linux BIND Configuration Tool
//
// Default initial "Caching Only" name server configuration
//options {
directory "/var/named";
dump-file "/var/named/data/cache_dump.db";
statistics-file "/var/named/data/named_stats.txt";
/*
* If there is a firewall between you and nameservers you want
* to talk to, you might need to uncomment the query-source
* directive below. Previous versions of BIND always asked
* questions using port 53, but BIND 8.1 uses an unprivileged
* port by default.
*/
// query-source address * port 53;
};zone "localdomain." IN {
type master;
file "localdomain.zone";
allow-update { none; };
};zone "0.0.127.in-addr.arpa." IN {
type master;
file "named.local";
allow-update { none; };
};zone "racdomain." IN {
type master;
file "racdomain.zone";
allow-update { none; };
};
zone "56.168.192.in-addr.arpa." IN {
type master;
file "named.rac";
allow-update { none; };
};
include "/etc/rndc.key";
[root@rac1 Server]# cat /var/named/racdomain.zone
$TTL 86400
@ IN SOA rac2 root.rac1 (
42 ; serial (d. adams)
3H ; refresh
15M ; retry
1W ; expiry
1D ) ; minimum
IN NS rac1
rac1 IN A 192.168.56.121
rac2 IN A 192.168.56.122
rac1-v IN A 192.168.56.131
rac2-v IN A 192.168.56.132
scan IN A 192.168.56.141
scan IN A 192.168.56.142
scan IN A 192.168.56.143
[root@rac2 Server]# cat /var/named/named.rac
$TTL 86400
@ IN SOA rac2. root.rac1. (
42 ; Serial
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ; Minimum
IN NS rac1.
121 IN PTR rac1.
122 IN PTR rac2.
131 IN PTR rac1-v.
132 IN PTR rac2-v.
141 IN PTR scan.
142 IN PTR scan.
143 IN PTR scan.
[root@rac1 ~]# cat /etc/resolv.conf
search racdomain
nameserver 192.168.56.121
nameserver 192.168.56.122
chkconfig named on
- Node RAC2
rndc-confgen -a
[root@rac2 Server]# cat /etc/named.conf
// Enterprise Linux BIND Configuration Tool
//
// Default initial "Caching Only" name server configuration
//
options {
directory "/var/named";
dump-file "/var/named/data/cache_dump.db";
statistics-file "/var/named/data/named_stats.txt";
/*
* If there is a firewall between you and nameservers you want
* to talk to, you might need to uncomment the query-source
* directive below. Previous versions of BIND always asked
* questions using port 53, but BIND 8.1 uses an unprivileged
* port by default.
*/
// query-source address * port 53;
};
zone "localdomain." IN {
type master;
file "localdomain.zone";
allow-update { none; };
};
zone "0.0.127.in-addr.arpa." IN {
type master;
file "named.local";
allow-update { none; };
};
zone "racdomain." IN {
type master;
file "racdomain.zone";
allow-update { none; };
};
zone "56.168.192.in-addr.arpa." IN {
type master;
file "named.rac";
allow-update { none; };
};
include "/etc/rndc.key";
[root@rac2 Server]# cat /var/named/racdomain.zone
$TTL 86400
@ IN SOA rac2 root.rac2 (
42 ; serial (d. adams)
3H ; refresh
15M ; retry
1W ; expiry
1D ) ; minimum
IN NS rac2
rac1 IN A 192.168.56.121
rac2 IN A 192.168.56.122
rac1-v IN A 192.168.56.131
rac2-v IN A 192.168.56.132
scan IN A 192.168.56.141
scan IN A 192.168.56.142
scan IN A 192.168.56.143
[root@rac2 Server]# cat /var/named/named.rac
$TTL 86400
@ IN SOA rac2. root.rac2. (
42 ; Serial
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ; Minimum
IN NS rac2.
121 IN PTR rac1.
122 IN PTR rac2.
131 IN PTR rac1-v.
132 IN PTR rac2-v.
141 IN PTR scan.
142 IN PTR scan.
143 IN PTR scan.
[root@rac2 ~]# cat /etc/resolv.conf
search racdomain
nameserver 192.168.56.122
nameserver 192.168.56.121
chkconfig named on