MMDVM联网模式:Wi-Fi优先或4G优先

MMDVM298

一、SSH 登录

pi-star 
raspberry

 文章源自-https://bh8sel.com/6373.html

二、查看优先联网模式

route -n 

# 看Metric数值,越小越优先。

#看Iface数值,4G网卡:usb0 /eth1 / ppp0;Wi-Fi:wlan0,视情形把下面命令里的 usb0 换成 eth1 或 ppp0 即可。

 文章源自-https://bh8sel.com/6373.html

三、进入 /etc/dhcpcd.conf 配置文件

sudo nano /etc/dhcpcd.conf

 文章源自-https://bh8sel.com/6373.html

四、在dhcpcd.conf底部加上如下优先模式:

Wi-Fi 优先:
interface wlan0
metric 10

interface usb0
metric 100
4G 优先:
interface usb0
metric 10

interface wlan0
metric 100

 文章源自-https://bh8sel.com/6373.html

五、Ctrl+O → 回车保存,Ctrl+X退出。

 文章源自-https://bh8sel.com/6373.html

六、重启生效

sudo systemctl restart dhcpcd
文章源自-https://bh8sel.com/6373.html文章源自-https://bh8sel.com/6373.html
 
评论  2  访客  2
    • 333985
      333985

      无话可说,只是看看

      • 风月的朋友
        风月的朋友

        站主你好,偶然路过贵站,内容是花了心思的,很喜欢。
        我们做AI角色扮演向的交流社区「风月」,卡片、世界书、多模型角色对话之类,风格偏安静那种。如果方便的话欢迎去看看:fengyue.fun
        有机会互相串门,祝更新顺利 :)

      匿名

      发表评论

      匿名网友
      确定

      拖动滑块以完成验证