Re: Round robin load distribution among servers does not work properly
In message 96c8e9660904071112p557840a4kfd85120d7c275...@mail.gmail.com, Mallappa Pallakke writes: Hi Mark/Kevin, I did the changes you suggested and it worked fine. Thanks a lot for all your help. Regarding round-robin load sharing instead of random, I have planned to have a dynamic update (nsupdate) triggered at realtime when ever a server goes down or comes up so that there will not be any possibility of putting double load on any server. My only challenge is to load the traffic on newly coming up server equal to other servers during high traffic. I need to do some controlled distribution of load (more on new server than others untill it comes close to other servers!). Please tell me if it has got any problem. If you need that much control you really need something other than named or you need a extra server. The DNS really isn't designed to, nor is it capable of, distributing load so precisely. Mark -- Mark Andrews, ISC 1 Seymour St., Dundas Valley, NSW 2117, Australia PHONE: +61 2 9871 4742 INTERNET: mark_andr...@isc.org ___ bind-users mailing list bind-users@lists.isc.org https://lists.isc.org/mailman/listinfo/bind-users
Re: Round robin load distribution among servers does not work properly
* Mallappa Pallakke: Can anybody tell me why this limitation and is there any sollution to resove this problem? Does your dig call result in two lookups behind the scenes, perhaps? ___ bind-users mailing list bind-users@lists.isc.org https://lists.isc.org/mailman/listinfo/bind-users
Round robin load distribution among servers does not work properly
Hi, I tried with 9.5.1.P2, but still I am not getting the expected round robin results: Please see below my named.conf and zone file: named.conf: = options { directory /var/named; // Uncommenting this might help if you have to go through a // firewall and things are not working out. But you probably // need to talk to your firewall admin. //query-source port 53; rrset-order { order cyclic;}; // fixed, random, cyclic }; zone mycompany.com { type master; // notify no; file db.mycompany.com; allow-update { any; }; // allow-update { 127.0.0.1; }; notify yes; }; db.mycompany.com: === $ORIGIN . $TTL 0 ; mycompany.com IN SOA www.mycompany.com. hostmaster.mycompany.com. ( 199813404 ; serial 1 ; refresh (1 second) 1 ; retry (1 second) 1 ; expire (1 second) 1 ; minimum (1 second) ) NS www.mycompany.com. $ORIGIN mycompany.com. localhost A 127.0.0.1 $TTL 0 ; www A 10.10.68.1 A 10.10.68.2 A 10.10.68.3 A 10.10.68.4 I always get following answers repeatedly. Not getting 10.10.68.2 and 10.10.68.3 as top records in response messages: = atcafs-n4s1:/kwlogs/msp# dig www.mycompany.com ; DiG 9.3.2 www.mycompany.com ;; global options: printcmd ;; Got answer: ;; -HEADER- opcode: QUERY, status: NOERROR, id: 13961 ;; flags: qr aa rd ra; QUERY: 1, ANSWER: 4, AUTHORITY: 1, ADDITIONAL: 0 ;; QUESTION SECTION: ;www.mycompany.com. IN A ;; ANSWER SECTION: www.mycompany.com. 0 IN A 10.10.68.4 www.mycompany.com. 0 IN A 10.10.68.1 www.mycompany.com. 0 IN A 10.10.68.2 www.mycompany.com. 0 IN A 10.10.68.3 ;; AUTHORITY SECTION: mycompany.com. 0 IN NS www.mycompany.com. ;; Query time: 1 msec ;; SERVER: 10.10.68.1#53(10.10.68.1) ;; WHEN: Sun Apr 6 00:21:07 2008 ;; MSG SIZE rcvd: 113 = atcafs-n4s1:/kwlogs/msp# dig www.mycompany.com ; DiG 9.3.2 www.mycompany.com ;; global options: printcmd ;; Got answer: ;; -HEADER- opcode: QUERY, status: NOERROR, id: 65208 ;; flags: qr aa rd ra; QUERY: 1, ANSWER: 4, AUTHORITY: 1, ADDITIONAL: 0 ;; QUESTION SECTION: ;www.mycompany.com. IN A ;; ANSWER SECTION: www.mycompany.com. 0 IN A 10.10.68.2 www.mycompany.com. 0 IN A 10.10.68.3 www.mycompany.com. 0 IN A 10.10.68.4 www.mycompany.com. 0 IN A 10.10.68.1 ;; AUTHORITY SECTION: mycompany.com. 0 IN NS www.mycompany.com. ;; Query time: 1 msec ;; SERVER: 10.10.68.1#53(10.10.68.1) ;; WHEN: Sun Apr 6 00:21:09 2008 ;; MSG SIZE rcvd: 113 == Please let me know anything is missing. Regards, Mallappa Pallakke On Sun, Apr 5, 2009 at 8:55 AM, Kirk b...@kirkb.net wrote: Mallappa Pallakke wrote: Hi, I was trying to do load balancing of client request among configured servers using internal DNS server, I get proper load balaning (DNS response with top most IP address going with proper round robin fashio) for odd number of IP addresses. But it does not give same bevior for even number of IP addresses. For example: If I have configured x.y.z.1, x.y.z.2, x.y.z.3, I get following combinations in dig response: x.y.z.1 x.y.z.2 x.y.z.3 x.y.z.2 x.y.z.3 x.y.z.1 x.y.z.3 x.y.z.1 x.y.z.2 And this repeats, giving round robin distribution. However, if I add one more IP address to the zone list (x.y.z.4), I get only following combinations: x.y.z.1 x.y.z.2 x.y.z.3 x.y.z.4 and x.y.z.3 x.y.z.4 x.y.z.1 x.y.z.2 It gets repeated. I will never get x.y.z.2 and x.y.z.4 as top entries in this response. Can anybody tell me why this limitation and is there any sollution to resove this problem? Thanks in advance. Mallappa Not sure what version of BIND you are using, but here I am using 9.5.1-P2. I just loaded a zone with 10 www records and different IP's and they are handed out round robin just fine. The idea of using DNS for load balancing has been brought up here so many times its hard to count. The answer is always the same. DNS was *never* meant to provide this functionality. Spend the big bucks and get a device meant to do *load balancing*. Search the archive for previous threads on this subject. http://marc.info/?l=bind9-usersw=2r=1s=load+balancingq=b
Re: Round robin load distribution among servers does not work properly
In message 96c8e9660904061734t61414549o22a535e681f58...@mail.gmail.com, Mallappa Pallakke writes: Hi, I tried with 9.5.1.P2, but still I am not getting the expected round robin results: Please see below my named.conf and zone file: named.conf: = options { directory /var/named; // Uncommenting this might help if you have to go through a // firewall and things are not working out. But you probably // need to talk to your firewall admin. //query-source port 53; rrset-order { order cyclic;};// fixed, random, cyclic }; zone mycompany.com { type master; //notify no; file db.mycompany.com; allow-update { any; }; // allow-update { 127.0.0.1; }; notify yes; }; db.mycompany.com: === $ORIGIN . $TTL 0 ; mycompany.com IN SOA www.mycompany.com. hostmaster.mycompany.com. ( 199813404 ; serial 1 ; refresh (1 second) 1 ; retry (1 second) 1 ; expire (1 second) 1 ; minimum (1 second) ) NS www.mycompany.com. $ORIGIN mycompany.com. localhost A 127.0.0.1 $TTL 0 ; www A 10.10.68.1 A 10.10.68.2 A 10.10.68.3 A 10.10.68.4 Change the nameservers name to be something other than www.mycompany.com. www.mycompany.com is being retrieved twice once for the answer section and once for the additional section. Each retrieval rotates the RRset once. The latter gets thrown away when named supresses duplicate RRsets in the answer so you see 2 rotations and 2 divides equally into 4. B.T.W. one should choose random rather than round-robin if you want uniform load on failure. Mark I always get following answers repeatedly. Not getting 10.10.68.2 and 10.10.68.3 as top records in response messages: = atcafs-n4s1:/kwlogs/msp# dig www.mycompany.com ; DiG 9.3.2 www.mycompany.com ;; global options: printcmd ;; Got answer: ;; -HEADER- opcode: QUERY, status: NOERROR, id: 13961 ;; flags: qr aa rd ra; QUERY: 1, ANSWER: 4, AUTHORITY: 1, ADDITIONAL: 0 ;; QUESTION SECTION: ;www.mycompany.com. IN A ;; ANSWER SECTION: www.mycompany.com. 0 IN A 10.10.68.4 www.mycompany.com. 0 IN A 10.10.68.1 www.mycompany.com. 0 IN A 10.10.68.2 www.mycompany.com. 0 IN A 10.10.68.3 ;; AUTHORITY SECTION: mycompany.com. 0 IN NS www.mycompany.com. ;; Query time: 1 msec ;; SERVER: 10.10.68.1#53(10.10.68.1) ;; WHEN: Sun Apr 6 00:21:07 2008 ;; MSG SIZE rcvd: 113 = atcafs-n4s1:/kwlogs/msp# dig www.mycompany.com ; DiG 9.3.2 www.mycompany.com ;; global options: printcmd ;; Got answer: ;; -HEADER- opcode: QUERY, status: NOERROR, id: 65208 ;; flags: qr aa rd ra; QUERY: 1, ANSWER: 4, AUTHORITY: 1, ADDITIONAL: 0 ;; QUESTION SECTION: ;www.mycompany.com. IN A ;; ANSWER SECTION: www.mycompany.com. 0 IN A 10.10.68.2 www.mycompany.com. 0 IN A 10.10.68.3 www.mycompany.com. 0 IN A 10.10.68.4 www.mycompany.com. 0 IN A 10.10.68.1 ;; AUTHORITY SECTION: mycompany.com. 0 IN NS www.mycompany.com. ;; Query time: 1 msec ;; SERVER: 10.10.68.1#53(10.10.68.1) ;; WHEN: Sun Apr 6 00:21:09 2008 ;; MSG SIZE rcvd: 113 === Please let me know anything is missing. Regards, Mallappa Pallakke On Sun, Apr 5, 2009 at 8:55 AM, Kirk b...@kirkb.net wrote: Mallappa Pallakke wrote: Hi, I was trying to do load balancing of client request among configured servers using internal DNS server, I get proper load balaning (DNS response with top most IP address going with proper round robin fashio) for odd number of IP addresses. But it does not give same bevior for even number of IP addresses. For example: If I have configured x.y.z.1, x.y.z.2, x.y.z.3, I get following combinations in dig response: x.y.z.1 x.y.z.2 x.y.z.3 x.y.z.2 x.y.z.3 x.y.z.1 x.y.z.3 x.y.z.1 x.y.z.2 And this repeats, giving round robin distribution. However, if I add one more IP address to the zone list (x.y.z.4), I get only following combinations: x.y.z.1 x.y.z.2 x.y.z.3 x.y.z.4 and x.y.z.3 x.y.z.4 x.y.z.1 x.y.z.2 It gets repeated. I will
Re: Round robin load distribution among servers does not work properly
Hi Mark, I do not see any additional section in the response. Can you please tell me what exactly you are asking me to change? I selected cyclic instead of random since I want my client requests to go to servers in exactly round-robin order. Please tell is there anything wrong with this? Thanks, Mallappa Pallakke On Mon, Apr 6, 2009 at 6:55 PM, Mark Andrews mark_andr...@isc.org wrote: In message 96c8e9660904061734t61414549o22a535e681f58...@mail.gmail.com, Mallappa Pallakke writes: Hi, I tried with 9.5.1.P2, but still I am not getting the expected round robin results: Please see below my named.conf and zone file: named.conf: = options { directory /var/named; // Uncommenting this might help if you have to go through a // firewall and things are not working out. But you probably // need to talk to your firewall admin. //query-source port 53; rrset-order { order cyclic;}; // fixed, random, cyclic }; zone mycompany.com { type master; // notify no; file db.mycompany.com; allow-update { any; }; // allow-update { 127.0.0.1; }; notify yes; }; db.mycompany.com: === $ORIGIN . $TTL 0 ; mycompany.com IN SOA www.mycompany.com. hostmaster.mycompany.com. ( 199813404 ; serial 1 ; refresh (1 second) 1 ; retry (1 second) 1 ; expire (1 second) 1 ; minimum (1 second) ) NS www.mycompany.com. $ORIGIN mycompany.com. localhost A 127.0.0.1 $TTL 0 ; www A 10.10.68.1 A 10.10.68.2 A 10.10.68.3 A 10.10.68.4 Change the nameservers name to be something other than www.mycompany.com. www.mycompany.com is being retrieved twice once for the answer section and once for the additional section. Each retrieval rotates the RRset once. The latter gets thrown away when named supresses duplicate RRsets in the answer so you see 2 rotations and 2 divides equally into 4. B.T.W. one should choose random rather than round-robin if you want uniform load on failure. Mark I always get following answers repeatedly. Not getting 10.10.68.2 and 10.10.68.3 as top records in response messages: = atcafs-n4s1:/kwlogs/msp# dig www.mycompany.com ; DiG 9.3.2 www.mycompany.com ;; global options: printcmd ;; Got answer: ;; -HEADER- opcode: QUERY, status: NOERROR, id: 13961 ;; flags: qr aa rd ra; QUERY: 1, ANSWER: 4, AUTHORITY: 1, ADDITIONAL: 0 ;; QUESTION SECTION: ;www.mycompany.com. IN A ;; ANSWER SECTION: www.mycompany.com. 0 IN A 10.10.68.4 www.mycompany.com. 0 IN A 10.10.68.1 www.mycompany.com. 0 IN A 10.10.68.2 www.mycompany.com. 0 IN A 10.10.68.3 ;; AUTHORITY SECTION: mycompany.com. 0 IN NS www.mycompany.com. ;; Query time: 1 msec ;; SERVER: 10.10.68.1#53(10.10.68.1) ;; WHEN: Sun Apr 6 00:21:07 2008 ;; MSG SIZE rcvd: 113 = atcafs-n4s1:/kwlogs/msp# dig www.mycompany.com ; DiG 9.3.2 www.mycompany.com ;; global options: printcmd ;; Got answer: ;; -HEADER- opcode: QUERY, status: NOERROR, id: 65208 ;; flags: qr aa rd ra; QUERY: 1, ANSWER: 4, AUTHORITY: 1, ADDITIONAL: 0 ;; QUESTION SECTION: ;www.mycompany.com. IN A ;; ANSWER SECTION: www.mycompany.com. 0 IN A 10.10.68.2 www.mycompany.com. 0 IN A 10.10.68.3 www.mycompany.com. 0 IN A 10.10.68.4 www.mycompany.com. 0 IN A 10.10.68.1 ;; AUTHORITY SECTION: mycompany.com. 0 IN NS www.mycompany.com. ;; Query time: 1 msec ;; SERVER: 10.10.68.1#53(10.10.68.1) ;; WHEN: Sun Apr 6 00:21:09 2008 ;; MSG SIZE rcvd: 113 === Please let me know anything is missing. Regards, Mallappa Pallakke On Sun, Apr 5, 2009 at 8:55 AM, Kirk b...@kirkb.net wrote: Mallappa Pallakke wrote: Hi, I was trying to do load balancing of client request among configured servers using internal DNS server, I get proper load balaning (DNS response with top most IP address going with proper round robin fashio) for odd number of IP addresses. But it does not give same bevior for even number of IP addresses. For example: If I have configured x.y.z.1, x.y.z.2, x.y.z.3, I get following combinations in dig response: x.y.z.1