Openwrt 命令行升级系统
时间:2017-1-13 15:51 热度:12360° 评论:0 条

下面我们要使用 sysupgrade (命令) 更新固件。
在浏览器里登录 网管地址 进行固件升级是比较简单的。今天我们要尝试的的是命令行刷机升级。命令行的方式更强大。
SSH登录路由器
在linux/ win10 linux子系统 /win软件Xshell等等,打开命令行终端,输入:
ssh [email protected](网关地址)输入密码,登录成功。
进入OpenWrt /tmp目录
cd /tmp检查OpenWrt路由器是否有足够的内存
df -h可以看出, /tmp 还有29.5MB可用空间,而升级固件在3MB左右,足够了.
下载OpenWrt固件
下载固件 可以去openwrt官网 也可以去pandora官网 选择对应架构下载对应镜像
按Ctrl+F查找自己的路由器型号。比如我输入的是 7620, 有两个固件,升级用的是 sysupgrade.bin文件。右键点击该链接,复制下载地址。
回到命令行终端, 下载固件到 /tmp 目录。
root@OpenWrt:/tmp# wget http://downloads.openwrt.org/snapshots/trunk/xxx/generic/openwrt-xxx.binmd5校验,确保下载的固件完整:
root@OpenWrt:/tmp# wget http://downloads.openwrt.org/snapshots/trunk/xxx/generic/md5sums root@OpenWrt:/tmp# md5sum -c md5sums 2> /dev/null | grep OK openwrt-ar71xx-generic-xxx-squashfs-sysupgrade.bin: OK输出结尾是OK,说明固件是完整的。
OpenWrt sysupgrade命令升级OpenWrt固件
root@OpenWrt:/tmp# sysupgrade -v openwrt-ar71xx-generic-xxxsquashfs-sysupgrade.bin ... Upgrade completed Rebooting system...过约2分钟,等路由器重启成功,如果没有意外,会发现有线和无线上网都正常。(如果是官方固件还需要开启wifi 安装luci等等)


捐赠支持:如果觉得这篇文章对您有帮助,请“扫一扫”鼓励作者!
相关文章- openwrt & nfc 每日进度2014/08/13
- ipset for dnsmasq
- openwrt 15.05 CC (非trunk 而是15.05 现在官方应该只到rc3 ) ar71xx 部分固件
- v2hxray-doc
- 玩转 openwrt 2
- S和谐社会S + ChnRoute OpenWRT 路由器自动F和谐Q 基于付费S和谐社会S修改版
- OpenWrt for Mini6410/Tiny6410 with GTK,QT,OpenCV
- gcc 从5.3升级到6.1之后 openwrt pkg-config glib编译报错修复办法
- openwrt 英文官网下的几个主流版本
- 香港DNS 付线路优化(s和谐社会s+chinadns)
本文作者:沁雨寒 文章标题: Openwrt 命令行升级系统
本文地址:https://blog.sxx1314.com/openwrt/434.html
版权声明:若无注明,本文皆为“unix 软硬件 技术宅 ”原创,转载请保留文章出处。百度已收录
本文地址:https://blog.sxx1314.com/openwrt/434.html
版权声明:若无注明,本文皆为“unix 软硬件 技术宅 ”原创,转载请保留文章出处。百度已收录















