Issues with reconnect, promtail towards loki-distributed

Hi!

Using loki-distributed helm-chart 0.78.0 and promtail 6.15.3

Every-time i take down loki and up again Promtail cannot reconnect.
I have to restart promtail again, then it works fine again.

Output from promtail:
First i get 404 when loki closes, then when it’s up again i get 500.

`level=warn ts=2024-01-12T08:52:52.776069987Z caller=client.go:419 component=client host=` `loki.test.com` `msg="error sending batch, will retry" status=500 
tenant= error="server returned HTTP status 500 Internal Server Error 
(500): empty ring"`

Similar problems:

I have also tried to add this i promtail:

config:
  clients:
    backoff_config:
    min_period: 500ms
    max_period: 20m
    max_retries: 100

Also i can get this error in promtail:


HTTP status 404 page not found

then after loki comes up:
sending batch, will retry status=502 tenant= error"server returned HTTP status 502 Bad Gateway.

It is using the same dns name to push logs, but somehow promtail cannot reconnect. What is different with loki when it goes down and up again, “reinstalled”?

It seems that it works as it should, even though i get those errors. I still can ingest logs.