cloudflared icon indicating copy to clipboard operation
cloudflared copied to clipboard

After working for a year today I got this error Unable to reach the origin service.🐛

Open Knowix opened this issue 2 years ago • 21 comments

Describe the bug Hey guys,

I've been using Cloudflare Argo tunnel for more than a year now. I installed it by following ibracrop's video on YouTube, and it worked like a charm. But today for some reason the tunnel stopped working properly. I have no experience in this field, I only followed a YouTube video. And also I didn't push any updates or changes to my network.

I'd be grateful if someone could help me solve my problem.

This is the error message that I see:

2024-04-02T22:50:44Z INF Starting tunnel tunnelID=522e3fca-111c-44fc-9379-e143d5254a46 2024-04-02T22:50:44Z INF Version 2024.1.4 2024-04-02T22:50:44Z INF GOOS: linux, GOVersion: go1.21.5-devel-cf, GoArch: amd64 2024-04-02T22:50:44Z INF Settings: map[cred-file:/home/nonroot/.cloudflared/522e3fca-111c-44fc-9379-e143d5254a46.json credentials-file:/home/nonroot/.cloudflared/522e3fca-111c-44fc-9379-e143d5254a46.json no-autoupdate:true] 2024-04-02T22:50:44Z INF Generated Connector ID: 37222e91-dd6c-465d-942e-df7057975c6d 2024-04-02T22:50:54Z ERR Failed to fetch features, default to disable error="lookup cfd-features.argotunnel.com on 127.0.0.11:53: read udp 127.0.0.1:41168->127.0.0.11:53: i/o timeout" 2024-04-02T22:50:54Z ERR update check failed error="Get "https://update.argotunnel.com?arch=amd64&clientVersion=2024.1.4&os=linux": dial tcp: lookup update.argotunnel.com on 127.0.0.11:53: read udp 127.0.0.1:60079->127.0.0.11:53: i/o timeout" 2024-04-02T22:51:04Z WRN Unable to lookup protocol percentage. 2024-04-02T22:51:04Z INF Initial protocol http2 2024-04-02T22:51:04Z INF ICMP proxy will use 172.18.0.3 as source for IPv4 2024-04-02T22:51:04Z INF ICMP proxy will use :: as source for IPv6 2024-04-02T22:51:24Z INF Starting metrics server on 127.0.0.1:44535/metrics 2024-04-02T22:51:44Z INF Tunnel server stopped

I also tried to start the tunnel from the console where I could start it and in Cloudflare it became Healthy but then it went back to Down in a few mins.

And I see these logs in the console.

2024-04-02T22:27:19Z ERR error="Unable to reach the origin service. The service may be down or it may not be responding to traffic from cloudflared: remote error: tls: unrecognized name" connIndex=1 event=1 ingressRule=0 originService=https://192.168.2.81:18443 2024-04-02T22:27:19Z ERR Request failed error="Unable to reach the origin service. The service may be down or it may not be responding to traffic from cloudflared: remote error: tls: unrecognized name" connIndex=1 dest=https://download.knowix.pro/ event=0 ip=198.41.192.67 type=http 2024-04-02T22:27:19Z ERR error="Unable to reach the origin service. The service may be down or it may not be responding to traffic from cloudflared: remote error: tls: unrecognized name" connIndex=1 event=1 ingressRule=0 originService=https://192.168.2.81:18443 2024-04-02T22:27:19Z ERR Request failed error="Unable to reach the origin service. The service may be down or it may not be responding to traffic from cloudflared: remote error: tls: unrecognized name" connIndex=1 dest=https://download.knowix.pro/favicon.ico event=0 ip=198.41.192.67 type=http ^C2024-04-02T22:27:46Z INF Initiating graceful shutdown due to signal interrupt ... 2024-04-02T22:27:47Z INF Unregistered tunnel connection connIndex=3 event=0 ip=198.41.192.47 2024-04-02T22:27:47Z ERR Failed to serve quic connection error="Application error 0x0 (remote)" connIndex=3 event=0 ip=198.41.192.47 2024-04-02T22:27:47Z ERR Serve tunnel error error="Application error 0x0 (remote)" connIndex=3 event=0 ip=198.41.192.47 2024-04-02T22:27:47Z INF Retrying connection in up to 1s connIndex=3 event=0 ip=198.41.192.47 2024-04-02T22:27:47Z INF Unregistered tunnel connection connIndex=0 event=0 ip=198.41.200.193 2024-04-02T22:27:47Z ERR Failed to serve quic connection error="Application error 0x0 (remote)" connIndex=0 event=0 ip=198.41.200.193 2024-04-02T22:27:47Z ERR Serve tunnel error error="Application error 0x0 (remote)" connIndex=0 event=0 ip=198.41.200.193 2024-04-02T22:27:47Z INF Retrying connection in up to 1s connIndex=0 event=0 ip=198.41.200.193 2024-04-02T22:27:47Z INF Unregistered tunnel connection connIndex=1 event=0 ip=198.41.192.67 2024-04-02T22:27:47Z ERR writing finish: Application error 0x0 (remote) 2024-04-02T22:27:47Z ERR Failed to serve quic connection error="Application error 0x0 (remote)" connIndex=1 event=0 ip=198.41.192.67 2024-04-02T22:27:47Z ERR Serve tunnel error error="Application error 0x0 (remote)" connIndex=1 event=0 ip=198.41.192.67 2024-04-02T22:27:47Z INF Retrying connection in up to 1s connIndex=1 event=0 ip=198.41.192.67 2024-04-02T22:27:47Z INF Unregistered tunnel connection connIndex=2 event=0 ip=198.41.200.73 2024-04-02T22:27:47Z ERR Failed to serve quic connection error="context canceled" connIndex=2 event=0 ip=198.41.200.73 2024-04-02T22:27:47Z INF Retrying connection in up to 1s connIndex=2 event=0 ip=198.41.200.73 2024-04-02T22:27:47Z ERR no more connections active and exiting 2024-04-02T22:27:47Z INF Tunnel server stopped 2024-04-02T22:27:47Z ERR icmp router terminated error="context canceled" 2024-04-02T22:27:47Z INF Metrics server stopped

