XEN-Netzwerk mit Debian: Unterschied zwischen den Versionen
Zur Navigation springen
Zur Suche springen
Keine Bearbeitungszusammenfassung |
Keine Bearbeitungszusammenfassung |
||
Zeile 18: | Zeile 18: | ||
# interfaces(5) file used by ifup(8) and ifdown(8) | # interfaces(5) file used by ifup(8) and ifdown(8) | ||
# Include files from /etc/network/interfaces.d: | # Include files from /etc/network/interfaces.d: | ||
#------------------------------------- | |||
# read xen-bridges definition | |||
#------------------------------------- | |||
source-directory /etc/network/interfaces.d | source-directory /etc/network/interfaces.d | ||
# | #------------------------------------- | ||
# use ethx names | |||
#------------------------------------- | |||
rename enp0s25=eth0 | rename enp0s25=eth0 | ||
rename enp2s0=eth1 | rename enp2s0=eth1 | ||
rename enp3s0=eth2 | rename enp3s0=eth2 | ||
# | #------------------------------------- | ||
# start ethernet and xen-bridges | |||
#------------------------------------- | |||
auto lo /eth*=eth xennetwork | auto lo /eth*=eth xennetwork | ||
Zeile 34: | Zeile 39: | ||
iface lo inet loopback | iface lo inet loopback | ||
# The | #------------------------------------- | ||
# The physical network interfaces | |||
#------------------------------------- | |||
iface eth inet manual | iface eth inet manual | ||
# pre-up /sbin/ethtool -K $IFACE gso off gro off tso off | # pre-up /sbin/ethtool -K $IFACE gso off gro off tso off | ||
#------------------------------------- | |||
# interfaces.d/xenbridges: | # interfaces.d/xenbridges: | ||
# br0intern, br1extern, br2dmz, br3wlan, br4off | # br0intern, br1extern, br2dmz, br3wlan, br4off | ||
#------------------------------------- | |||
iface xennetwork inet manual | iface xennetwork inet manual | ||
#pre-up ifdown /vlan* || true | |||
up ifup br0intern br2dmz br3wlan br4off | up ifup br0intern br2dmz br3wlan br4off | ||
down ifdown br0intern br2dmz br3wlan br4off | down ifdown br0intern br2dmz br3wlan br4off | ||
#------------------------------------- | |||
# optional (manual) VLAN configuration | |||
#------------------------------------- | |||
rename eth2.1=vlanintern | |||
rename eth2.178=vlanextern | |||
iface vlanintern inet static | iface vlanintern inet static | ||
#pre-up ifdown xennetwork || true | |||
address 192.168.2.5/24 | address 192.168.2.5/24 | ||
gateway 192.168.2.12 | gateway 192.168.2.12 | ||
iface vlanextern inet static | iface vlanextern inet static | ||
#pre-up ifdown xennetwork || true | |||
address 192.168.178.5/24 | address 192.168.178.5/24 | ||
gateway 192.168.178.1 | gateway 192.168.178.1 |
Version vom 26. Dezember 2020, 12:59 Uhr
Ich verwende die folgende Netzwerkkonfiguration:
- 1x LAN auf Netzwerkkarte (eth0)
- 1x freie Netzwerkkarte (eth1)
- 1x Firewall Netzwerkkarte (eth2)
- 2x VLAN: nur manuell gestartet (eth2.x)
- XEN-Netzwerk: Bridges br0intern (eth0), br2dmz, br3wlan
Das LAN verwendet die XEN Bridge br0intern mit Netzwerkkarte eth0.
Die Firewall benutzt direkt die Netzwerkkarte eth2 und erstellt selbst die notwendigen VLAN's.
Die XEN Bridges br2dmz und br3wlan werden mit der Firewall verbunden, aber nicht mit einer Netzwerkkarte.
Die VLAN's vlanintern und vlanextern werden normalerweise nicht auf dem XEN-Host konfiguriert, sondern in der Firewall. Die Konfiguration der VLAN's wird nur bedarfsweise manuell gestartet.
File: /etc/network/interfaces
# interfaces(5) file used by ifup(8) and ifdown(8) # Include files from /etc/network/interfaces.d: #------------------------------------- # read xen-bridges definition #------------------------------------- source-directory /etc/network/interfaces.d #------------------------------------- # use ethx names #------------------------------------- rename enp0s25=eth0 rename enp2s0=eth1 rename enp3s0=eth2 #------------------------------------- # start ethernet and xen-bridges #------------------------------------- auto lo /eth*=eth xennetwork # The loopback network interface iface lo inet loopback #------------------------------------- # The physical network interfaces #------------------------------------- iface eth inet manual # pre-up /sbin/ethtool -K $IFACE gso off gro off tso off #------------------------------------- # interfaces.d/xenbridges: # br0intern, br1extern, br2dmz, br3wlan, br4off #------------------------------------- iface xennetwork inet manual #pre-up ifdown /vlan* || true up ifup br0intern br2dmz br3wlan br4off down ifdown br0intern br2dmz br3wlan br4off #------------------------------------- # optional (manual) VLAN configuration #------------------------------------- rename eth2.1=vlanintern rename eth2.178=vlanextern iface vlanintern inet static #pre-up ifdown xennetwork || true address 192.168.2.5/24 gateway 192.168.2.12 iface vlanextern inet static #pre-up ifdown xennetwork || true address 192.168.178.5/24 gateway 192.168.178.1