Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    OpenVPN TCP port 443 bad performance

    Scheduled Pinned Locked Moved OpenVPN
    15 Posts 5 Posters 8.0k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • K
      Krome
      last edited by

      Hi,

      Thanks for your answer!
      The web gui runs on port 80.
      The only package I've added is OpenVPN client export utility.

      1 Reply Last reply Reply Quote 0
      • K
        kejianshi
        last edited by

        Try it on UDP unless you don't like UDP.

        I'm not sure what is causing this with your setup.  I don't get bad results here.

        1 Reply Last reply Reply Quote 0
        • D
          doktornotor Banned
          last edited by

          Pretty much convinced it's related to the virtualization.

          1 Reply Last reply Reply Quote 0
          • K
            kejianshi
            last edited by

            Yeah - I also have that strong inclination to believe its a visualization issue.  However, I'm not sure what kind. My VMs also behave alot better than that.  Maybe he gave it not nearly enough memory and its using swap for RAM.  I don't know.  I've never had one misbehave that way.

            1 Reply Last reply Reply Quote 0
            • K
              Krome
              last edited by

              @kejianshi:

              Try it on UDP unless you don't like UDP.

              I'm not sure what is causing this with your setup.  I don't get bad results here.

              I need to use TCP in order to bypass some firewalls. :)

              @kejianshi:

              Yeah - I also have that strong inclination to believe its a visualization issue.  However, I'm not sure what kind. My VMs also behave alot better than that.  Maybe he gave it not nearly enough memory and its using swap for RAM.  I don't know.  I've never had one misbehave that way.

              I gave 8vcpu and 4Gb of RAM to Pfsense but same result :(

              1 Reply Last reply Reply Quote 0
              • K
                Krome
                last edited by

                I've tried too with VIRTIO drivers in Pfsense but there is no improvement.

                1 Reply Last reply Reply Quote 0
                • jimpJ
                  jimp Rebel Alliance Developer Netgate
                  last edited by

                  @Krome:

                  50 views and no reply?

                  50 google/yahoo/bing bots hit the thread and you wonder why they don't respond? :-)
                  Not all views are human, and if someone can't help, they wouldn't reply. You can't judge anything by thread views.

                  VPN performance on TCP is going to be bad if there is any notable loss along the way. Any loss will be compounded because TCP connections will retransmit to ensure data gets to the other side. So if the tunnel loses a packet, it will retransmit, meanwhile the client inside the tunnel also lost a packet and will retransmit, and then the retransmits of the client get retransmitted by the tunnel, etc, etc.

                  Until you try it on UDP to eliminate that as a potential cause, the rest is pure speculation though.

                  There isn't any general issue with OpenVPN and virtualization, but encryption tends to be CPU-bound so if there isn't much CPU to spare, it could be slow.

                  What does "top -aSH" show at the shell while doing a performance test? It would help narrow down where the bottleneck is, if it's CPU/resource-related.

                  Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

                  Need help fast? Netgate Global Support!

                  Do not Chat/PM for help!

                  1 Reply Last reply Reply Quote 0
                  • K
                    Krome
                    last edited by

                    Hi,
                    Thank you for your answer.

                    A top -aSH during a performance test shows this output :

                    last pid: 52778;  load averages:  0.16,  0.08,  0.02                                                                                                                                up 0+03:43:44  14:43:22
                    127 processes: 9 running, 90 sleeping, 28 waiting
                    CPU:  0.0% user,  0.0% nice,  0.7% system,  0.4% interrupt, 98.8% idle
                    Mem: 57M Active, 15M Inact, 105M Wired, 364K Cache, 98M Buf, 1814M Free
                    Swap: 4096M Total, 4096M Free

                    Seems it's not CPU/resources related :(

                    1 Reply Last reply Reply Quote 0
                    • D
                      doktornotor Banned
                      last edited by

                      I've seen this kind of setup traffic-shaped with a 3G ISP… Not kidding. Almost unusable.

                      1 Reply Last reply Reply Quote 0
                      • K
                        Krome
                        last edited by

                        In my case I'm using this setup behind a fiber connection  ;)

                        1 Reply Last reply Reply Quote 0
                        • K
                          Krome
                          last edited by

                          Disabling tcp.inflight mode has strongly increased performances in TCP 443.
                          Now, I'm getting around 80 Mb/s via the tunnel.
                          The Pfsense is behind a 1 Gb/s connection to the Internet, and at home I've got a fiber connection ~200 Mb/s download, are there some tunables to increase the bandwidth again ?

                          Thanks  :)
                          Alex

                          1 Reply Last reply Reply Quote 0
                          • G
                            Guldil
                            last edited by

                            ok i confirm the workaround.

                            For an OpenVPN in TCP 443 on pfsense 2.1.3 i have to disable TCP Inflight Mode.

                            If not, i have only 1.3 Mbit, without, i have 12 Mbit !

                            1 Reply Last reply Reply Quote 0
                            • First post
                              Last post
                            Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.