[MASOCH-L] Roteamento dentro do Squid
Julio Arruda
jarruda-gter at jarruda.com
Fri Jan 6 14:59:25 -03 2006
O 'tcp_outgoing_address 200.141.99.193' esta dizendo para o squid usar
este endereco como "ponta" da conexao. Pense nisto como uma maneira de
forcar o "bind" do sessao TCP "saindo" do cache, nesta porta.
So que, isto nao forca o trafego a SAIR por esta porta, a porta de saida
vai ser a porta que a decisao de roteamento do kernel "decidir"
(no seu caso, a rota default, a menos que voce tenha feito algo funny,
que so seria visivel no ip route show :-).
Para tanto, normalmente voce estaria brincando com coisas como iproute2
http://www.tldp.org/HOWTO/Adv-Routing-HOWTO/ tem algumas dicas
Guilherme wrote:
> Pessoal, o servidor tem duas saidas de internet.
>
> ppp0 Link encap:Point-to-Point Protocol
> inet addr:200.165.237.147 P-t-P:200.217.72.1 Mask:255.255.255.255
> UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1492 Metric:1
> RX packets:15182381 errors:0 dropped:0 overruns:0 frame:0
> TX packets:16114194 errors:0 dropped:0 overruns:0 carrier:0
> collisions:0 txqueuelen:3
> RX bytes:2022499793 (1928.8 Mb) TX bytes:2275168913 (2169.7 Mb)
>
> ppp1 Link encap:Point-to-Point Protocol
> inet addr:200.141.99.193 P-t-P:200.217.72.56 Mask:255.255.255.255
> UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1492 Metric:1
> RX packets:13437644 errors:0 dropped:0 overruns:0 frame:0
> TX packets:12333236 errors:0 dropped:0 overruns:0 carrier:0
> collisions:0 txqueuelen:3
> RX bytes:2131497045 (2032.7 Mb) TX bytes:3152584958 (3006.5 Mb)
>
> Eu queria configurar meu squid para fazer as requisições vindas da rede 10.11.0.0/24 sair pela interface ppp1. Acrescentei exatamente as linhas abaixo em meu squid.conf, só que não funciona.
>
> acl rede1 src 10.11.0.0/255.255.255.0
> tcp_outgoing_address 200.141.99.193 rede1
>
> Abaixo está listada com o comando route a tabela de roteamento do kernel.
>
> (root at gw-fde)[/]# route
> Kernel IP routing table
> Destination Gateway Genmask Flags Metric Ref Use Iface
> 200.217.72.56 * 255.255.255.255 UH 0 0 0 ppp1
> 200.217.72.1 * 255.255.255.255 UH 0 0 0 ppp0
> 10.0.0.0 * 255.255.255.0 U 0 0 0 eth0
> 10.2.0.0 * 255.255.255.0 U 0 0 0 eth0
> 10.4.0.0 * 255.255.255.0 U 0 0 0 eth0
> 10.12.0.0 * 255.255.255.0 U 0 0 0 eth0
> 10.14.0.0 * 255.255.255.0 U 0 0 0 eth0
> 10.10.1.0 * 255.255.255.0 U 0 0 0 eth0
> localnet * 255.255.255.0 U 0 0 0 eth0
> 10.1.0.0 * 255.255.255.0 U 0 0 0 eth0
> 10.3.0.0 * 255.255.255.0 U 0 0 0 eth0
> 10.11.0.0 * 255.255.255.0 U 0 0 0 eth0
> 10.13.0.0 * 255.255.255.0 U 0 0 0 eth0
> 10.15.0.0 * 255.255.255.0 U 0 0 0 eth0
> loopback * 255.0.0.0 U 0 0 0 lo
> default 200.217.72.1 0.0.0.0 UG 0 0 0 ppp0
>
> Estou usando o squid compilado versão STABLE11, mas não estou conseguindo.
>
> Fico grato pela ajuda de todos aqui da lista
>
>
> __
> masoch-l list
> https://eng.registro.br/mailman/listinfo/masoch-l
>
More information about the masoch-l
mailing list