网络管理器报告:
device not managed
输出sudo lshw -C Network
:
*-network DISABLED
description: Ethernet interface
product: RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller
vendor: Realtek Semiconductor Co., Ltd.
physical id: 0
bus info: pci@0000:02:00.0
logical name: enp2s0
version: 15
serial: 2c:60:0c:f6:97:a6
size: 10Mbit/s
capacity: 1Gbit/s
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress msix bus_master cap_list ethernet physical tp 10bt 10bt-fd 100bt 100bt-fd 1000bt-fd autonegotiation
configuration: autonegotiation=on broadcast=yes driver=r8168 driverversion=8.042.00-NAPI duplex=full latency=0 link=no multicast=yes port=twisted pair speed=10Mbit/s
resources: irq:47 ioport:4000(size=256) memory:c4404000-c4404fff memory:c4400000-c4403fff
*-network
description: Wireless interface
product: QCA9377 802.11ac Wireless Network Adapter
vendor: Qualcomm Atheros
physical id: 0
bus info: pci@0000:03:00.0
logical name: wlp3s0
version: 30
serial: 48:e2:44:46:07:ab
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
configuration: broadcast=yes driver=ath10k_pci driverversion=4.8.0-34-generic firmware=WLAN.TF.1.0-00267-1 ip=192.168.1.101 latency=0 link=yes multicast=yes wireless=IEEE 802.11
resources: irq:53 memory:c4200000-c43fffff
输出nmcli d
:
DEVICE TYPE STATE CONNECTION
wlp3s0 wifi connected FASTWEB***************
enp2s0 ethernet unmanaged --
lo loopback unmanaged --
输出ifconfig
:
lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 1 (Local Loopback)
RX packets 2487 bytes 383935 (383.9 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 2487 bytes 383935 (383.9 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
wlp3s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.101 netmask 255.255.255.0 broadcast 192.168.1.255
inet6 2001:b07:6452:4630:d631:dc14:aa32:46e7 prefixlen 64 scopeid 0x0<global>
inet6 fe80::7932:6d1f:e49b:9b8d prefixlen 64 scopeid 0x20<link>
ether 48:e2:44:46:07:ab txqueuelen 1000 (Ethernet)
RX packets 29742 bytes 30300740 (30.3 MB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 22589 bytes 4019841 (4.0 MB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
输出ip a
:
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1
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: enp2s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
link/ether 2c:60:0c:f6:97:a6 brd ff:ff:ff:ff:ff:ff
3: wlp3s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
link/ether 48:e2:44:46:07:ab brd ff:ff:ff:ff:ff:ff
inet 192.168.1.101/24 brd 192.168.1.255 scope global dynamic wlp3s0
valid_lft 42392sec preferred_lft 42392sec
inet6 2001:b07:6452:4630:d631:dc14:aa32:46e7/64 scope global noprefixroute
valid_lft forever preferred_lft forever
inet6 fe80::7932:6d1f:e49b:9b8d/64 scope link
valid_lft forever preferred_lft forever
我该如何解决?
答案1
在终端中运行此命令(然后重新启动):
sudo touch /etc/NetworkManager/conf.d/10-globally-managed-devices.conf
当我将 Ubuntu 从 16.04 升级到 16.10 时,它修复了类似的问题。
答案2
您的设备存在,但系统因某种原因拒绝管理它。
要解决此问题,请确保您的/etc/network/interfaces
文件不包含以太网设备的定义。在终端中,运行以下命令:
sudo cp /etc/network/interfaces /etc/network/interfaces.bak
sudo nano /etc/network/interfaces
删除除这三行之外的所有行(除非你有非常有充分的理由保留其他行):
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback
然后,通过重新启动或运行以下命令重新启动网络管理器:
sudo service network-manager restart
或者,您可以通过网络管理器启用所有接口的管理,但请注意,这可能会导致其他与网络相关的问题。
在 中/etc/NetworkManager/NetworkManager.conf
,将任何一行更改为以下内容managed=false
:
managed=true
请务必通过重新启动或使用上述命令重新启动 NetworkManager。