最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

connection - NGROK failing to dial ngrok server - invalid argument - Stack Overflow

programmeradmin2浏览0评论

I've been using NGROK on my TrueNAS Jail (FreeBSD) for a couple of years (4+) and it always worked fine. I have a free account (that generates random URLs) and my internet access sits behind 2 LTE connections and a load balancer.

Recently it stopped working so I took the chance to update to the latest version as usually these are the reasons why it stops working.

For simplicity, I started over: removed ngrok and the yml file and started from scratch.

  1. Downloaded and extracted the latest FreeBSD version (3.21.0)
wget ngrok-v3-stable-freebsd-amd64.tgz
tar -xvzf ngrok-v3-stable-freebsd-amd64.tgz
  1. Added my authtoken (taken from my account on their website):
./ngrok config add-authtoken <token here>
Authtoken saved to configuration file: /root/.config/ngrok/ngrok.yml
  1. Tested simple runs like the documentation says:
./ngrok http http://localhost:8080
./ngrok tcp 22
  1. Got the result for both:
ngrok                                                                                                                                                                                                      (Ctrl+C to quit)

Session Status                reconnecting (failed to dial ngrok server with address "connect.ngrok-agent:443": invalid argument)
Version                       3.21.0
Web Interface                 http://127.0.0.1:4040

Connections                   ttl     opn     rt1     rt5     p50     p90
                              0       0       0.00    0.00    0.00    0.00

This is the result of the diagnose command:

./ngrok diagnose
Testing ngrok connectivity...

Internet Connectivity
  Name Resolution                           [ OK ]
  TCP                                       [ OK ]
  TLS                                       [ OK ]
Localhost Connectivity
  Name Resolution                           [ OK ]
Ngrok Connectivity - Region: Auto (lowest latency)
  Name Resolution                           [ OK ]
  TCP                                       [ OK ]
  TLS                                       [ OK ]
  Tunnel Protocol                           [ OK ]
Successfully established ngrok connection! (region: 'eu', latency: 56.114596ms)

The result is always the same even if I use my older config file, and even if I set the ingress address to something else, example:

version: "3"
agent:
  authtoken: <token here>
  connect_url: tunnel.eu.ngrok:443

I get the same "invalid argument" message, just with the new URL.

Any ideas what could be wrong? I dont seem to be doing anything wrong.

I've been using NGROK on my TrueNAS Jail (FreeBSD) for a couple of years (4+) and it always worked fine. I have a free account (that generates random URLs) and my internet access sits behind 2 LTE connections and a load balancer.

Recently it stopped working so I took the chance to update to the latest version as usually these are the reasons why it stops working.

For simplicity, I started over: removed ngrok and the yml file and started from scratch.

  1. Downloaded and extracted the latest FreeBSD version (3.21.0)
wget ngrok-v3-stable-freebsd-amd64.tgz
tar -xvzf ngrok-v3-stable-freebsd-amd64.tgz
  1. Added my authtoken (taken from my account on their website):
./ngrok config add-authtoken <token here>
Authtoken saved to configuration file: /root/.config/ngrok/ngrok.yml
  1. Tested simple runs like the documentation says:
./ngrok http http://localhost:8080
./ngrok tcp 22
  1. Got the result for both:
ngrok                                                                                                                                                                                                      (Ctrl+C to quit)

Session Status                reconnecting (failed to dial ngrok server with address "connect.ngrok-agent:443": invalid argument)
Version                       3.21.0
Web Interface                 http://127.0.0.1:4040

Connections                   ttl     opn     rt1     rt5     p50     p90
                              0       0       0.00    0.00    0.00    0.00

This is the result of the diagnose command:

./ngrok diagnose
Testing ngrok connectivity...

Internet Connectivity
  Name Resolution                           [ OK ]
  TCP                                       [ OK ]
  TLS                                       [ OK ]
Localhost Connectivity
  Name Resolution                           [ OK ]
Ngrok Connectivity - Region: Auto (lowest latency)
  Name Resolution                           [ OK ]
  TCP                                       [ OK ]
  TLS                                       [ OK ]
  Tunnel Protocol                           [ OK ]
Successfully established ngrok connection! (region: 'eu', latency: 56.114596ms)

The result is always the same even if I use my older config file, and even if I set the ingress address to something else, example:

version: "3"
agent:
  authtoken: <token here>
  connect_url: tunnel.eu.ngrok:443

I get the same "invalid argument" message, just with the new URL.

Any ideas what could be wrong? I dont seem to be doing anything wrong.

Share Improve this question asked Mar 19 at 15:56 Vasco BaptistaVasco Baptista 6832 gold badges8 silver badges15 bronze badges 1
  • The error says invalid argument. Are you providing any additional arguments? Also, if you have any ngrok config file already, delete them. If you don't have any problem reconnecting, then you could also consider pinggy.io – Bishakh Ghosh Commented Mar 20 at 10:37
Add a comment  | 

1 Answer 1

Reset to default 0

Found the source and a solution.

My FreeBSD jail was based on release 12.3.
I have created a new jail based on 13.5 and it worked fine.

I assume it could have been caused by an incompatibility with an older version, possibly due to some dependency.

发布评论

评论列表(0)

  1. 暂无评论