# Wireguard Connection handshake not completing

**URL:** <https://forum.pritunl.com/t/wireguard-connection-handshake-not-completing/662>\
**Category:** Pritunl VPN\
**Created:** [January 6, 2023, 6:29am UTC](https://forum.pritunl.com/t/wireguard-connection-handshake-not-completing/662 "2023-01-06T06:29:05Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![atwskris](https://forum.pritunl.com/letter_avatar_proxy/v4/letter/a/bc8723/32.png) [@atwskris](https://forum.pritunl.com/u/atwskris)\
**Post date:** [January 6, 2023, 6:29am UTC](https://forum.pritunl.com/t/wireguard-connection-handshake-not-completing/662/1 "2023-01-06T06:29:05Z")

</div>

Hi,

I have set up wireguard on the server and client side and have the blue button for wireguard available. When trying to connect it gets an ip of the wireguard subnet, however after 5 seconds it says the handshake did not complete. After 3 attempts it says the server is offline.

How can I fix the issue with the handshake?

Thanks!  
Kris

---

<div class="post-metadata">

**Author:** ![zach](https://forum.pritunl.com/user_avatar/forum.pritunl.com/zach/32/1105_2.png) [@zach](https://forum.pritunl.com/u/zach)\
**Post date:** [January 6, 2023, 8:49am UTC](https://forum.pritunl.com/t/wireguard-connection-handshake-not-completing/662/2 "2023-01-06T08:49:23Z")

</div>

This is likely a configuration issue with the load balancer. If a load balancer is used the server must have a replication count equal to or greater than the number of hosts attached. Any host that is online must be replicating the server to be ready to accept the request from the load balancer.

---

<div class="post-metadata">

**Author:** ![atwskris](https://forum.pritunl.com/letter_avatar_proxy/v4/letter/a/bc8723/32.png) [@atwskris](https://forum.pritunl.com/u/atwskris)\
**Post date:** [January 7, 2023, 9:03pm UTC](https://forum.pritunl.com/t/wireguard-connection-handshake-not-completing/662/3 "2023-01-07T21:03:05Z")

</div>

Ok, I have reduced the LB down to only point to a single instance and updated the server config to match. The handshake still fails. I am using the HA Proxy config from the docs.

Are there some other options I can look into to solve this?

Thanks!  
Kris

---

<div class="post-metadata">

**Author:** ![zach](https://forum.pritunl.com/user_avatar/forum.pritunl.com/zach/32/1105_2.png) [@zach](https://forum.pritunl.com/u/zach)\
**Post date:** [January 8, 2023, 12:21am UTC](https://forum.pritunl.com/t/wireguard-connection-handshake-not-completing/662/4 "2023-01-08T00:21:36Z")

</div>

What error is shown in the service logs from the _View Logs_ in the top right menu?

---

<div class="post-metadata">

**Author:** ![atwskris](https://forum.pritunl.com/letter_avatar_proxy/v4/letter/a/bc8723/32.png) [@atwskris](https://forum.pritunl.com/u/atwskris)\
**Post date:** [January 8, 2023, 10:15pm UTC](https://forum.pritunl.com/t/wireguard-connection-handshake-not-completing/662/5 "2023-01-08T22:15:08Z")

</div>

There are the logs right from the server:

> [Host-12] 2023-01-08 13:53:01 User connected wg user\_id=637beddaa7703884b8ad7ec8  
> [Host-12] 2023-01-08 13:53:01 User disconnected user\_id=637beddaa7703884b8ad7ec8  
> [Host-12] 2023-01-08 13:53:21 User connected wg user\_id=637beddaa7703884b8ad7ec8  
> [Host-12] 2023-01-08 13:53:21 User disconnected user\_id=637beddaa7703884b8ad7ec8  
> [Host-12] 2023-01-08 13:53:42 User connected wg user\_id=637beddaa7703884b8ad7ec8  
> [Host-12] 2023-01-08 13:53:42 User disconnected user\_id=637beddaa7703884b8ad7ec8

These are the logs from the system logs:

> [Host-12][2023-01-08 13:55:47,376][INFO] Authenticating user  
> factors = [“pin”]  
> [Host-12][2023-01-08 13:56:07,871][INFO] Authenticating user  
> factors = [“pin”]  
> [Host-12][2023-01-08 13:56:28,305][INFO] Authenticating user  
> factors = [“pin”]  
> [Host-12][2023-01-08 13:56:49,181][INFO] Authenticating user  
> factors = [“pin”]  
> [Host-12][2023-01-08 13:57:11,118][INFO] Authenticating user  
> factors = [“pin”]  
> [Host-12][2023-01-08 13:57:31,819][INFO] Authenticating user  
> factors = [“pin”]  
> [Host-12][2023-01-08 13:57:52,344][INFO] Authenticating user  
> factors = [“pin”]

Interestingly I noticed this as well:

> [Host-12][2023-01-08 13:50:25,016][INFO] Starting vpn server  
> server\_id = “637c5ff9a7703884b8adc0d2”  
> instance\_id = “63bb3aa17c3a2cab1ea28f80”  
> instances =   
> instances\_count = 0  
> route\_count = 0  
> network = “192.168.222.0/24”  
> network6 = “fd00:c0a8:de00::/64”  
> dynamic\_firewall = false  
> host\_id = “b608fa79ac0e4bc0b98a6235084c58ed”  
> host\_address = “10.30.1.12”  
> host\_address6 = “fe80::703c:fcff:fe36:3df6”  
> host\_networks = [“10.10.0.0/16”, “10.30.1.0/27”, “10.50.3.0/24”, “10.20.4.0/27”]  
> cur\_timestamp = “2023-01-08 21:50:25.015450”  
> libipt = false

The network line only contains the non-wireguard network… the wireguard subnet is 192.168.211.0/24

---

<div class="post-metadata">

**Author:** ![atwskris](https://forum.pritunl.com/letter_avatar_proxy/v4/letter/a/bc8723/32.png) [@atwskris](https://forum.pritunl.com/u/atwskris)\
**Post date:** [January 8, 2023, 10:20pm UTC](https://forum.pritunl.com/t/wireguard-connection-handshake-not-completing/662/6 "2023-01-08T22:20:26Z")

</div>

Logs from the Client Logs:

> RequestError: Request: Timeout error  
> RequestError: Request: Timeout error  
> at ClientRequest.eval (webpack-internal:///./app/Request.js:170:31)  
> at ClientRequest.emit (node:events:513:28)  
> at TLSSocket.emitRequestTimeout (node:\_http\_client:814:9)  
> at Object.onceWrapper (node:events:627:28)  
> at TLSSocket.emit (node:events:525:35)  
> at Socket.\_onTimeout (node:net:526:8)  
> at listOnTimeout (node:internal/timers:559:17)  
> at process.processTimers (node:internal/timers:502:7)  
> [2023-1-7 13:27:25][ERROR] Profiles: Failed to sync profile configuration  
> RequestError: Request: Timeout error  
> RequestError: Request: Timeout error  
> at ClientRequest.eval (webpack-internal:///./app/Request.js:170:31)  
> at ClientRequest.emit (node:events:513:28)  
> at TLSSocket.emitRequestTimeout (node:\_http\_client:814:9)  
> at Object.onceWrapper (node:events:627:28)  
> at TLSSocket.emit (node:events:525:35)  
> at Socket.\_onTimeout (node:net:526:8)  
> at listOnTimeout (node:internal/timers:559:17)  
> at process.processTimers (node: internal/timers:502:7)

---

<div class="post-metadata">

**Author:** ![zach](https://forum.pritunl.com/user_avatar/forum.pritunl.com/zach/32/1105_2.png) [@zach](https://forum.pritunl.com/u/zach)\
**Post date:** [January 9, 2023, 3:01am UTC](https://forum.pritunl.com/t/wireguard-connection-handshake-not-completing/662/7 "2023-01-09T03:01:52Z")

</div>

These are not the correct logs, there is a selection in the client log view that allows selecting the service logs.

---

<div class="post-metadata">

**Author:** ![atwskris](https://forum.pritunl.com/letter_avatar_proxy/v4/letter/a/bc8723/32.png) [@atwskris](https://forum.pritunl.com/u/atwskris)\
**Post date:** [January 9, 2023, 3:48am UTC](https://forum.pritunl.com/t/wireguard-connection-handshake-not-completing/662/8 "2023-01-09T03:48:11Z")

</div>

These service logs from the client?

> C:/Program Files/Go/src/runtime/asm\_amd64.s:1594 +0x8771e0  
> [2022-11-22 21:59:54][ERRO] ▶ profile: Failed to push profile log output ◆ output=“2022-11-22 21:59:54 Server poll timeout, restarting”  
> log: Failed to rotate profile log file  
> rename C:\ProgramData\Pritunl\Profiles\616330449522a755.log C:\ProgramData\Pritunl\Profiles\616330449522a755.log.1: The process cannot access the file because it is being used by another process.  
> ORIGINAL STACK TRACE:  
> [github.com/pritunl/pritunl-client-electron/service/log.ProfilePushLog](http://github.com/pritunl/pritunl-client-electron/service/log.ProfilePushLog)  
> C:/Users/Windows/go/src/github.com/pritunl/pritunl-client-electron/service/log/profile.go:58 +0xd2fe25  
> [github.com/pritunl/pritunl-client-electron/service/profile.(\*Profile).pushOutput](http://github.com/pritunl/pritunl-client-electron/service/profile.(*Profile).pushOutput)  
> C:/Users/Windows/go/src/github.com/pritunl/pritunl-client-electron/service/profile/profile.go:836 +0xd479f0  
> [github.com/pritunl/pritunl-client-electron/service/profile.(\*Profile).parseLine](http://github.com/pritunl/pritunl-client-electron/service/profile.(*Profile).parseLine)  
> C:/Users/Windows/go/src/github.com/pritunl/pritunl-client-electron/service/profile/profile.go:848 +0xd48045  
> [github.com/pritunl/pritunl-client-electron/service/profile.(\*Profile).startOvpn.func3](http://github.com/pritunl/pritunl-client-electron/service/profile.(*Profile).startOvpn.func3)  
> C:/Users/Windows/go/src/github.com/pritunl/pritunl-client-electron/service/profile/profile.go:1567 +0xd4c63b  
> runtime.goexit  
> C:/Program Files/Go/src/runtime/asm\_amd64.s:1594 +0x8771e0  
> [2022-11-22 21:59:54][ERRO] ▶ profile: Failed to push profile log output ◆ output=“2022-11-22 21:59:54 SIGUSR1[soft,server\_poll] received, process restarting”  
> log: Failed to rotate profile log file  
> rename C:\ProgramData\Pritunl\Profiles\616330449522a755.log C:\ProgramData\Pritunl\Profiles\616330449522a755.log.1: The process cannot access the file because it is being used by another process.  
> ORIGINAL STACK TRACE:  
> [github.com/pritunl/pritunl-client-electron/service/log.ProfilePushLog](http://github.com/pritunl/pritunl-client-electron/service/log.ProfilePushLog)  
> C:/Users/Windows/go/src/github.com/pritunl/pritunl-client-electron/service/log/profile.go:58 +0xd2fe25  
> [github.com/pritunl/pritunl-client-electron/service/profile.(\*Profile).pushOutput](http://github.com/pritunl/pritunl-client-electron/service/profile.(*Profile).pushOutput)  
> C:/Users/Windows/go/src/github.com/pritunl/pritunl-client-electron/service/profile/profile.go:836 +0xd479f0  
> [github.com/pritunl/pritunl-client-electron/service/profile.(\*Profile).parseLine](http://github.com/pritunl/pritunl-client-electron/service/profile.(*Profile).parseLine)  
> C:/Users/Windows/go/src/github.com/pritunl/pritunl-client-electron/service/profile/profile.go:848 +0xd48045  
> [github.com/pritunl/pritunl-client-electron/service/profile.(\*Profile).startOvpn.func3](http://github.com/pritunl/pritunl-client-electron/service/profile.(*Profile).startOvpn.func3)  
> C:/Users/Windows/go/src/github.com/pritunl/pritunl-client-electron/service/profile/profile.go:1567 +0xd4c63b  
> runtime.goexit  
> C:/Program Files/Go/src/runtime/asm\_amd64.s:1594 +0x8771e0  
> [2022-11-22 21:59:54][ERRO] ▶ profile: Failed to push profile log output ◆ output=“2022-11-22 21:59:54 Outgoing Control Channel Authentication: Using 160 bit message hash ‘SHA1’ for HMAC authentication”  
> log: Failed to rotate profile log file  
> rename C:\ProgramData\Pritunl\Profiles\616330449522a755.log C:\ProgramData\Pritunl\Profiles\616330449522a755.log.1: The process cannot access the file because it is being used by another process.  
> ORIGINAL STACK TRACE:  
> [github.com/pritunl/pritunl-client-electron/service/log.ProfilePushLog](http://github.com/pritunl/pritunl-client-electron/service/log.ProfilePushLog)  
> C:/Users/Windows/go/src/github.com/pritunl/pritunl-client-electron/service/log/profile.go:58 +0xd2fe25  
> [github.com/pritunl/pritunl-client-electron/service/profile.(\*Profile).pushOutput](http://github.com/pritunl/pritunl-client-electron/service/profile.(*Profile).pushOutput)  
> C:/Users/Windows/go/src/github.com/pritunl/pritunl-client-electron/service/profile/profile.go:836 +0xd479f0  
> [github.com/pritunl/pritunl-client-electron/service/profile.(\*Profile).parseLine](http://github.com/pritunl/pritunl-client-electron/service/profile.(*Profile).parseLine)  
> C:/Users/Windows/go/src/github.com/pritunl/pritunl-client-electron/service/profile/profile.go:848 +0xd48045  
> [github.com/pritunl/pritunl-client-electron/service/profile.(\*Profile).startOvpn.func3](http://github.com/pritunl/pritunl-client-electron/service/profile.(*Profile).startOvpn.func3)  
> C:/Users/Windows/go/src/github.com/pritunl/pritunl-client-electron/service/profile/profile.go:1567 +0xd4c63b  
> runtime.goexit  
> C:/Program Files/Go/src/runtime/asm\_amd64.s:1594 +0x8771e0
