VMware Ubuntu 无网卡驱动怎么办?

网上拷了一个VMware的Ubuntu系统,结果网络没法连接。

ifconfig命令一看,只有lo的本地回环网卡,没有真实网卡驱动。

很简单,一下三步就可以搞定。

首先,iplink show查看本地所有网卡。

我这里出现了一个ens33的网卡驱动,

ens33: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500

inet xxxxxx netmask 255.255.255.0 broadcast 192.168.0.255

inet6 fe80::20c:29ff:fe27:7ee8 prefixlen 64 scopeid 0x20<link>

ether 00:0c:29:27:7e:e8 txqueuelen 1000 (以太网)

RX packets 29 bytes 3043 (3.0 KB)

RX errors 0 dropped 0 overruns 0 frame 0

TX packets 66 bytes 8959 (8.9 KB)

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 (本地环回)

RX packets 3059 bytes 219302 (219.3 KB)

RX errors 0 dropped 0 overruns 0 frame 0

TX packets 3059 bytes 219302 (219.3 KB)

TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

所以,我们这里就需要激活这个网卡驱动就行。

命令:sudo ifconfig ens33 up

然后,开启虚拟机的桥接模式,我这里是WiFi,所以选这个,大家自己可以尝试尝试。

最后,开启dhcp,分配IP

命令:sudo dhclient ens33

再重启网卡即可。sudo /etc/network-manager restart(可用可不用)

最后,自己ping一下baidu就可以了。

相关推荐
Zach_yuan4 小时前
深入浅出 JSONCpp
linux·服务器·网络·c++
AtoposのCX3304 小时前
Docker运行hello-world镜像失败或超时
运维·docker
北京迅为5 小时前
《【北京迅为】itop-3568开发板NPU使用手册》- 第 7章 使用RKNN-Toolkit-lite2
linux·人工智能·嵌入式·npu
Dragon~Snow5 小时前
Linux Centos9 安装 Elasticsearch
linux·elasticsearch·jenkins
熊延5 小时前
麒麟V10系统安装部署elasticsearch
linux·运维·服务器·elasticsearch·搜索引擎·全文检索
Jia ming5 小时前
跟踪器与事件使用举例
linux·事件·跟踪器
生活很暖很治愈6 小时前
Linux——基础IO&软硬链接
linux·ubuntu
2401_858936886 小时前
【Linux C 编程】标准 IO 详解与实战:从基础接口到文件操作实战
linux·c语言
Roc.Chang6 小时前
Ubuntu 下 VLC 无法启动(Segmentation fault)终极解决方案
linux·ubuntu·vlc·媒体播放
松涛和鸣7 小时前
72、IMX6ULL驱动实战:设备树(DTS/DTB)+ GPIO子系统+Platform总线
linux·服务器·arm开发·数据库·单片机