Re: [PATCH net-next v1] ipvs: add consistent source hashing scheduling

2018-04-02 Thread Vincent Bernat
❦ 2 avril 2018 22:05 +0300, Julian Anastasov  : > Sorry to say it but may be you missed the discussion > on lvs-devel about the new MH scheduler implemented by Inju Song: > > https://www.spinics.net/lists/lvs-devel/msg04928.html > http://archive.linuxvirtualserver.org/html/lvs-devel/2018-0

Re: [PATCH net-next v1] ipvs: add consistent source hashing scheduling

2018-04-02 Thread Julian Anastasov
Hello, On Mon, 2 Apr 2018, Vincent Bernat wrote: > Based on Google's Maglev algorithm [1][2], this scheduler builds a > lookup table in a way disruption is minimized when a change > occurs. This helps in case of active/active setup without > synchronization. Like for classic source hashi

Re: [PATCH net-next v1] ipvs: add consistent source hashing scheduling

2018-04-02 Thread Vincent Bernat
❦ 2 avril 2018 10:33 -0700, Eric Dumazet  : >> +static inline u32 >> +ip_vs_csh_permutation(struct ip_vs_dest *d, int j) >> +{ >> +u32 offset, skip; >> +__be32 addr_fold = d->addr.ip; >> + >> +#ifdef CONFIG_IP_VS_IPV6 >> +if (d->af == AF_INET6) >> +addr_fold = d->addr.ip6

Re: [PATCH net-next v1] ipvs: add consistent source hashing scheduling

2018-04-02 Thread Eric Dumazet
On 04/02/2018 10:20 AM, Vincent Bernat wrote: > +static inline u32 > +ip_vs_csh_permutation(struct ip_vs_dest *d, int j) > +{ > + u32 offset, skip; > + __be32 addr_fold = d->addr.ip; > + > +#ifdef CONFIG_IP_VS_IPV6 > + if (d->af == AF_INET6) > + addr_fold = d->addr.ip6[0]

[PATCH net-next v1] ipvs: add consistent source hashing scheduling

2018-04-02 Thread Vincent Bernat
Based on Google's Maglev algorithm [1][2], this scheduler builds a lookup table in a way disruption is minimized when a change occurs. This helps in case of active/active setup without synchronization. Like for classic source hashing, this lookup table is used to assign connections to a real server