Development discussion of WireGuard
 help / color / mirror / Atom feed
From: <wireguard@lindenberg.one>
To: <wireguard@lists.zx2c4.com>
Subject: AW: AW: two client connections -> crash?
Date: Mon, 20 Jul 2020 16:23:54 +0200	[thread overview]
Message-ID: <064401d65ea1$66142470$323c6d50$@lindenberg.one> (raw)
In-Reply-To: <41f52bae-6caf-75b4-3b69-c0a2e10451db@xand.uk>

Hello,
thanks for pointing that out. Actually the idea was to switch over my VPN endpoint from one VPS to another one, thus the any address route (0.0.0.0/0) was correct, but now it is clear to me it does not make sense really to have any address twice. I am trying to test the new endpoint with a dedicated machine now (which fails to install wireguard).
But I am still wondering why the network stack kind of crashes. Even with a bullshit configuration like I did, imho this should never happen.
Thanks, Joachim

-----Ursprüngliche Nachricht-----
Von: WireGuard <wireguard-bounces@lists.zx2c4.com> Im Auftrag von Xand Meaden
Gesendet: Tuesday, 14 July 2020 15:50
An: wireguard@lists.zx2c4.com
Betreff: Re: AW: two client connections -> crash?

"AllowedIPs" is the list of IP addresses/subnets that should be routed via that wireguard tunnel. In your case you've set both tunnels to be default route (0.0.0.0/0) for IPv4 traffic.

So it depends on what is the other end of each tunnel - and what you want the tunnel to be used for. AllowedIPs might just be the private IP address of each peer if you just want to communicate with that.

Xand

On 14/07/2020 14:43, Joachim Lindenberg wrote:
> Good observation. I never really understood  what IPs I should put there and also didn´t find a good  documentation on that. And obviously with one connection it wasn´t that important to get it right. What IP addresses or network should AllowedIPs refer to? Client? Server? Tunnel?
> Thanks, Joachim
>
> -----Ursprüngliche Nachricht-----
> Von: M. Dietrich <mdt@emdete.de>
> Gesendet: Tuesday, 14 July 2020 12:11
> An: wireguard@lindenberg.one; 'WireGuard mailing list' 
> <wireguard@lists.zx2c4.com>
> Betreff: Re: two client connections -> crash?
>
>
> Quotation from wireguard@lindenberg.one at Juli 13, 2020 20:53:
>> I am trying to configure one client system (Ubuntu 18.04.4 LTS 
>> (GNU/Linux 5.3.0-62-generic x86_64)) against two servers. The 
>> configuration is very similar:
>>
>> root@Mailcow:/home/joachim# cat /etc/wireguard/wg0-client.conf 
>> [Interface] Address = 10.200.200.2/24 PrivateKey = *** DNS = 8.8.8.8
>> #10.200.200.1
>>
>> [Peer]
>> PublicKey = qn6CTz578gbrYpzYkvV2okoqkIFHKye+mRj4i/I8Sz8=
>> Endpoint = fire.lindenberg.one:51820
>> AllowedIPs = 0.0.0.0/0
>> PersistentKeepalive = 21
>>
>> root@Mailcow:/home/joachim# cat /etc/wireguard/wg1-client.conf 
>> [Interface] Address = 10.200.201.2/24 PrivateKey = *** DNS = 8.8.8.8
>> #10.200.200.1
>>
>> [Peer]
>> PublicKey = QAJANxtuAvdT+HR3fP1I2DXq0Azl0T3jF5s+cW7foSA=
>> Endpoint = nc.lindenberg.one:51820
>> AllowedIPs = 0.0.0.0/0
>> PersistentKeepalive = 21
>>
>> Wg-quick up wg0-client ist at system startup. Now unfortunately when 
>> I do wg-quick up wg1-client the network stack kind of crashes. The 
>> command does not terminate, and connectivity on all interfaces is 
>> broken.
>> Is this a configuration issue? Should I change ports to be different? 
>> Is there some other issue?
> The ports are fine because the IPs are different. You use the same AllowedIPs for both. And they cover the whole network. 
> This cannot work. What is the intention of that config?
>
>> Do I have to define two interfaces or could I have just one with 
>> multiple peers? But how could I then specify which tunnel to use?
> Depends on what you want to achieve. Sure you can use multiple peers for one interface.
>



  reply	other threads:[~2020-07-20 14:24 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-13 18:53 wireguard
2020-07-13 23:51 ` Jason A. Donenfeld
2020-07-14 10:11 ` M. Dietrich
2020-07-14 13:43   ` AW: " Joachim Lindenberg
2020-07-14 13:50     ` Xand Meaden
2020-07-20 14:23       ` wireguard [this message]
2020-07-14 17:54     ` M. Dietrich

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='064401d65ea1$66142470$323c6d50$@lindenberg.one' \
    --to=wireguard@lindenberg.one \
    --cc=wireguard@lists.zx2c4.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).