Benutzer-Werkzeuge

Webseiten-Werkzeuge


knowledge_base:linux:ipconfig:ifupdown

IP configuration: ifupdown

ifupdown is the classic debian way of configuring network. It is on its way out tho. Still works on Debian 12, but for example Raspian Bookworm and Debian Cloud Images have moved away from it.

Static Configuration

/etc/network/interfaces
# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
allow-hotplug eth0
iface eth0 inet static
        address 192.168.21.2/24
        gateway 192.168.21.1
iface eth0 inet6 static
        address fd18:76a0:3427:201::2/64
iface eth0 inet6 auto

IPv6: token or DHCP

/etc/network/interfaces
iface eth1 inet6 dhcp #DHCPv6

DHCPv4 DUID identifier

ifupdown sends dhclient -i Flag (use DHCPv6 DUID for v4) by default now. To revert backt to MAC-Address set following item in dhclient.conf:1)

/etc/dhcp/dhclient.conf
send dhcp-client-identifier = hardware;

or this option in /etc/network/interface:2)

/etc/network/interfaces
iface eth0 inet dhcp
    client no

IPv6 Token

add token addr and fe80 with that number

/etc/network/interfaces
iface eth0 inet6 auto
        pre-up /sbin/ip token set ::40 dev eth0
        up /sbin/ip -6 addr add fe80::40/64 dev eth0

3)

/app/www/public/data/pages/knowledge_base/linux/ipconfig/ifupdown.txt · Zuletzt geändert: 2025/02/19 14:50 von julian.lemmerich