Welcome! Log In Create A New Profile

Advanced

Crash observed while using nginx-upstream-carp along with zone directive

October 24, 2017 05:38AM
Hi,

I am trying to use the following "NGINX upstream carp" module to realize upstream load balancing with a certain server affinity for requests.

https://github.com/olegloa/nginx-upstream-carp

The following basic configuration works fine.

upstream mybackends {
server 192.168.1.3:8720;
server 192.168.1.3:8721;
server 192.168.1.3:8722;

carp;
}

However, if I add a "zone" directive within the upstream block (which contains the carp directive also), the verification test for the configuration (using -t option) crashes.

upstream mybackends {

zone zone_for_mybackends 1m;

server 192.168.1.37:8720;
server 192.168.1.37:8721;
server 192.168.1.37:8722;

carp;
}

The presence of "carp" directive seems to be causing the issue here. From my analysis, the crash seems to be due to the "setting" of peer.data field by carp module, which leads to an invalid memory access in the upstream zone code.

The carp-module code seems to be developed 6-7 years ago, and I guess it is probably not fully compatible with the latest NGINX upstream constructs like zone.

If someone else is using carp module and has faced this problem, could you please explain how it can be resolved?

Thanks
Rajesh
Subject Author Posted

Crash observed while using nginx-upstream-carp along with zone directive

rnmx18 October 24, 2017 05:38AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 64
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready