https://wiki.archlinux.org/api.php?action=feedcontributions&user=Plutosrings&feedformat=atomArchWiki - User contributions [en]2024-03-29T11:48:08ZUser contributionsMediaWiki 1.41.0https://wiki.archlinux.org/index.php?title=Bridge_with_netctl&diff=335813Bridge with netctl2014-09-17T04:05:03Z<p>Plutosrings: /* Configuration */ - change references in the description of new example from values in example to parameter names</p>
<hr />
<div>[[Category:Networking]]<br />
{{Related articles start}}<br />
{{Related|Network bridge}}<br />
{{Related articles end}}<br />
<br />
{{Merge|Network bridge|I suggest to move the netctl-specific parts of this article into a subsection of "Network bridge"}}<br />
<br />
== Installation ==<br />
<br />
[[pacman|Install]] the {{Pkg|netctl}} package from the [[official repositories]].<br />
<br />
== Configuration ==<br />
<br />
* Copy {{ic|/etc/netctl/examples/bridge}} to {{ic|/etc/netctl/bridge}}.<br />
* In this example, we create a bridge called {{ic|br0}} which has real Ethernet adapter {{ic|eth0}} and (optionally) a tap device {{ic|tap0}} connected to it. Of course, edit {{ic|br0}}, {{ic|eth0}} and {{ic|tap0}} to your needs.<br />
<br />
{{hc|/etc/netctl/bridge|<nowiki><br />
Description="Example Bridge connection"<br />
Interface=br0<br />
Connection=bridge<br />
BindsToInterfaces=(eth0 tap0)<br />
IP=dhcp<br />
</nowiki>}}<br />
<br />
* This example creates a statically assigned bridge called {{ic|br0}} which has real Ethernet adapter {{ic|eth0}} connected to it. Edit {{ic|Interface}}, {{ic|BindsToInterfaces}}, {{ic|Address}}, and {{ic|Gateway}} to your needs.<br />
{{hc| /etc/netctl/bridge|<nowiki><br />
Description="Example Bridge connection"<br />
Interface=br0<br />
Connection=bridge<br />
BindsToInterfaces=(eth0)<br />
IP=static<br />
Address='192.168.10.20/24'<br />
Gateway='192.168.10.200'<br />
## Ignore (R)STP and immediately activate the bridge<br />
SkipForwardingDelay=yes<br />
</nowiki>}}<br />
{{Tip|If you are using static IP, see man pages of [[netctl]], and also edit {{ic|/etc/resolv.conf}} if necessary.}}<br />
<br />
<br />
* You can bridge any combination of network devices editing {{ic|BindsToInterfaces}} option.<br />
* If any of the bridged devices (e.g. {{ic|eth0}}, {{ic|tap0}}) had [[dhcpcd]] enabled, [[systemd#Using units|stop and disable]] the {{ic|dhcpcd@eth0.service}} daemon. Or set {{ic|1=IP=no}} to the netctl profiles.<br />
* Finally, [[netctl#Just one profile|start and enable]] your {{ic|/etc/netctl/bridge}}.</div>Plutosringshttps://wiki.archlinux.org/index.php?title=Bridge_with_netctl&diff=335812Bridge with netctl2014-09-17T04:01:28Z<p>Plutosrings: /* Configuration */ Added an example of a statically configured bridge, usage of the single quotes for the value was not immediately obvious to me, a similar example i found online helped</p>
<hr />
<div>[[Category:Networking]]<br />
{{Related articles start}}<br />
{{Related|Network bridge}}<br />
{{Related articles end}}<br />
<br />
{{Merge|Network bridge|I suggest to move the netctl-specific parts of this article into a subsection of "Network bridge"}}<br />
<br />
== Installation ==<br />
<br />
[[pacman|Install]] the {{Pkg|netctl}} package from the [[official repositories]].<br />
<br />
== Configuration ==<br />
<br />
* Copy {{ic|/etc/netctl/examples/bridge}} to {{ic|/etc/netctl/bridge}}.<br />
* In this example, we create a bridge called {{ic|br0}} which has real Ethernet adapter {{ic|eth0}} and (optionally) a tap device {{ic|tap0}} connected to it. Of course, edit {{ic|br0}}, {{ic|eth0}} and {{ic|tap0}} to your needs.<br />
<br />
{{hc|/etc/netctl/bridge|<nowiki><br />
Description="Example Bridge connection"<br />
Interface=br0<br />
Connection=bridge<br />
BindsToInterfaces=(eth0 tap0)<br />
IP=dhcp<br />
</nowiki>}}<br />
<br />
* This example creates a statically assigned bridge called {{ic|br0}} which has real Ethernet adapter {{ic|eth0}} connected to it. Edit {{ic|br0}}, {{ic|eth0}}, {{ic|Address}}, and {{ic|Gateway}} to your needs.<br />
{{hc| /etc/netctl/bridge|<nowiki><br />
Description="Example Bridge connection"<br />
Interface=br0<br />
Connection=bridge<br />
BindsToInterfaces=(eth0)<br />
IP=static<br />
Address='192.168.10.20/24'<br />
Gateway='192.168.10.200'<br />
## Ignore (R)STP and immediately activate the bridge<br />
SkipForwardingDelay=yes<br />
</nowiki>}}<br />
{{Tip|If you are using static IP, see man pages of [[netctl]], and also edit {{ic|/etc/resolv.conf}} if necessary.}}<br />
<br />
<br />
* You can bridge any combination of network devices editing {{ic|BindsToInterfaces}} option.<br />
* If any of the bridged devices (e.g. {{ic|eth0}}, {{ic|tap0}}) had [[dhcpcd]] enabled, [[systemd#Using units|stop and disable]] the {{ic|dhcpcd@eth0.service}} daemon. Or set {{ic|1=IP=no}} to the netctl profiles.<br />
* Finally, [[netctl#Just one profile|start and enable]] your {{ic|/etc/netctl/bridge}}.</div>Plutosrings