New on LowEndTalk? Please Register and read our Community Rules.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
VirtFusion Bridge Networking
I'm trying to set up standard bridge networking on a hypervisor using Netplan, but I'm not sure what I'm doing wrong. I was following the VirtFusion hypervisor installation docs. Then I got some errors and started reading the Netplan docs, and made my own config. I may be confused, help me understand. 🙏
My config.
network:
version: 2
renderer: networkd
ethernets:
eno1:
dhcp4: false
bridges:
br0:
interfaces:
- eno1
addresses: # assigned IPv4s
- 200.99.101.111/24
- 200.99.102.111/24
- 200.99.102.222/24
- 200.99.103.111/24
- 200.99.103.222/24
- 200.99.103.333/24
routes:
- to: default
via: 200.99.101.1 # gateway for primary IP 200.99.101.111
table: 1
- to: default
via: 200.99.102.1 # gateway for 200.99.102.xxx
table: 2
- to: default
via: 200.99.103.1 # gateway for 200.99.103.xxx
table: 3
routing-policy:
- from: 200.99.101.111/24
table: 1
- from: 200.99.102.111/24
table: 2
- from: 200.99.102.222/24
table: 2
- from: 200.99.103.111/24
table: 3
- from: 200.99.103.222/24
table: 3
- from: 200.99.103.333/24
table: 3
dhcp4: no
nameservers:
addresses:
- 1.1.1.1
- 1.0.0.1
parameters:
stp: true
forward-delay: 0
Comments
The solution is to not use Netplan
Found How to switch back networking to /etc/network/interfaces on Ubuntu 22.04 Jammy Jellyfish Linux
Exactly. Better yet, use Debian.
Debian cloudinit thingy also has it
https://dai.ly/x6i7rsc?start=1943
Yeah, I wrote a short text with commands that I just copy paste to deploy a Debian hypervisor, I made it using ChatGPT by pasting the output of ’history’ and asking it to make the markdown guide. I can post it here for OP, let me just get to my computer🤓
@NessaCat (for Debian)
This guide outlines the steps for setting up and configuring your network on a Linux server. It includes commands to run, files to edit, and examples of file contents.
Commands to Run
First, execute the following commands in your terminal:
Files to Edit
You will need to edit the following files:
/etc/network/interfaces
This file configures your network interfaces. Here's the complete content for the file:
/etc/resolv.conf
This file sets up DNS servers for your network. Here's the complete content for the file:
/etc/systemd/resolved.conf
This file is for systemd's network name resolution service. Here's the complete content for the file:
Restart Services
After editing the files, restart the network services with these commands:
Obviously it can be easily improved such as merging the apt commands and deciding on sudo vs non-sudo etc but it's 100 % GPT based on my 'history' output and I cba to fix it up as it's only meant for me..
Ty @emgh I hate netplan, it has been the worse mistake of debain/ubuntu
Yup, definitely annoying. I think it was @FatGrizzly telling me to just not when I tried to make it work properly, and I've followed the advice since
@totally_not_banned or anyone else that might know, in my guide, I as said just used GPT to look at what I've done and make it readable for myself to follow in the future, but, is the editing of
/etc/resolv.conf
totally meaningless? As said, I just winged it, and it worked, but as I read it I realize that the system should get its DNS settings from/etc/systemd/resolved.conf
anyway, right?Edit: Yes, I read it for another few seconds and realized it's just a symlink of
/run/systemd/resolve/resolv.conf
.Well, from what i understand it's usually meaningless as in it'll work for everything which doesn't try to read /etc/resolv.conf directly (according Arch's wiki - yeah i had to look this up too - stuff like web browsers, software compiled from Go, GnuPG, ...). For those types of software systemd usually (as the default of 3 optional modes...) puts a single local DNS resolver running on 127.0.0.53 there. Talk about making stuff complicated. I figure putting some external DNS server there wouldn't really hurt either though as the only side effect would be avoiding systemd's resolver, i guess.
That's interesting, I remember seeing that on one of my systems!
Anyway, with the config that I posted above, /etc/resolv.conf simply symlinks to /run/systemd/resolve/resolv.conf, and sudo systemctl restart systemd-resolved resets the whole file according to systemd configurations, /etc/resolv.conf looking like (afterwards, minus the comments):
nameserver 1.1.1.1
nameserver 1.0.0.1
search .
So editing it manually is not needed. It'll reset on restart anyway.
A little fixed up version: https://lowendtalk.com/discussion/193264/bridged-virtfusion-setup-debian-12