Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Search
    • Register
    • Login
    Introducing Netgate Nexus: Multi-Instance Management at Your Fingertips.

    haproxy site returns 404 on every other refresh...

    Scheduled Pinned Locked Moved Cache/Proxy
    3 Posts 2 Posters 2.0k Views 2 Watching
    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.
    • D
      DavidBrowett
      last edited by DavidBrowett

      Hi all

      I've had a pfsense server running haproxy for a while now with no problems. Until now. I have one particular website, it's running on IIS 8 (Windows Server 2012 R2). I now have a simple html page on it that says nothing more than "hello", this loads the first time I attempt it from the internet. But then if I hit refresh I get error 404. Another refresh and it loads again, and another.... another 404. I've tried waiting for various intervals for the refresh but the pattern remains the same - loads, 404, loads, 404, etc.

      No special configuration here. 1 WAN, 1 LAN, running Squid for proxy and HAproxy for reverse proxying. Both backend and frontend are bog standard basic, nothing special about their configurations.

      This site worked fine on a VERY old TMG server previously, and it works fine on the internal network, so I'm convinced it's a pfsense / haproxy configuration issue. The only other potential I can think of is that this site also hosts a .net application, maybe I'm missing something for that in HAproxy or IIS? Anyone have any ideas or experience?

      Cheers!

      P 1 Reply Last reply
      Reply Quote 0
      • P
        PiBa @DavidBrowett
        last edited by

        @davidbrowett
        Strange.. Do you have 2 frontends binding to the same port, that could give alternating results..
        Or 2 haproxy processes running? (with possibly different configs in memory if one is to old and still accepting new connections)
        Also enable haproxy log's check what it says there for each request?

        Can you share your haproxy.cfg , it can be seen at the bottom of the haproxy settings tab.

        1 Reply Last reply
        Reply Quote 0
        • D
          DavidBrowett
          last edited by DavidBrowett

          Hi PiBa, and thanks for the response. Would you believe, I have just managed to get it going. Interesting one, IIS site was missing a binding for that particular host header. Strange that it didn't work considering that it's the only site on that server and it was listening on the right port, etc, but it has made the difference to it! Lesson learned!

          1 Reply Last reply
          Reply Quote 0

          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

          With your input, this post could be even better 💗

          Register Login
          • First post
            Last post
          Copyright 2026 Rubicon Communications LLC (Netgate). All rights reserved.
          Privacy Policy · Cookie Policy