Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    WireGuard not working :( Handshake for peer1 did not complete after 5 seconds

    Scheduled Pinned Locked Moved WireGuard
    1 Posts 1 Posters 760 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • R
      Redas
      last edited by

      Hello, I installed WireGuard on Ubuntu machine (I actually tried 2 different servers, one from Oracle, and another from Google, same thing), and trying to connect with Windows 10 machine, by WireGuard Windows client program, I can connect but internet does not work, that's what I get in logs

      2025-01-19 15:09:59.127308: [TUN] [wg] Startup complete

      2025-01-19 15:10:04.122533: [TUN] [wg] Handshake for peer 1 (130.162.167.42:51830) did not complete after 5 seconds, retrying (try 2)

      2025-01-19 15:10:04.122533: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:10:09.206795: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:10:14.215363: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:10:19.256183: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:10:24.293026: [TUN] [wg] Handshake for peer 1 (130.162.167.42:51830) did not complete after 5 seconds, retrying (try 2)

      2025-01-19 15:10:24.293026: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:10:29.438627: [TUN] [wg] Handshake for peer 1 (130.162.167.42:51830) did not complete after 5 seconds, retrying (try 2)

      2025-01-19 15:10:29.438627: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:10:34.479556: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:10:39.494686: [TUN] [wg] Handshake for peer 1 (130.162.167.42:51830) did not complete after 5 seconds, retrying (try 2)

      2025-01-19 15:10:39.494686: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:10:44.528590: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:10:49.669496: [TUN] [wg] Handshake for peer 1 (130.162.167.42:51830) did not complete after 5 seconds, retrying (try 2)

      2025-01-19 15:10:49.669496: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:10:54.683977: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:10:59.692184: [TUN] [wg] Handshake for peer 1 (130.162.167.42:51830) did not complete after 5 seconds, retrying (try 2)

      2025-01-19 15:10:59.692184: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:11:04.692549: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      2025-01-19 15:11:09.719846: [TUN] [wg] Sending handshake initiation to peer 1 (130.162.167.42:51830)

      In other words, it trying to do handshaker, but never successful. Here is my configs

      SERVER:

      [Interface]

      PrivateKey = <PRIVATE_KEY>

      Address = 10.0.0.1/24

      ListenPort = 51830

      PostUp = iptables -A FORWARD -i %i -j ACCEPT; iptables -t nat -A POSTROUTING -o ens4 -j MASQUERADE

      PostDown = iptables -D FORWARD -i %i -j ACCEPT; iptables -t nat -D POSTROUTING -o ens4 -j MASQUERADE

      [Peer]

      PublicKey = <PUBLIC_KEY>

      AllowedIPs = 10.0.0.2/32

      CLIENT:

      [Interface]

      PrivateKey = <PRIVATE_KEY>

      Address = 10.0.0.2/32

      DNS = 8.8.8.8

      [Peer]

      PublicKey = <PUBLIC_KEY>

      Endpoint = IP:51830

      AllowedIPs = 0.0.0.0/0

      PersistentKeepalive = 20

      I tried to change 10.0.0.1/24 to 10.0.0.1/32, but it did not change anything, anyone can help me please? Thanks!

      1 Reply Last reply Reply Quote 0
      • First post
        Last post
      Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.