ivpn/desktop-app-cli

Unable to ping servers

Closed this issue · 4 comments

Bug report

Describe your environment

  • Device: Running it off of a USB drive that i plug into multiple laptops
  • OS name and version: Artix Linux 64 bit Rolling distro, latest updates as of Apr 22
  • IVPN app version: masterbranch (date:2021-04-22 commit:5da83001f9eda37005ba06dbeb9b9b8960a277d0)

Describe the problem

This has been going on for a long time but i decided to ask about it just now.

Pinging gives this output:

$ ivpn servers -ping
Pinging servers ...
Error: failed to ping servers

And here are the detailed logs:

Apr 22 17:54:05.958 [prtcl ] Client connected: 127.0.0.1:48212
Apr 22 17:54:06.036 [prtcl ] Connected binary (127.0.0.1:48212): '/usr/local/bin/ivpn'
Apr 22 17:54:06.036 [prtcl ] [<--] Hello
Apr 22 17:54:06.036 [prtcl ] Connected client version: '1.0' [set KeepDaemonAlone = true]
Apr 22 17:54:06.036 [prtcl ] [-->] HelloResp
Apr 22 17:54:06.036 [prtcl ] [-->] ConnectedResp
Apr 22 17:54:06.036 [frwl  ] Getting status...
Apr 22 17:54:06.037 [prtcl ] [<--] GetServers
Apr 22 17:54:06.037 [prtcl ] [-->] ServerListResp
Apr 22 17:54:06.043 [prtcl ] [<--] PingServers
Apr 22 17:54:06.043 [servc ] Servers pinging skipped due to connected state
Apr 22 17:54:06.043 [prtcl ] [-->] PingServersResp
Apr 22 17:54:06.044 [prtcl ] Client disconnected: 127.0.0.1:48212
Apr 22 17:54:06.044 [prtcl ] Current state not changing [KeepDaemonAlone=true]
Apr 22 17:54:06.048 [frwl  ]    true
Apr 22 17:54:06.048 [prttyp] ERROR types.go:48:(in github.com/ivpn/desktop-app-daemon/protocol/types.Send.func1): failed to send command to client: write tcp 127.0.0.1:37539->127.0.0.1:48212: use of closed network connection
Apr 22 17:54:08.503 [prtcl ] Client connected: 127.0.0.1:48214
Apr 22 17:54:08.579 [prtcl ] Connected binary (127.0.0.1:48214): '/usr/local/bin/ivpn'
Apr 22 17:54:08.579 [prtcl ] [<--] Hello
Apr 22 17:54:08.580 [prtcl ] Connected client version: '1.0' [set KeepDaemonAlone = true]

Steps to reproduce:




Observed Results:

  • What happened? This could be a description, log output, etc.

Expected Results:

  • What did you expect to happen?

Relevant Code:

// TODO(you): code here to reproduce the problem

Hello @GentlemansKiller
It looks like the VPN is connected when you try to ping the servers.

It has no sense to ping servers when VPN is connected. So, the daemon just skipping this operation.
Otherwise, the ping result will be relative to the server you currently connected to (not to your current location, as expected)

Hello @GentlemansKiller
It looks like the VPN is connected when you try to ping the servers.

It has no sense to ping servers when VPN is connected. So, the daemon just skipping this operation.
Otherwise, the ping result will be relative to the server you currently connected to (not to your current location, as expected)

@stenya Okay makes sense, as you said on the UI issue as well.. And also as I mentioned on the other issue, do you think this could be implemented as an option to ping during connection? Let me know your thoughts

@GentlemansKiller What is the use case for it?
Pinging the servers in the connected state says nothing about real latency to your current location.

@stenya oh ok, so the app is not able to ping from my physical location to those servers while the VPN is connected, got it. Sorry, i guess i didnt understand that part :) Yeah, in that case, if the app can't do that, then there would be no use, true.