我有两个 USB WiFi 适配器(我们称它们为wlx1和wlx2),我想将它们连接到我的机器(Ubuntu Server 20.10)。我无法同时连接两个适配器,如果我尝试sudo netplan --debug apply
我会收到以下错误:
A dependency job for netplan-wpa-wlx2.service failed. See 'journalctl -xe' for details.
输出journalctl -xe
:
Apr 23 20:27:19 my-machine systemd[1]: sys-subsystem-net-devices-wlx2.device: Job sys-subsystem-net-devices-wlx2.device/start timed out.
Apr 23 20:27:19 my-machine systemd[1]: Timed out waiting for device /sys/subsystem/net/devices/wlx2.
这很明显,因为wlx2在物理上没有连接。
内容/etc/netplan/00-installer-config.yaml
(静态IP配置):
# This is the network config written by 'subiquity'
network:
ethernets:
enp3s0:
optional: true
dhcp4: no
addresses:
- 192.168.2.60/24
gateway4: 192.168.2.1
nameservers:
addresses: [8.8.8.8, 1.1.1.1]
version: 2
wifis:
wlx1:
optional: true
access-points:
"my-ssid":
password: "*******"
dhcp4: no
addresses:
- 192.168.2.60/24
gateway4: 192.168.2.1
nameservers:
addresses: [8.8.8.8, 1.1.1.1]
wlx2:
optional: true
access-points:
"my-ssid":
password: "*******"
dhcp4: no
addresses:
- 192.168.2.60/24
gateway4: 192.168.2.1
nameservers:
addresses: [8.8.8.8, 1.1.1.1]
是否可以选择告诉 netplan 该设备可能尚未连接?