Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bridge management #53

Open
signal-09 opened this issue Jun 14, 2024 · 0 comments
Open

Bridge management #53

signal-09 opened this issue Jun 14, 2024 · 0 comments

Comments

@signal-09
Copy link
Contributor

signal-09 commented Jun 14, 2024

Simple bridge management in Linux is handled by iproute2 as follow:

$ sudo ip link add name br0 type bridge
$ sudo ip link set dev br0 up
$ sudo ip link set dev eth0 master br0
$ sudo ip link set dev eth1 master br0

To remove an interface from the bridge:

$ sudo ip link set dev eth0 nomaster

In macOS the same result can be obtained with:

$ sudo ifconfig bridge0 create
$ sudo ifconfig bridge0 addm en0
$ sudo ifconfig bridge0 addm en1

And to remove an interface from the bridge:

$ sudo ifconfig bridge0 deletem en0

Bridge interfaces must be named bridge<n>, otherwise the system will throw an exception:

$ sudo ifconfig br0 create
ifconfig: SIOCIFCREATE2: Invalid argument
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants