<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.alikaravi.ir/index.php?action=history&amp;feed=atom&amp;title=Mikrotik_Ubuntu_L2TPv3</id>
	<title>Mikrotik Ubuntu L2TPv3 - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.alikaravi.ir/index.php?action=history&amp;feed=atom&amp;title=Mikrotik_Ubuntu_L2TPv3"/>
	<link rel="alternate" type="text/html" href="https://wiki.alikaravi.ir/index.php?title=Mikrotik_Ubuntu_L2TPv3&amp;action=history"/>
	<updated>2026-06-22T13:40:39Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.40.1</generator>
	<entry>
		<id>https://wiki.alikaravi.ir/index.php?title=Mikrotik_Ubuntu_L2TPv3&amp;diff=171&amp;oldid=prev</id>
		<title>Karavi at 19:42, 21 June 2026</title>
		<link rel="alternate" type="text/html" href="https://wiki.alikaravi.ir/index.php?title=Mikrotik_Ubuntu_L2TPv3&amp;diff=171&amp;oldid=prev"/>
		<updated>2026-06-21T19:42:44Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 19:42, 21 June 2026&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l10&quot;&gt;Line 10:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 10:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;| &amp;#039;&amp;#039;&amp;#039;Device&amp;#039;&amp;#039;&amp;#039; || Ubuntu 24.04 || MikroTik RouterOS 7.20+&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;| &amp;#039;&amp;#039;&amp;#039;Device&amp;#039;&amp;#039;&amp;#039; || Ubuntu 24.04 || MikroTik RouterOS 7.20+&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;| &#039;&#039;&#039;Public IP&#039;&#039;&#039; || 157.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;90&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;26&lt;/del&gt;.4 || &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;78&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;157&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;42&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;222&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;| &#039;&#039;&#039;Public IP&#039;&#039;&#039; || 157.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;9&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;2&lt;/ins&gt;.4 || &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;85&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;57&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;4&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;221&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;| &amp;#039;&amp;#039;&amp;#039;Tunnel IP&amp;#039;&amp;#039;&amp;#039; || 10.0.0.1/30 || 10.0.0.2/30&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;| &amp;#039;&amp;#039;&amp;#039;Tunnel IP&amp;#039;&amp;#039;&amp;#039; || 10.0.0.1/30 || 10.0.0.2/30&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l53&quot;&gt;Line 53:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 53:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   version = &amp;quot;l2tpv3&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   version = &amp;quot;l2tpv3&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   encap = &amp;quot;ip&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   encap = &amp;quot;ip&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   local = &quot;157.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;90&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;26&lt;/del&gt;.4:0&quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   local = &quot;157.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;9&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;2&lt;/ins&gt;.4:0&quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   peer = &quot;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;78&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;157&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;42&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;222&lt;/del&gt;:0&quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   peer = &quot;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;85&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;57&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;4&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;221&lt;/ins&gt;:0&quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   tid = 100&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   tid = 100&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   ptid = 200&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   ptid = 200&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l112&quot;&gt;Line 112:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 112:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;syntaxhighlight lang=&amp;quot;text&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;syntaxhighlight lang=&amp;quot;text&amp;quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;/interface l2tp-ether add name=l2tpv3 connect-to=157.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;90&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;26&lt;/del&gt;.4 local-address=&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;78&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;157&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;42&lt;/del&gt;.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;222 &lt;/del&gt;local-tunnel-id=200 remote-tunnel-id=100 local-session-id=2000 remote-session-id=1000 l2tp-proto-version=l2tpv3-ip unmanaged-mode=yes disabled=no&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;/interface l2tp-ether add name=l2tpv3 connect-to=157.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;9&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;2&lt;/ins&gt;.4 local-address=&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;85&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;57&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;4&lt;/ins&gt;.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;221 &lt;/ins&gt;local-tunnel-id=200 remote-tunnel-id=100 local-session-id=2000 remote-session-id=1000 l2tp-proto-version=l2tpv3-ip unmanaged-mode=yes disabled=no&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;/ip address add address=10.0.0.2/30 interface=l2tpv3&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;/ip address add address=10.0.0.2/30 interface=l2tpv3&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Karavi</name></author>
	</entry>
	<entry>
		<id>https://wiki.alikaravi.ir/index.php?title=Mikrotik_Ubuntu_L2TPv3&amp;diff=170&amp;oldid=prev</id>
		<title>Karavi: Created page with &quot;== L2TPv3 Tunnel: Linux to MikroTik ==  === Overview ===  This guide explains how to set up a static L2TPv3 site-to-site tunnel between a Linux server and a MikroTik router using &lt;code&gt;ql2tpd&lt;/code&gt; from the &lt;code&gt;go-l2tp&lt;/code&gt; package.  {| class=&quot;wikitable&quot; ! !! Server !! Client |- | &#039;&#039;&#039;Device&#039;&#039;&#039; || Ubuntu 24.04 || MikroTik RouterOS 7.20+ |- | &#039;&#039;&#039;Public IP&#039;&#039;&#039; || 157.90.26.4 || 78.157.42.222 |- | &#039;&#039;&#039;Tunnel IP&#039;&#039;&#039; || 10.0.0.1/30 || 10.0.0.2/30 |- | &#039;&#039;&#039;Tunnel ID&#039;&#039;&#039; || 100...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.alikaravi.ir/index.php?title=Mikrotik_Ubuntu_L2TPv3&amp;diff=170&amp;oldid=prev"/>
		<updated>2026-06-21T19:38:06Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;== L2TPv3 Tunnel: Linux to MikroTik ==  === Overview ===  This guide explains how to set up a static L2TPv3 site-to-site tunnel between a Linux server and a MikroTik router using &amp;lt;code&amp;gt;ql2tpd&amp;lt;/code&amp;gt; from the &amp;lt;code&amp;gt;go-l2tp&amp;lt;/code&amp;gt; package.  {| class=&amp;quot;wikitable&amp;quot; ! !! Server !! Client |- | &amp;#039;&amp;#039;&amp;#039;Device&amp;#039;&amp;#039;&amp;#039; || Ubuntu 24.04 || MikroTik RouterOS 7.20+ |- | &amp;#039;&amp;#039;&amp;#039;Public IP&amp;#039;&amp;#039;&amp;#039; || 157.90.26.4 || 78.157.42.222 |- | &amp;#039;&amp;#039;&amp;#039;Tunnel IP&amp;#039;&amp;#039;&amp;#039; || 10.0.0.1/30 || 10.0.0.2/30 |- | &amp;#039;&amp;#039;&amp;#039;Tunnel ID&amp;#039;&amp;#039;&amp;#039; || 100...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== L2TPv3 Tunnel: Linux to MikroTik ==&lt;br /&gt;
&lt;br /&gt;
=== Overview ===&lt;br /&gt;
&lt;br /&gt;
This guide explains how to set up a static L2TPv3 site-to-site tunnel between a Linux server and a MikroTik router using &amp;lt;code&amp;gt;ql2tpd&amp;lt;/code&amp;gt; from the &amp;lt;code&amp;gt;go-l2tp&amp;lt;/code&amp;gt; package.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! !! Server !! Client&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;Device&amp;#039;&amp;#039;&amp;#039; || Ubuntu 24.04 || MikroTik RouterOS 7.20+&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;Public IP&amp;#039;&amp;#039;&amp;#039; || 157.90.26.4 || 78.157.42.222&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;Tunnel IP&amp;#039;&amp;#039;&amp;#039; || 10.0.0.1/30 || 10.0.0.2/30&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;Tunnel ID&amp;#039;&amp;#039;&amp;#039; || 100 || 200&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;Session ID&amp;#039;&amp;#039;&amp;#039; || 1000 || 2000&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
---&lt;br /&gt;
&lt;br /&gt;
=== Prerequisites ===&lt;br /&gt;
&lt;br /&gt;
* Ubuntu 24.04 (kernel 6.8+)&lt;br /&gt;
* MikroTik RouterOS 7.20 or later&lt;br /&gt;
* Root access on both devices&lt;br /&gt;
* IP protocol 115 allowed in firewall on both sides&lt;br /&gt;
&lt;br /&gt;
---&lt;br /&gt;
&lt;br /&gt;
=== Linux Server Setup ===&lt;br /&gt;
&lt;br /&gt;
==== 1. Install packages ====&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
apt install -y linux-modules-extra-$(uname -r) go-l2tp&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== 2. Load kernel modules ====&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
modprobe l2tp_eth l2tp_ip l2tp_netlink&lt;br /&gt;
echo -e &amp;quot;l2tp_eth\nl2tp_ip\nl2tp_netlink&amp;quot; &amp;gt; /etc/modules-load.d/l2tp.conf&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== 3. Create ql2tpd configuration ====&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
mkdir -p /etc/ql2tpd&lt;br /&gt;
cat &amp;gt; /etc/ql2tpd/ql2tpd.toml &amp;lt;&amp;lt; &amp;#039;EOF&amp;#039;&lt;br /&gt;
[tunnel.t1]&lt;br /&gt;
  version = &amp;quot;l2tpv3&amp;quot;&lt;br /&gt;
  encap = &amp;quot;ip&amp;quot;&lt;br /&gt;
  local = &amp;quot;157.90.26.4:0&amp;quot;&lt;br /&gt;
  peer = &amp;quot;78.157.42.222:0&amp;quot;&lt;br /&gt;
  tid = 100&lt;br /&gt;
  ptid = 200&lt;br /&gt;
&lt;br /&gt;
  [tunnel.t1.session.s1]&lt;br /&gt;
    pseudowire = &amp;quot;eth&amp;quot;&lt;br /&gt;
    sid = 1000&lt;br /&gt;
    psid = 2000&lt;br /&gt;
    interface_name = &amp;quot;l2tpeth0&amp;quot;&lt;br /&gt;
EOF&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== 4. Create systemd service ====&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
cat &amp;gt; /etc/systemd/system/ql2tpd.service &amp;lt;&amp;lt; &amp;#039;EOF&amp;#039;&lt;br /&gt;
[Unit]&lt;br /&gt;
Description=L2TPv3 Static Tunnel&lt;br /&gt;
After=network.target&lt;br /&gt;
&lt;br /&gt;
[Service]&lt;br /&gt;
ExecStart=/usr/sbin/ql2tpd -config /etc/ql2tpd/ql2tpd.toml&lt;br /&gt;
Restart=always&lt;br /&gt;
&lt;br /&gt;
[Install]&lt;br /&gt;
WantedBy=multi-user.target&lt;br /&gt;
EOF&lt;br /&gt;
&lt;br /&gt;
systemctl enable --now ql2tpd&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== 5. Assign tunnel IP ====&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
sleep 2&lt;br /&gt;
ip addr add 10.0.0.1/30 dev l2tpeth0&lt;br /&gt;
ip link set l2tpeth0 up&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== 6. Persist IP after reboot ====&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
cat &amp;gt; /etc/networkd-dispatcher/routable.d/l2tp-ip.sh &amp;lt;&amp;lt; &amp;#039;EOF&amp;#039;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
sleep 3&lt;br /&gt;
ip addr add 10.0.0.1/30 dev l2tpeth0 2&amp;gt;/dev/null&lt;br /&gt;
ip link set l2tpeth0 up 2&amp;gt;/dev/null&lt;br /&gt;
EOF&lt;br /&gt;
chmod +x /etc/networkd-dispatcher/routable.d/l2tp-ip.sh&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
---&lt;br /&gt;
&lt;br /&gt;
=== MikroTik Client Setup ===&lt;br /&gt;
&lt;br /&gt;
Run the following commands in the MikroTik terminal:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;text&amp;quot;&amp;gt;&lt;br /&gt;
/interface l2tp-ether add name=l2tpv3 connect-to=157.90.26.4 local-address=78.157.42.222 local-tunnel-id=200 remote-tunnel-id=100 local-session-id=2000 remote-session-id=1000 l2tp-proto-version=l2tpv3-ip unmanaged-mode=yes disabled=no&lt;br /&gt;
&lt;br /&gt;
/ip address add address=10.0.0.2/30 interface=l2tpv3&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note|&amp;lt;code&amp;gt;unmanaged-mode=yes&amp;lt;/code&amp;gt; is required. Without it, MikroTik attempts to run the L2TPv3 control protocol, which &amp;lt;code&amp;gt;ql2tpd&amp;lt;/code&amp;gt; does not support since it operates as a static (data-plane only) daemon.}}&lt;br /&gt;
&lt;br /&gt;
---&lt;br /&gt;
&lt;br /&gt;
=== Verification ===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;From Linux server:&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
ping 10.0.0.2 -c 4&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;From MikroTik:&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;text&amp;quot;&amp;gt;&lt;br /&gt;
/ping 10.0.0.1 count=4&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
---&lt;br /&gt;
&lt;br /&gt;
=== Cleanup ===&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Linux server:&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
systemctl stop ql2tpd&lt;br /&gt;
systemctl disable ql2tpd&lt;br /&gt;
rm /etc/systemd/system/ql2tpd.service&lt;br /&gt;
rm -rf /etc/ql2tpd&lt;br /&gt;
rm -f /etc/networkd-dispatcher/routable.d/l2tp-ip.sh&lt;br /&gt;
rm -f /etc/modules-load.d/l2tp.conf&lt;br /&gt;
systemctl daemon-reload&lt;br /&gt;
ip link del l2tpeth0 2&amp;gt;/dev/null&lt;br /&gt;
modprobe -r l2tp_eth l2tp_ip l2tp_netlink 2&amp;gt;/dev/null&lt;br /&gt;
apt remove -y go-l2tp&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;MikroTik:&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;text&amp;quot;&amp;gt;&lt;br /&gt;
/ip address remove [find interface=l2tpv3]&lt;br /&gt;
/interface l2tp-ether remove l2tpv3&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
---&lt;br /&gt;
&lt;br /&gt;
=== Troubleshooting ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Symptom !! Cause !! Fix&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;Module l2tp_eth not found&amp;lt;/code&amp;gt; || Missing extra modules || &amp;lt;code&amp;gt;apt install linux-modules-extra-$(uname -r)&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Interface not created || &amp;lt;code&amp;gt;ql2tpd&amp;lt;/code&amp;gt; not running in background || Run with &amp;lt;code&amp;gt;&amp;amp;&amp;lt;/code&amp;gt; or use systemd service&lt;br /&gt;
|-&lt;br /&gt;
| Link stays DOWN || MikroTik sending control messages || Add &amp;lt;code&amp;gt;unmanaged-mode=yes&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No packets arriving || Firewall blocking proto 115 || Allow IP protocol 115 on both sides&lt;br /&gt;
|-&lt;br /&gt;
| IP lost after reboot || No persistence script || Add networkd-dispatcher script (step 6)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
---&lt;br /&gt;
&lt;br /&gt;
=== Notes ===&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;ql2tpd&amp;lt;/code&amp;gt; is a static (quiescent) L2TPv3 daemon — it does &amp;#039;&amp;#039;&amp;#039;not&amp;#039;&amp;#039;&amp;#039; run the L2TPv3 control protocol. Both peers must have matching tunnel and session IDs configured manually.&lt;br /&gt;
* MikroTik &amp;lt;code&amp;gt;l2tp-ether&amp;lt;/code&amp;gt; with &amp;lt;code&amp;gt;unmanaged-mode=yes&amp;lt;/code&amp;gt; bypasses the control protocol and operates as a pure static data plane, making it compatible with &amp;lt;code&amp;gt;ql2tpd&amp;lt;/code&amp;gt;.&lt;br /&gt;
* The tunnel carries raw Ethernet frames (pseudowire type: &amp;lt;code&amp;gt;eth&amp;lt;/code&amp;gt;), making it suitable for Layer 2 bridging between sites.&lt;br /&gt;
* No encryption is applied by default. For production use, consider wrapping the tunnel with IPsec.&lt;br /&gt;
&lt;br /&gt;
---&lt;br /&gt;
&lt;br /&gt;
=== References ===&lt;br /&gt;
&lt;br /&gt;
* [https://github.com/katalix/go-l2tp go-l2tp GitHub]&lt;br /&gt;
* [https://manpages.ubuntu.com/manpages/oracular/man5/ql2tpd.toml.5.html ql2tpd.toml man page]&lt;br /&gt;
* [https://www.rfc-editor.org/rfc/rfc3931 RFC 3931 — L2TPv3]&lt;br /&gt;
* [https://www.rfc-editor.org/rfc/rfc4719 RFC 4719 — L2TPv3 Ethernet Pseudowire]&lt;/div&gt;</summary>
		<author><name>Karavi</name></author>
	</entry>
</feed>