L2TP Client: Debian: Difference between revisions

(less fail)
 
You MUST NOT use DHCP on this connection. You have to set a static IP, so that you can set a custom route, going to <tt>90.155.53.19</tt> *via* what would otherwise be the <tt>gateway</tt> line; in this case I'd normally set <tt>gateway 10.42.0.1</tt> in the example below, but instead i set <tt>up /sbin/ip route add 90.155.53.19/32 via 10.42.0.1 dev enp14s0</tt>. This makes all traffic on IPv4 route through the L2TP instead of directly through the main upstream, in this case virgin media.
 
'''And do the same for any other IP addresses that l2tp.aa.net.uk resolves to. Note that IPs may be added with or without warning.'''
 
The fact that I used Virgin Media on this line is irrelevant. You can use L2TP on any ISP. Adapt the config below to your needs, accordingly: