uboot网络操作解决:ARPRetry count exceeded; starting again ping failed; host 192.168.86.128 is not alive

uboot网络操作解决:ARPRetry count exceeded; starting again ping failed; host 192.168.86.128 is not alive

最近在uboot网络操作的时候,如下图所示:uboot去ping虚拟机里的ubuntu发现怎么都ping不了,下面给出解决办法
uboot网络操作解决:ARPRetry count exceeded; starting again ping failed; host 192.168.86.128 is not alive_第1张图片

0、将开发板与电脑处于同一网段内,最简单的办法就是将网线插在同一个路由器下。

1、将虚拟机网络连接设置为桥接模式(B)

uboot网络操作解决:ARPRetry count exceeded; starting again ping failed; host 192.168.86.128 is not alive_第2张图片

2、ifconfig查看ip;然后sudo ifconfig ens33 down,关闭ens33;再次执行ifconfig确认ens33关闭

uboot网络操作解决:ARPRetry count exceeded; starting again ping failed; host 192.168.86.128 is not alive_第3张图片

3、sudo ifconfig ens33 up,开启ens33;ifconfig查看开启后的ip。如我的为192.168.1.101

uboot网络操作解决:ARPRetry count exceeded; starting again ping failed; host 192.168.86.128 is not alive_第4张图片

4、进入uboot,一次执行以下命令

setenv ipaddr 192.168.1.50
setenv ethaddr b8:ae:1d:01:00:00
setenv gatewayip 192.168.1.1
setenv netmask 255.255.255.0
setenv serverip 192.168.1.101
saveenv

注意:1、使用setenv ipaddr 192.168.1.50前可先通过ping 192.168.1.50查看ip是否被占用。
2、setenv ethaddr b8:ae:1d:01:00:00为MAC地址,同一网段内要保证ethaddr不同
3、setenv serverip 192.168.1.101为所要通信的主机地址,例如我的为ubuntu主机ip192.168.1.101

5、通过命令ping 192.168.1.101查看是否通信成功。

注意:只能uboot ping 主机。不能主机 ping uboot。
uboot网络操作解决:ARPRetry count exceeded; starting again ping failed; host 192.168.86.128 is not alive_第5张图片

你可能感兴趣的:(嵌入式Linux学习,网络,ubuntu,linux)