<div dir="ltr">Your balancing rules are incorrect. This is how we balance 30% per IP:<div><br></div><div><div># 33% of traffic per local IP</div><div>acl third random 1/3</div><div>acl half random 1/2</div><div><br></div><div>tcp_outgoing_address X.X.X.2 third</div><div>tcp_outgoing_address X.X.X.3 half</div><div>tcp_outgoing_address X.X.X.4</div></div><div><br></div><div>Read <a href="https://wiki.squid-cache.org/Features/AclRandom">https://wiki.squid-cache.org/Features/AclRandom</a>.</div><div><br></div><div>Basically for 1/5 you need something like this:</div><div><br></div><div><div>acl fifth random 1/5</div><div>acl fourth random 1/4</div><div>acl third random 1/3</div><div>acl half random 1/2</div><div><br></div><div>tcp_outgoing_address XX.3X.YYY.10 <span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">fifth</span></div><div>tcp_outgoing_address XX.X3.YYY.21 <span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">fourth</span></div><div>tcp_outgoing_address XX.5X.YYY.31 <span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">third</span></div><div>tcp_outgoing_address XX.X9.YYY.34 <span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">half</span></div><div>tcp_outgoing_address XX.5X.YYY.38</div></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Feb 22, 2018 at 10:15 AM, Patrick Chemla <span dir="ltr"><<a href="mailto:patrick.chemla@performance-managers.com" target="_blank">patrick.chemla@performance-managers.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
I have googled for days and can't find the right settings to distribut outgoing requests over part on local IPs of my server.<br>
<br>
This is my conf I built according to what I found on docs and forums:<br>
<br>
<br>
Squid Cache: Version 4.0.17<br>
<br>
------------<br>
<br>
blablabla<br>
<br>
blablabla<br>
<br>
blablabla<br>
<br>
------------<br>
<br>
acl Percent001 random 1/5<br>
acl Percent002 random 1/5<br>
acl Percent003 random 1/5<br>
acl Percent004 random 1/5<br>
acl Percent005 random 1/5<br>
<br>
server_persistent_connections off<br>
<br>
<br>
tcp_outgoing_address XX.3X.YYY.10 Percent001<br>
tcp_outgoing_address XX.X3.YYY.21 Percent002<br>
tcp_outgoing_address XX.5X.YYY.31 Percent003<br>
tcp_outgoing_address XX.X9.YYY.34 Percent004<br>
tcp_outgoing_address XX.5X.YYY.38 Percent005<br>
<br>
balance_on_multiple_ip on<br>
<br>
forwarded_for delete<br>
via off<br>
<br>
My problem is that this server as<br>
<br>
- a main IP MA.IN.IP.00 of course<br>
<br>
- a locahost 127.0.0.1 of course<br>
<br>
- some secondary IPs attached to the same interface as the main IP<br>
<br>
<br>
The input traffic comes through one of the secondaries, and I need the output traffic to get out randomly through other secondaries IPs, not any squid traffic from the main IP.<br>
<br>
When I look at the log, or using network tcpdump analyzer, I can see that there is squid outgoing traffic on this IP, and I can't find how to deny tcp_outgoing_address to be on the main IP.<br>
<br>
I hope it's clear, and I need help after I searched for days many combinations.<br>
<br>
Many thanks<br>
<br>
Patrick<br>
<br>
______________________________<wbr>_________________<br>
squid-users mailing list<br>
<a href="mailto:squid-users@lists.squid-cache.org" target="_blank">squid-users@lists.squid-cache.<wbr>org</a><br>
<a href="http://lists.squid-cache.org/listinfo/squid-users" rel="noreferrer" target="_blank">http://lists.squid-cache.org/l<wbr>istinfo/squid-users</a><br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">With best regards, Ivan Larionov.</div>
</div>