Where communities thrive

  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
Repo info
Marvin Pascual
I'm sorry but I can't find in the documentation how to configure multiple backends on a single gobetween
Illarion Kovalchuk
see discovery section
Marvin Pascual
gobetween will be listening on a single HTTPS port. How can I differentiate between different backend services? How gobetween decides that the incoming traffic is for backendA and not for backendB, and so on and so forth?
Illarion Kovalchuk
using sni

kind = "static"

static_list = [ # (required) [

"localhost:8000 weight=5", # "<host>:<port> weight=<int>" weight=1 by default

"localhost:8001 sni=www.foo.com" # ]


sorry for formatting, it is hard to copy paste examples using phone
take a look at config.toml
Dear community, i'm setting up GoBetween 0.6 under Win2012 r2 core. We have a issue in balancing 2 web servers ad the developer asked if possible to set affinty / persistence. can someone help with this item cos i did not find anything on GoBetween docs . Thank You in advance
Hilko Lantinga
I've got a TCP/UDP service with port sharing. Is there a way to let UDP follow the TCP persistence?
Hi, I'm proxying UDP, with no healthchecks and both client_ and backend_idle_timeouts set to 1m. I have two servers configured statically. I notice if I stop the service on one of them, gobetween notices within a few seconds and starts sending the traffic to the other one. The error logged is (udp/server/session): Failed to read from backend: read udp> read: connection refused. This is great, I'm just wondering what specifically the failover behavior is. Since it's UDP there's no session or ACKs, etc to keep track of at the transport layer, and I'm not sure what connection refused means in the context of UDP. Thanks.
I think I can answer my own question: the read from the udp connection failed because it received an ICMP port unreachable message on it, because traffic was being sent to the backend on the closed port, which responded with the icmp
which prompts gobetween to close that session and try again on the other server
Encountering an issue with debug logging statements in v0.6.1 yyyar/gobetween#202
Shantanu Gadgil
Yay! 0.7.0 released! :D
Question regarding tls termination: is mutual tls supporter? Are there plans to support certificate revocation lists?
I'm not seeing actual roundrobin UDP
with a stream- it looks like it picks a backend host and delivers all packets to it
I assume it thinks it is a stream and delivers to the first host it picks.
I'm wondering if I can force it to cycle destinations to do true load balancing rather than trying to some kind of session-based load balancing..
Craig Sayler
can gobetween be installed in a external LB infront of the master node API's?
Craig Sayler
My company is looking at using you as a load balancer for our internal k8s installation. i have a meeting soon and would love to get a answer!
Shantanu Gadgil
@csayler Gobetween can definitely used as frontend LB. By "external", I assume you mean "public facing" ?
BTW, have checked the wiki at: https://github.com/yyyar/gobetween/wiki
in case you have more queries, it would be good to know about your setup details :)
Eli Sarver
Hi. Has anyone had success with AMQP behind gobetween? I've tried using gb directly over three rabbitmq servers in hash1 mode, but I'm getting odd errors in response. I can proxy with amqproxy fine, but that solution doesn't handle multiple backends, so I thought I'd bridge the two to get some sort of HA to my proxy (running 3 nodes within a kubernetes cluster)
Illarion Kovalchuk
Hi @elisarver . Can you please show your config?
Hey guys, I've just downloaded the latest version of gobetween. I then pretty much used the default provided config to test load balancing to a couple websphere app instances I already had running. however, when hitting the load balancer I am actually redirected to the particular WAS instance URL, which is obviously not what I wanted. I couldn't find anything in the documentation in relation to this, is that expected behaviour?
FYI, I found out what the problem was. Websphere itself was redirecting. This article is what I had to do to fix it https://www-01.ibm.com/support/docview.wss?uid=swg21569667

Hello All,

Can we setup MSSQL Mirrored DB for failover in GoBetween?
If the primary database is failed all request should move to secondary IP

Justin Butterworth
Hi Guys, has anyone had any luck with the exec health check in windows? I have a really simple scenario which is more failover then load balance, I'm using a batch file and curl to check which site is active but whatever "expected output" I put in the config and the bat file it's always "unexpected" - batch file copies the example in the documentation albeit with my value
@echo off
curl -o nul --silent --head --fail -Is http://%1/
echo|set /p Dummy="DOWN"
echo|set /p Dummy="UP"
and the healthcheck is
kind = "exec"
interval = "10s"
timeout = "2s"
exec_command ="C:\myscript\gobetween\healthcheck\exec_healthcheck.bat" # (required) command to execute
exec_expected_positive_output = "UP" # (required) expected output of command in case of success
exec_expected_negative_output = "DOWN" # (required) expected output of command in case of failure
status is always

2019-06-20 07:07:37 [WARNI] (healthcheck/exec): Unexpected output: "UP"

2019-06-20 07:07:38 [WARNI] (healthcheck/exec): Unexpected output: "DOWN"

2019-06-20 07:07:47 [WARNI] (healthcheck/exec): Unexpected output: "UP"

2019-06-20 07:07:48 [WARNI] (healthcheck/exec): Unexpected output: "DOWN"

so it's working and it's seeing it but I can't get the output to match, tried quoting, unquoting etc
Nick Doikov
try to use numerical values for up (1) and down (0)
Illarion Kovalchuk
why do you do this weird echo | set /p thing?
why not jist echo "UP" or echo "DOWN" ?
if the echo is adding a newline character then it will break it
i use "0" and "1", my batch file calls a powershell script which then does a "Write-Host '0' -NoNewLine" or "Write-Host '1' -NoNewLine" depending on the server health
Illarion Kovalchuk
So, as conclusion, it does not matter is it '0' or 'DOWN' - the problem is probably the extra newline
Wait, we got it
your script outputs "UP" with "
including quotation symbols
Yaroslav Pogrebnyak
Yep, from source: log.Warn("Unexpected output: ", out)
so "UP" does not match with UP :-)
So somehow remove quotes around UP and DOWN from healthcheck script output and it should fix the issue :-)
Illarion Kovalchuk
I am not using windows, so can't check, but as I understand, you need to replace echo | set ... with just echo UP
and echo DOWN
I'm a newbie. This's first time I use gobetween. I want to config sample Load balancing for two webservice, which request come from domain: mydomain.com to IP of server installed gobetween. But I can't see any documentation for it. I'm setting on my windows server 2012. I really need your help, are there anyone who can help me?
Thanks so much!
Illarion Kovalchuk
Hi! You can try use default config. It is the main source of examples
Shantanu Gadgil
@Miunh for experiments sake, I would recommend using the gobetween in binary form and for test backend I can recommend using gowebhello.
you should be able to get a very simple setup going on a single machine, before going on to bigger things :)