Bridge utils config für Virtualbox Debian: Unterschied zwischen den Versionen
Zur Navigation springen
Zur Suche springen
(→Danach) |
|||
| Zeile 26: | Zeile 26: | ||
bind-interfaces | bind-interfaces | ||
dhcp-range=192.168.16.100,192.168.16.110,255.255.255.0,12h | dhcp-range=192.168.16.100,192.168.16.110,255.255.255.0,12h | ||
| − | dhcp-option=3,192.168.16. | + | dhcp-option=3,192.168.16.254 |
| − | dhcp-option=6,192.168.16. | + | dhcp-option=6,192.168.16.254 |
server=8.8.8.8 | server=8.8.8.8 | ||
log-queries | log-queries | ||
Aktuelle Version vom 8. April 2026, 12:09 Uhr
Installation
- apt install bridge-utils iptables dnsmasq
Muss in die /etc/network/interfaces
auto dummy0
iface dummy0 inet manual
pre-up modprobe dummy numdummies=1
auto vmbr0
iface vmbr0 inet static
address 192.168.16.254
netmask 255.255.255.0
bridge_ports dummy0
bridge_fd 5
bridge_stp no
post-up iptables -t nat -j POSTROUTING -s 192.168.16.0/24 -j MASQUERADE
post-up echo 1 > /proc/sys/net/ipv4/ip_forward
Danach
- ifup -v vmbr0
DNS und DHCP für das Netz
- Konfiguration
- vi /etc/dnsmasq.conf
interface=vmbr0 bind-interfaces dhcp-range=192.168.16.100,192.168.16.110,255.255.255.0,12h dhcp-option=3,192.168.16.254 dhcp-option=6,192.168.16.254 server=8.8.8.8 log-queries log-dhcp
- Starten und Enablen
- systemctl restart dnsmasq