mirror of
https://github.com/systemd/systemd.git
synced 2026-08-04 15:10:33 +00:00
Merge pull request #29767 from poettering/host-to-host
automatic support for host-to-host networking that only does link-local addressing
This commit is contained in:
15
TODO
15
TODO
@@ -133,16 +133,11 @@ Deprecations and removals:
|
||||
|
||||
Features:
|
||||
|
||||
* hwdb: add a new field that can be used to mark network devices where only
|
||||
ipv4ll/ipv6ll makes sense, i.e. which should not expect to be connected to
|
||||
the internet, i.e. for direct host-to-host connection. Set it for thunderbolt
|
||||
networking, and for "laplink"-style network cables. Then make netword match
|
||||
against that prop in a .network file we ship by default. Would be
|
||||
particularly useful in storage target mode (i.e. NVME-TCP) modes. i.e. do
|
||||
what https://christian.kellner.me/2018/05/24/thunderbolt-networking-on-linux/
|
||||
and
|
||||
https://github.com/NetworkManager/NetworkManager/blob/main/data/90-nm-thunderbolt.rules#L11
|
||||
do for NM, but generically.
|
||||
* networkd: controlled by build-time options install some of the
|
||||
*.network.example files we install currently as regular files *.network. For
|
||||
many cases it's what you want: just configure the damn network. Hopefully
|
||||
this can be enabled on Fedora even, though into a separate sub-RPM, so that
|
||||
we don't conflict with NM.
|
||||
|
||||
* add support for activating nvme-oF devices at boot automatically via kernel
|
||||
cmdline, and maybe even support a syntax such as
|
||||
|
||||
12
hwdb.d/82-net-auto-link-local.hwdb
Normal file
12
hwdb.d/82-net-auto-link-local.hwdb
Normal file
@@ -0,0 +1,12 @@
|
||||
# This file is part of systemd.
|
||||
|
||||
# Network interfaces for which only Link-Local communication (i.e. IPv4LL, …)
|
||||
# makes sense, because they almost certainy will point to another host, not an
|
||||
# internet router.
|
||||
|
||||
# (Note: matches against drivers go into 82-net-auto-link-local.rules instead)
|
||||
|
||||
# Prolific USB-to-USB links (https://www.prolific.com.tw/US/ShowProduct.aspx?pcid=43)
|
||||
usb:v067Bp25A1*
|
||||
usb:v067Bp27A1*
|
||||
ID_NET_AUTO_LINK_LOCAL_ONLY=1
|
||||
21
network/80-auto-link-local.network.example
Normal file
21
network/80-auto-link-local.network.example
Normal file
@@ -0,0 +1,21 @@
|
||||
# SPDX-License-Identifier: MIT-0
|
||||
#
|
||||
# This example config file is installed as part of systemd.
|
||||
# It may be freely copied and edited (following the MIT No Attribution license).
|
||||
#
|
||||
# To use the file, one of the following methods may be used:
|
||||
# 1. add a symlink from /etc/systemd/network to the current location of this file,
|
||||
# 2. copy the file into /etc/systemd/network or one of the other paths checked
|
||||
# by systemd-networkd and edit it there.
|
||||
# This file should not be edited in place, because it'll be overwritten on upgrades.
|
||||
|
||||
# Enable IPv4LL + IPv6LL (but no DHCP/IPv6RA) for local links
|
||||
[Match]
|
||||
Type=ether
|
||||
Property=ID_NET_AUTO_LINK_LOCAL_ONLY=1
|
||||
|
||||
[Network]
|
||||
LinkLocalAddressing=yes
|
||||
DHCP=no
|
||||
IPv6AcceptRA=no
|
||||
MulticastDNS=yes
|
||||
15
rules.d/82-net-auto-link-local.rules
Normal file
15
rules.d/82-net-auto-link-local.rules
Normal file
@@ -0,0 +1,15 @@
|
||||
# do not edit this file, it will be overwritten on update
|
||||
|
||||
ACTION=="remove", GOTO="net_link_local_end"
|
||||
SUBSYSTEM!="net", GOTO="net_link_local_end"
|
||||
|
||||
# Network interfaces for which only Link-Local communication (i.e. IPv4LL, …)
|
||||
# makes sense, because they almost certainy will point to another host, not an
|
||||
# internet router.
|
||||
|
||||
# (Note: matches against VID/PID go into 82-net-auto-link-local.hwdb instead)
|
||||
|
||||
# Thunderbolt host-to-host connections
|
||||
DRIVERS=="thunderbolt-net", ENV{ID_NET_AUTO_LINK_LOCAL_ONLY}="1"
|
||||
|
||||
LABEL="net_link_local_end"
|
||||
Reference in New Issue
Block a user