Environment and versions

  • OS: Unraid
  • Architecture: AMD
  • Version: Latest / 2024.01.03

Knowix avatar Apr 02 '24 22:04 Knowix

Did you get anywhere with this? I have pretty much the same initial error - Failed to fetch features, default to disable error="lookup cfd-features.argotunnel.com on 127.0.0.11:53: read udp 127.0.0.1:41168->127.0.0.11:53: i/o timeout"

richardcavspain avatar Apr 21 '24 06:04 richardcavspain

Same here

brenoaquino avatar May 15 '24 22:05 brenoaquino

Did you get anywhere with this? I have pretty much the same initial error - Failed to fetch features, default to disable error="lookup cfd-features.argotunnel.com on 127.0.0.11:53: read udp 127.0.0.1:41168->127.0.0.11:53: i/o timeout"

i have the same problem

souja67 avatar May 19 '24 15:05 souja67

Still not working for me :-(

richardcavspain avatar May 19 '24 17:05 richardcavspain

Was able to fix my issue. Ended up being a DNS issue. My cloudflare tunnel container was unable to resolve DNS. I manually updated my DNS servers on my Synology to point to my router for primary and google (8.8.8.8) for my secondary. Hope this helps someone.

souja67 avatar May 19 '24 18:05 souja67

Was able to fix my issue. Ended up being a DNS issue. My cloudflare tunnel container was unable to resolve DNS. I manually updated my DNS servers on my Synology to point to my router for primary and google (8.8.8.8) for my secondary. Hope this helps someone.

So in your case it was internal name resolution that was the issue? The HA box being unable to resolve argotunnel.com - right?

richardcavspain avatar May 19 '24 18:05 richardcavspain

For anyone having this issue, I managed to "fix" my installation, thanks to souja67 for the tip.

This was a DNS issue, I found that when I tried terminal inside HA, I could PING IP addresses on the Internet but not resolve their names, even though DNS, IP addresses and default gateways were setup correctly and I could access HA from within the local network. In the end (because I run HA in a VM) I backed it up, blew away the VM and set it up again from scratch, got HA running and then restored HA from backup and everything worked fine, confirming it was a VM issue, not a HA issue.

I hope this helps someone in the future :-)

richardcavspain avatar May 20 '24 20:05 richardcavspain

I use docker container in mikrotik router and got same issue, but in my server still good connect

qal1215 avatar Aug 14 '24 17:08 qal1215

My issue was DNS. I changed from Cloudflare to Google's DNS under System Setting -> Network -> Wifi Name -> DNS, flushed the cache, and restarted the Mac, and it worked. Wasted hours 🤦‍♂️

abhagsain avatar Aug 26 '24 07:08 abhagsain

I encountered the same issue with my Docker Compose file and resolved it by configuring the DNS of my tunnel container to point to my router :

  cloudflare:
    container_name: cloudflare
    image: cloudflare/cloudflared:latest
    restart: unless-stopped
    networks:
      - custom_network
    environment:
      - TUNNEL_TOKEN=${CF_TUNNEL_TOKEN}
    command: tunnel --no-autoupdate run
    dns:
      - 192.168.1.1
      - 1.1.1.1

