Search the Community
Showing results for tags 'namespace'.
Found 1 result
-
Hi, I created the wireguard interface and applied the configuration on the init namespace. I then moved it to a "container" namespace with ip link set wg0 netns container ip -n container link set wg0 up I then add an ip to it, and add the default route on my container namespace to be on wg0, but i have no network connectivity. Looking at wireshark, it seems the packets can get out, but cannot come back. here is some additional info: gnuwu@anonynowo ~ $ sudo ip -n container a Password: 1: lo: <LOOPBACK> mtu 65536 qdisc noop state DOWN group default qlen 1000 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 2: sit0@NONE: <NOARP> mtu 1480 qdisc noop state DOWN group default qlen 1000 link/sit 0.0.0.0 brd 0.0.0.0 9: wg0: <POINTOPOINT,NOARP,UP,LOWER_UP> mtu 1420 qdisc noqueue state UNKNOWN group default qlen 1000 link/none inet 172.16.0.2/32 scope global wg0 valid_lft forever preferred_lft forever gnuwu@anonynowo ~ $ sudo ip -n container l 1: lo: <LOOPBACK> mtu 65536 qdisc noop state DOWN mode DEFAULT group default qlen 1000 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 2: sit0@NONE: <NOARP> mtu 1480 qdisc noop state DOWN mode DEFAULT group default qlen 1000 link/sit 0.0.0.0 brd 0.0.0.0 9: wg0: <POINTOPOINT,NOARP,UP,LOWER_UP> mtu 1420 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000 link/none gnuwu@anonynowo ~ $ sudo ip netns exec container wg show interface: wg0 public key: (hidden) private key: (hidden) listening port: 40816 peer: (hidden) preshared key: (hidden) endpoint: 213.152.161.236:1637 allowed ips: 0.0.0.0/0, ::/0 latest handshake: 59 seconds ago transfer: 3.76 KiB received, 71.90 KiB sent persistent keepalive: every 15 seconds gnuwu@anonynowo ~ $ sudo ip -n container r default dev wg0 scope link gnuwu@anonynowo ~ $ sudo ip netns exec container ping -c 4 1.1.1.1 PING 1.1.1.1 (1.1.1.1) 56(84) bytes of data. --- 1.1.1.1 ping statistics --- 4 packets transmitted, 0 received, 100% packet loss, time 3068ms