Linksys MR7350 固定启动分区

改完后就不会切换分区了,如果刷挂了就得拆机TTL了

进ssh查看当前的默认bootcmd

1
fw_printenv bootcmd

image

我的是这样的

1
bootcmd=i2c dev 0 && i2c probe && i2c mw 0x62 0x00 0x00 1 && i2c mw 0x62 0x01 0x05 1 && i2c mw 0x62 0x08 0x00 1 && if test $auto_recovery = no; then bootipq; elif test $boot_part = 1; then run bootpart1; else run bootpart2; fi

把打印出来的默认bootcmd存起来,如果后面要恢复的话要还原

查看当前在哪个分区

1
fw_printenv boot_part

image

boot_part=1就说明当前在第一个分区,如果=2就说明是第二个分区

设置bootcmd参数

1
fw_setenv bootcmd 'i2c dev 0 && i2c probe && i2c mw 0x62 0x00 0x00 1 && i2c mw 0x62 0x01 0x05 1 && i2c mw 0x62 0x08 0x00 1 && run bootpart<你想要启动的分区>'

如果要固定启动第一个分区就如下

1
fw_setenv bootcmd 'i2c dev 0 && i2c probe && i2c mw 0x62 0x00 0x00 1 && i2c mw 0x62 0x01 0x05 1 && i2c mw 0x62 0x08 0x00 1 && run bootpart1'

然后重启就不会变分区了,boot_part这个值也就没有用了,所以op里面的高级重启也没有用了

恢复自动切换分区

1
fw_setenv bootcmd '<你刚开始保存的默认bootcmd>'

例如

1
fw_setenv bootcmd 'i2c dev 0 && i2c probe && i2c mw 0x62 0x00 0x00 1 && i2c mw 0x62 0x01 0x05 1 && i2c mw 0x62 0x08 0x00 1 && if test $auto_recovery = no; then bootipq; elif test $boot_part = 1; then run bootpart1; else run bootpart2; fi'

Linksys MR7350 固定启动分区
https://2333.world/_posts/2022_02_24/Linksys-MR7350-固定启动分区/
作者
Yuban10703
发布于
2022年2月24日
许可协议