mphel44 avatar Jan 22 '25 18:01 mphel44

I did this by changing the local DNS to 8.8.8.8

Heroor avatar Feb 23 '25 03:02 Heroor

for me restarting the server resolves the problem, restarting container doesn't, restating docker service doesnt'. i run cloudflared in docker container

`--- services: cloudflared: command: - "tunnel" - "--no-autoupdate" - "run" - "--token"

container_name: "cloudflared"
entrypoint:
  - "cloudflared"
  - "--no-autoupdate"
image: "cloudflare/cloudflared:latest"
logging:
  driver: "json-file"
  options: {}
network_mode: "bridge"
restart: "always"
deploy:
  resources:
    limits:
      memory: 128m
      cpus: "1"
dns:
  - 1.1.1.1
  - 8.8.8.8
  - 192.168.4.1`

NormanCrypt avatar Mar 01 '25 10:03 NormanCrypt

I got the same issue, and tried this K8S config as a result, however I also get a new issue..

2025-04-07T10:06:38Z ERR  error="Unable to reach the origin service. The service may be down or it may not be responding to traffic from cloudflared: dial tcp: lookup traefik on 1.1.1.1:53: no such host" connIndex=3 event=1 ingressRule=3 originService=http://traefik
2025-04-07T10:06:38Z ERR Request failed error="Unable to reach the origin service. The service may be down or it may not be responding to traffic from cloudflared: dial tcp: lookup traefik on 1.1.1.1:53: no such host" connIndex=3 dest=https://nextcloud.spidershomelab.xyz/index.php/204 event=0 ip=198.41.200.233 type=http
apiVersion: apps/v1
kind: Deployment
metadata:
  name: tunnel
  labels:
    app: tunnel
spec:
  replicas: 1
  selector:
    matchLabels:
      app: tunnel
  template:
    metadata:
      labels:
        app: tunnel
    spec:
      dnsPolicy: None
      dnsConfig:
        nameservers:
          - 1.1.1.1
          - 10.43.0.10
#        searches:
#          - default.svc.cluster.local
      hostNetwork: true
      containers:
        - name: tunnel
          image: cloudflare/cloudflared:latest
          args:
            - tunnel
            - --no-autoupdate
            - run
          env:
            - name: TUNNEL_TOKEN
              valueFrom:
                configMapKeyRef:
                  name: env
                  key: CLOUDFLARE_TUNNEL_TOKEN
      restartPolicy: Always

anyone know how i can fix this? It is supposed to ask kubedns for the ips of the services, but its only using 1.1.1.1

SpiderUnderUrBed avatar Apr 07 '25 10:04 SpiderUnderUrBed

I'm seeing this as well. I can't allow DNS to anything other than Azure in my case. Except Azure can't resolve "cfd-features.argotunnel.com".

neil-119 avatar Jun 01 '25 17:06 neil-119

Had same issue. Now i just "sudo netplan try" and everything works. Ubuntu 24.04

`crypt@nuc:/mnt/ssd/HOMELAB/cloudflared$ sudo netplan status Online state: offline DNS Addresses: 127.0.0.53 (stub) DNS Search: tail783bb.ts.net

crypt@nuc:/mnt/ssd/HOMELAB/cloudflared$ sudo netplan try Do you want to keep these settings?

Press ENTER before the timeout to accept the new configuration

Changes will revert in 110 seconds Configuration accepted.

crypt@nuc:/mnt/ssd/HOMELAB/cloudflared$ sudo netplan status Online state: online DNS Addresses: 127.0.0.53 (stub) DNS Search: tail783bb.ts.net`

Just checked on other Ubuntu 22.04 with same issue and i think it fixed it.

NormanCrypt avatar Jun 12 '25 17:06 NormanCrypt

Changing the tunnel service url from localhost to 127.0.0.1 fixed it for me. But i was already using 1.1.1.1 and 8.8.8.8 as my dns resolvers.

mkemalemdar avatar Jun 23 '25 20:06 mkemalemdar

Had this problem for hours after a week of stable uptime on my Pi. Adding 1.1.1.1 to /etc/resolv.conf solved the issue.

nameserver 127.0.0.1
nameserver 1.1.1.1

hcoxx avatar Oct 10 '25 04:10 hcoxx

Did you get anywhere with this? I have pretty much the same initial error - Failed to fetch features, default to disable error="lookup cfd-features.argotunnel.com on 127.0.0.11:53: read udp 127.0.0.1:41168->127.0.0.11:53: i/o timeout"

I have the same issue on my local k3s cluster. I have 2 replicas, one of them will always crash.

