我有以下网卡:
Bus 001 Device 002: ID 12d1:1506 Huawei Technologies Co., Ltd. Modem/Networkcard
它可以通过ip
工具访问并正确使用dhcpcd
(下面输出中的第三个条目):
$ ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: enp5s0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc fq_codel state DOWN group default qlen 1000
link/ether bc:5f:f4:3a:84:84 brd ff:ff:ff:ff:ff:ff
3: wwp0s18f2u1i1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN group default qlen 1000
link/ether 0c:5b:8f:27:9a:64 brd ff:ff:ff:ff:ff:ff
inet 192.168.8.100/24 brd 192.168.8.255 scope global wwp0s18f2u1i1
valid_lft forever preferred_lft forever
inet6 fe80::48d6:a9ee:6db4:1236/64 scope link
valid_lft forever preferred_lft forever
但NetworkManager
似乎忽略了它:
$ nmcli device show
GENERAL.DEVICE: enp5s0
GENERAL.TYPE: ethernet
GENERAL.HWADDR: BC:5F:F4:3A:84:84
GENERAL.MTU: 1500
GENERAL.STATE: 20 (unavailable)
GENERAL.CONNECTION: --
GENERAL.CON-PATH: --
WIRED-PROPERTIES.CARRIER: off
GENERAL.DEVICE: lo
GENERAL.TYPE: loopback
GENERAL.HWADDR: 00:00:00:00:00:00
GENERAL.MTU: 65536
GENERAL.STATE: 10 (unmanaged)
GENERAL.CONNECTION: --
GENERAL.CON-PATH: --
IP4.ADDRESS[1]: 127.0.0.1/8
IP4.GATEWAY: --
IP6.ADDRESS[1]: ::1/128
IP6.GATEWAY: --
我可以继续使用此连接,但有时dhcpcd
我需要连接,并且不允许我建立连接,除非确保我有连接。VPN
NetworkManager
VPN
LAN
答案1
将 /etc/NetworkManager/NetworkManager.conf 更改 [ifupdown] managed=false
为[ifupdown] managed=true