<div dir="ltr">Hi, <div><br></div><div>Does anyone here have experience running Tinc on NixOS? </div><div><br></div><div>I'm trying to run Tinc on a NixOS machine, using the similar configuration i had for Ubuntu. My home subnet is <a href="http://192.168.1.0/24">192.168.1.0/24</a> and my work is <a href="http://10.16.0.0/24">10.16.0.0/24</a>. However, unlike ubuntu, when I start tincd on nixos, and try to 'ifconfig $INTERFACE 192.168.1.10 netmask 255.255.255.0' in my tinc-up, I loose network access on the box (no ping/ssh to the box). I see tun0 interface created, but no data flows. </div>
<div><br></div><div><div>eno1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500</div><div> inet 192.168.1.10 netmask 255.255.255.0 broadcast 192.168.1.255</div><div> inet6 fe80::c23f:d5ff:fe62:8353 prefixlen 64 scopeid 0x20<link></div>
<div> ether c0:3f:d5:62:83:53 txqueuelen 1000 (Ethernet)</div><div> RX packets 33611293 bytes 45550645568 (42.4 GiB)</div><div> RX errors 0 dropped 42 overruns 0 frame 0</div><div> TX packets 22359766 bytes 26366564624 (24.5 GiB)</div>
<div> TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0</div><div> device interrupt 20 memory 0xf7c00000-f7c20000</div><div><br></div><div><br></div><div>tun0: flags=4305<UP,POINTOPOINT,RUNNING,NOARP,MULTICAST> mtu 1500</div>
<div> unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 txqueuelen 500 (UNSPEC)</div><div> RX packets 0 bytes 0 (0.0 B)</div><div> RX errors 0 dropped 0 overruns 0 frame 0</div><div> TX packets 0 bytes 0 (0.0 B)</div>
<div> TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0</div></div><div><br></div><div>Here is my tinc-up</div><div><div><br></div><div>#!/nix/store/ajxd1z42ql9qihdj1pa7in12iynf532g-bash-4.2-p45/bin/sh</div>
<div>#ifconfig $INTERFACE 192.168.1.10 netmask 255.255.255.0</div><div>ip route add <a href="http://10.16.0.0/24">10.16.0.0/24</a> dev $INTERFACE</div><div>ip link set dev $INTERFACE up</div></div><div><br></div><div>Here are the routes on I see</div>
<div><div>[zs@homer2:~]$ route</div><div>Kernel IP routing table</div><div>Destination Gateway Genmask Flags Metric Ref Use Iface</div><div>default 10.16.0.1 0.0.0.0 UG 0 0 0 eno16777728</div>
<div>10.16.0.0 * 255.255.0.0 U 0 0 0 eno16777728</div><div>192.168.1.0 * 255.255.255.0 U 0 0 0 eno16777728</div></div><div><br></div><div><div>[zs@esprit1:~]$ route</div>
<div>Kernel IP routing table</div><div>Destination Gateway Genmask Flags Metric Ref Use Iface</div><div>default 192.168.1.1 0.0.0.0 UG 202 0 0 eno1</div><div>10.16.0.0 * 255.255.255.0 U 0 0 0 eno1</div>
<div>192.168.1.0 * 255.255.255.0 U 202 0 0 eno1</div></div><div><br></div><div><br></div><div>Any suggestions/pointers to debug this would be appreciated. I see the two tinc nodes are performing PING/PONG.</div>
<div><br>Thanks,</div><div>Zia</div><div><br></div></div>