Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Linux Virtual Server: Users

[lvs-users] another lvs-tun problem with large posts (MTU and fragmentation)

 

 

Linux Virtual Server users RSS feed   Index | Next | Previous | View Threaded


udo at udosa

Apr 17, 2008, 5:36 AM

Post #1 of 3 (457 views)
Permalink
[lvs-users] another lvs-tun problem with large posts (MTU and fragmentation)

hi lvs-evangelists,

i am really a LVS nebiew and i have setup an LVS Tun Set on 3 machines.

The reason for LVS Tun was because i have get very trouble with routing
over privat networkadresses.
I have get LVS NAT to run, but after some time the private netadresses
wasn't reachable in the serverset. I think i have got problems with the
routing of my provider.
So i setup up a LVS Tun Set on public ipadresses and it works fine for
me. Now i have got a response from a client he report from timeouts by
post-requests. Sadly i cant reproduce this problem in my requests.
The apache logs show me the follow error: "request failed: error reading
the headers"

After i study the LVS-Howto i found the section for MTU and package
fragmentation. I added the follow rule to my iptables. But it dont help
to solve the problem.
iptables -A OUTPUT -s VIRTUAL-IP -p tcp -m tcp --tcp-flags SYN,RST,ACK
SYN,ACK -j TCPMSS --set-mss 1440

For a better understanding of my LVS Set here are some information:

1. Im using only public ipadresses

2. my dircetor is also a realserver with 1 nic and has the follow interfaces

eth0 = public ip (not in use for the LVS)
eth0:80 = public ip (thats my VIRTUAL-IP)
lo = 127.0.0.1 (not in use for the LVS)

3. the output of ipvsadm here (2 standalone realserver and 1 local
realserver directly on the director)

IP Virtual Server version 1.2.1 (size=4096)
Prot LocalAddress:Port Scheduler Flags
-> RemoteAddress:Port Forward Weight ActiveConn InActConn
TCP VIRTUAL-IP:http rr
-> REALSERVER_IP1:http Tunnel 1 0 0
-> REALSERVER_IP2:http Tunnel 1 0 0
-> localhost.localdomain:http Local 1 0 0

4. more infos for the director
cat /proc/sys/net/ipv4/ip_forward = 1
no special route is added
the set works fine without large posts
no errors for the realserver who run directly on the director by large posts

5. the realserver with 1 nic has the follow interfaces

eth0 = public ip (the REALSERVER_IP that is list in the ipvsadm output
on director)
lo = 127.0.0.1 (not in use for the LVS)
tunl0 = VIRTUAL-IP (with no arp)

6. more infos for the realserver
cat /proc/sys/net/ipv4/ip_forward = 0
no special route is added
errors in this realservers by large posts > "request failed: error
reading the headers" also when i use the iptables command for mtu
fragmentation:
iptables -A OUTPUT -s VIRTUAL-IP -p tcp -m tcp --tcp-flags SYN,RST,ACK
SYN,ACK -j TCPMSS --set-mss 1440
The HTML-Post Test-Scripts hangs by connection on the realserver


Some Questions:
- Are my settings ok. (specially director as realserver too, use of
public ips)?
- for testing i have change my mtu on the director eth0:80 to 1480 but
this dont solve the problem
- i change also the mtu temporary on the realserver eth0 to 1480 but
this dont solve the problem too
- do i need a special routing for LVS-tun

Maybe somebody have any ideas. Im very pleased about some tips.

regards
udosa from munich


_______________________________________________
LinuxVirtualServer.org mailing list - lvs-users [at] LinuxVirtualServer
Send requests to lvs-users-request [at] LinuxVirtualServer
or go to http://lists.graemef.net/mailman/listinfo/lvs-users


sandyinchina at gmail

Apr 17, 2008, 5:51 AM

Post #2 of 3 (429 views)
Permalink
Re: [lvs-users] another lvs-tun problem with large posts (MTU and fragmentation) [In reply to]

On Thu, Apr 17, 2008 at 8:36 PM, Udo Sauer <udo [at] udosa> wrote:

> After i study the LVS-Howto i found the section for MTU and package
> fragmentation.

A fairly simple explanation of pth MTU issues:
http://www.freeswan.org/freeswan_trees/freeswan-2.06/doc/glossary.html#pathMTU

A section of this paper has the best analysis I've seen:
http://www.av8n.com/security/lisa/

--
Sandy Harris,
Nanjing, China

_______________________________________________
LinuxVirtualServer.org mailing list - lvs-users [at] LinuxVirtualServer
Send requests to lvs-users-request [at] LinuxVirtualServer
or go to http://lists.graemef.net/mailman/listinfo/lvs-users


udo at udosa

Apr 17, 2008, 9:30 AM

Post #3 of 3 (425 views)
Permalink
Re: [lvs-users] another lvs-tun problem with large posts (MTU and fragmentation) [In reply to]

Hi Sandy,

thx for quick response. I have fix the problem. The tip was in the first
link of your answer ->> check your firewall !

I have add the IP-Rule that set the mss on the end of my iptable-script.
iptables -A OUTPUT -s VIRTUAL-IP -p tcp -m tcp --tcp-flags SYN,RST,ACK
SYN,ACK -j TCPMSS --set-mss 1440

... and here was perhaps the problem with other ip-tables rules before.
After i add the line in the top off my firewall script the problem with
the timeouts by large posts was fixed.

thx to all and regards
udosa munich


Sandy Harris schrieb:
> On Thu, Apr 17, 2008 at 8:36 PM, Udo Sauer <udo [at] udosa> wrote:
>
>
>> After i study the LVS-Howto i found the section for MTU and package
>> fragmentation.
>>
>
> A fairly simple explanation of pth MTU issues:
> http://www.freeswan.org/freeswan_trees/freeswan-2.06/doc/glossary.html#pathMTU
>
> A section of this paper has the best analysis I've seen:
> http://www.av8n.com/security/lisa/
>
>


_______________________________________________
LinuxVirtualServer.org mailing list - lvs-users [at] LinuxVirtualServer
Send requests to lvs-users-request [at] LinuxVirtualServer
or go to http://lists.graemef.net/mailman/listinfo/lvs-users

Linux Virtual Server users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.