Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue when traefik.backend.loadbalancer.swarm=true #2138

Closed
thibaultmeyer opened this issue Sep 18, 2017 · 5 comments
Closed

Issue when traefik.backend.loadbalancer.swarm=true #2138

thibaultmeyer opened this issue Sep 18, 2017 · 5 comments

Comments

@thibaultmeyer
Copy link

thibaultmeyer commented Sep 18, 2017

Do you want to request a feature or report a bug?

What did you do?

Running 2+ backends (Docker swarm 17.06) with the label traefik.backend.loadbalancer.swarm=true

What did you expect to see?

Get 1 frontend with 2+ backends

What did you see instead?

1 frontend with only 1 backend.

image

PS : I have try with whoiam image and scale = 3, the LB don't working too.

Output of traefik version:

Version: v1.4.0-rc2
Codename: roquefort
Go version: go1.9
Built: 2017-09-08_07:31:37PM
OS/Arch: linux/amd64

What is your environment & configuration (arguments, toml, provider, platform, ...)?

###############################################################################
## Entry points
# ~~~~~
defaultEntryPoints = ["http", "https"]
[entryPoints]
  [entryPoints.http]
  address = ":80"
    [entryPoints.http.redirect]
    entryPoint = "https"
  [entryPoints.https]
  address = ":443"
  [[entryPoints.https.tls.certificates]]
    CertFile = "/etc/ssl/xxxx.io.crt"
    KeyFile = "/etc/ssl/xxxx.io.key"
  [[entryPoints.https.tls.certificates]]
    CertFile = "/etc/ssl/yyyy.ski.crt"
    KeyFile = "/etc/ssl/yyyy.ski.key"


[web]

# Web administration port
address = ":8080"

# Set REST API to read-only mode
ReadOnly = true

# Authentication
# https://websistent.com/tools/htdigest-generator-tool/
[web.auth.digest]
users = [
  "xxxx:traefik:xxxxx"
]


[docker]

# Docker server endpoint. Can be a tcp or a unix socket endpoint.
endpoint = "unix:///var/run/docker.sock"

# Default domain used.
# Can be overridden by setting the "traefik.domain" label on a container.
domain = "xxxx.io"

# Enable watch docker changes
watch = true

# Expose containers by default in traefik
# If set to false, containers that don't have `traefik.enable=true` will be ignored
exposedbydefault = false

# Use Swarm Mode services as data provider
swarmmode = true


[healthcheck]

# Set the default health check interval. Will only be effective if health check
# paths are defined. Given provider-specific support, the value may be
# overridden on a per-backend basis.
# Can be provided in a format supported by [time.ParseDuration](https://golang.org/pkg/time/#ParseDuration) or as raw
# values (digits). If no units are provided, the value is parsed assuming
# seconds
interval = "15s"


[accessLog]

Extra

Everything is working when traefik.backend.loadbalancer.swarm is set to false.

@thibaultmeyer thibaultmeyer changed the title WebUI issue when traefik.backend.loadbalancer.swarm=true Issue when traefik.backend.loadbalancer.swarm=true Sep 18, 2017
@benjamin2k
Copy link

Hello

I have the same problem here, random error 502. I tried to set the value to false, but it does not solve the bug.

It's totally random… There are no specific "patterns" giving those errors :/ And as a +, the LB is routing the domain to the wrong service… Ex. domain1.com give domain2.com (and it create some ssl issues…)

@benjamin2k
Copy link

benjamin2k commented Sep 22, 2017

The typical error on the traefik logs are the following

level=warning msg="Error forwarding to http://172.42.0.14:80, err: context canceled" 
level=warning msg="Error copying upstream response body: write tcp 10.255.0.6:80->10.255.0.2:48774: write: connection reset by peer 2017/09/21 14:54:52 server.go:2753: http: multiple response.WriteHeader calls

@caseyrichins
Copy link

Any update on this issue, i've experienced this issue as well. When have multiple backends are defined only shows one and there is uncertnity if the backends are truly taking traffic and available.

@ldez ldez added kind/bug/possible a possible bug that needs analysis before it is confirmed or fixed. and removed status/0-needs-triage labels Oct 5, 2017
@SantiMunoz
Copy link

Same problem here as @benjamin2k.
Using Traefik 1.4.0 and Docker 17.09.0-ce.

I have a docker swarm with several services, with 3 replicas each one, but I'm only noticing this problem in a couple of services and it seems totally random. Some times gives 502 or routes to the wrong service.

If I can provide you more information please tell me!

Next week I will try Traefik 1.4.2.

@ldez ldez added this to the 1.4 milestone Nov 3, 2017
@ldez ldez added kind/bug/confirmed a confirmed bug (reproducible). and removed kind/bug/possible a possible bug that needs analysis before it is confirmed or fixed. labels Nov 3, 2017
@nmengin
Copy link
Contributor

nmengin commented Nov 3, 2017

@SantiMunoz Indeed this problem seems to be fixed by the PR #2314 which is merged in version 1.4.2.

I close the issue.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

7 participants