2025-10-23T00:42:41Z ERR Failed to fetch features, default to disable error="lookup cfd-features.argotunnel.com on 8.8.8.8:53: dial udp 8.8.8.8:53: i/o tim

Even after I set :

> kubectl debug -it -n cloudflared-tunnel my-cloudflared-hsgk4 --image=alpine -- sh
--profile=legacy is deprecated and will be removed in the future. It is recommended to explicitly specify a profile, for example "--profile=general".
Defaulting debug container name to debugger-vckcn.
All commands and output from this session will be recorded in container logs, including credentials and sensitive information passed through the command prompt.
If you don't see a command prompt, try pressing enter.
/ # cat /etc/resolv.conf
search cloudflared-tunnel.svc.cluster.local svc.cluster.local cluster.local tail79e65.ts.net lan
nameserver 10.43.0.10
nameserver 1.1.1.1
nameserver 8.8.8.8
options ndots:5
/ # nslookup cfd-features.argotunnel.com
Server:         1.1.1.1
Address:        1.1.1.1:53

Non-authoritative answer:

Non-authoritative answer:

The other pod works but it is unstable. Its log has :

2025-10-23T00:40:55Z ERR  error="Unable to reach the origin service. The service may be down or it may not be responding to traffic from cloudflared: dial tcp 10.43.217.162:3000: i/o timeout" connIndex=3 event=1 ingressRule=0 originService=http://rust-hello.default:3000
2025-10-23T00:40:55Z ERR Request failed error="Unable to reach the origin service. The service may be down or it may not be responding to traffic from cloudflared: dial tcp 10.43.217.162:3000: i/o timeout" connIndex=3 dest=xxxx event=0 ip=198.41.192.27 type=http

kosumic avatar Oct 23 '25 00:10 kosumic

The issue may have something to

Did you get anywhere with this? I have pretty much the same initial error - Failed to fetch features, default to disable error="lookup cfd-features.argotunnel.com on 127.0.0.11:53: read udp 127.0.0.1:41168->127.0.0.11:53: i/o timeout"

I have the same issue on my local k3s cluster. I have 2 replicas, one of them will always crash.

2025-10-23T00:42:41Z ERR Failed to fetch features, default to disable error="lookup cfd-features.argotunnel.com on 8.8.8.8:53: dial udp 8.8.8.8:53: i/o tim

Even after I set :

> kubectl debug -it -n cloudflared-tunnel my-cloudflared-hsgk4 --image=alpine -- sh
--profile=legacy is deprecated and will be removed in the future. It is recommended to explicitly specify a profile, for example "--profile=general".
Defaulting debug container name to debugger-vckcn.
All commands and output from this session will be recorded in container logs, including credentials and sensitive information passed through the command prompt.
If you don't see a command prompt, try pressing enter.
/ # cat /etc/resolv.conf
search cloudflared-tunnel.svc.cluster.local svc.cluster.local cluster.local tail79e65.ts.net lan
nameserver 10.43.0.10
nameserver 1.1.1.1
nameserver 8.8.8.8
options ndots:5
/ # nslookup cfd-features.argotunnel.com
Server:         1.1.1.1
Address:        1.1.1.1:53

Non-authoritative answer:

Non-authoritative answer:

The other pod works but it is unstable. Its log has :

2025-10-23T00:40:55Z ERR  error="Unable to reach the origin service. The service may be down or it may not be responding to traffic from cloudflared: dial tcp 10.43.217.162:3000: i/o timeout" connIndex=3 event=1 ingressRule=0 originService=http://rust-hello.default:3000
2025-10-23T00:40:55Z ERR Request failed error="Unable to reach the origin service. The service may be down or it may not be responding to traffic from cloudflared: dial tcp 10.43.217.162:3000: i/o timeout" connIndex=3 dest=xxxx event=0 ip=198.41.192.27 type=http

The argo channel issue may be caused by the liveness probe and the overwrite of /etc/resolv.conf by Tailscale. The resolv.conf in coredns is affected by tailscale so argo channel resolution is super slow -> timeout.

Use this command to check:

kubectl -n kube-system edit configmap coredns

kosumic avatar Oct 23 '25 03:10 kosumic

It seems we were experiencing the same issue with Cloudflared and encountered the "Unable to reach the origin service" (Error 530 - The origin has been unregistered from Argo Tunnel) error. I managed to fix it with the following steps:

First, I uninstalled the Cloudflared service with the command: sudo cloudflared service uninstall

After that, I reinstalled the Cloudflared service with the command: sudo cloudflared service install <YOUR_TUNNEL_ID>

This process successfully fixed the problem and the service is back to working as expected. Hopefully, this helps anyone else facing a similar issue!

KiroFyzu avatar Jan 05 '26 03:01 KiroFyzu