我刚买一个新的USB 3.0 千兆以太网适配器我无法在 Ubuntu 18.04.1 服务器 x64 版本中安装它。
我联系了 tp-link 支持,他们给我发了驱动程序。我安装了驱动程序,但我的适配器仍然没有互联网连接。我按照这个脚步但没有任何成功。
有人能帮我解决这个问题吗?
编辑:
Output of `ifconfig`
enp19s0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
ether 78:2b:cb:e9:d5:3c txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
enx503eaa8b183c: flags=4098<BROADCAST,MULTICAST> mtu 1500
ether 50:3e:aa:8b:18:3c txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
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 1000 (Local Loopback)
RX packets 226 bytes 15022 (15.0 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 226 bytes 15022 (15.0 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
wlp18s0: flags=4098<BROADCAST,MULTICAST> mtu 1500
ether 18:f4:6a:3f:af:11 txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
输出sudo lshw -c network
*-network DISABLED
description: Wireless interface
product: AR9285 Wireless Network Adapter (PCI-Express)
vendor: Qualcomm Atheros
physical id: 0
bus info: pci@0000:12:00.0
logical name: wlp18s0
version: 01
serial: 18:f4:6a:3f:af:11
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
configuration: broadcast=yes driver=ath9k driverversion=4.15.0-38-generic firmware=N/A latency=0 link=no multicast=yes wireless=IEEE 802.11
resources: irq:17 memory:fbc00000-fbc0ffff
*-network
description: Ethernet interface
product: RTL8101/2/6E PCI Express Fast/Gigabit Ethernet controller
vendor: Realtek Semiconductor Co., Ltd.
physical id: 0
bus info: pci@0000:13:00.0
logical name: enp19s0
version: 02
serial: 78:2b:cb:e9:d5:3c
size: 10Mbit/s
capacity: 100Mbit/s
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress msix vpd bus_master cap_list rom ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd autonegotiation
configuration: autonegotiation=on broadcast=yes driver=r8169 driverversion=2.3LK-NAPI duplex=half latency=0 link=no multicast=yes port=MII speed=10Mbit/s
resources: irq:18 ioport:e000(size=256) memory:d0b10000-d0b10fff memory:d0b00000-d0b0ffff memory:fb200000-fb21ffff
*-network DISABLED
description: Ethernet interface
physical id: 2
logical name: enx503eaa8b183c
serial: 50:3e:aa:8b:18:3c
size: 100Mbit/s
capacity: 1Gbit/s
capabilities: ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd 1000bt 1000bt-fd autonegotiation
configuration: autonegotiation=on broadcast=yes driver=r8152 driverversion=v1.09.9 duplex=full link=no multicast=yes port=MII speed=100Mbit/s
/etc/netplan/01-netcfg.yaml 中的文件名称
内容/etc/netplan/01-netcfg.yaml
# This file describes the network interfaces available on your system
# For more information, see netplan(5).
network:
version: 2
renderer: networkd
ethernets:
enp19s0:
dhcp4: yes
先感谢您。
答案1
尝试这个...
在terminal
...
cd /etc/netplan
# 更改目录
sudo cp 01-netcfg.yaml 01-netcfg.HOLD
# 备份文件
sudo pico 01-netcfg.yaml
# 编辑文件
用这个替换你在那里看到的东西……
# This file describes the network interfaces available on your system
# For more information, see netplan(5).
network:
version: 2
renderer: networkd
ethernets:
enp19s0:
dhcp4: yes
optional: true
enx503eaa8b183c:
dhcp4: yes
optional: true
然后...
sudo netplan generate
# 生成配置文件
sudo netplan apply
# 应用新配置
reboot
# 重启系统
回顾一下之前的瘦身和是否配置命令来检查操作。
答案2
我遇到了类似的问题,并通过执行以下操作使卡正常工作:
sudo ip l s dev enx503eaa8b183c up
答案3
这里是 18.04.3,使用 TP-Link TG-3468。我必须执行以下操作:
sudo ip l s dev enp6s0 up
然后我修改/etc/netplan/01-network-manager-all.yaml
成这样:
network:
version: 2
renderer: NetworkManager
ethernets:
enp6s0:
match:
macaddress: "12:34:56:78:90:12"
set-name: enp6s0
dhcp4: true
dhcp-identifier: mac
critical: true
nameservers:
addresses: ["<LAN IP address of router>"]
然后
sudo netplan --debug generate
sudo netplan apply
sudo reboot