智能路由器-OpenWRT系列一(OpenWRT刷机)
智能路由器-OpenWRT系列⼀(OpenWRT刷机)
现在没有了⽹络,估计⼤家都不知道该怎么消遣娱乐了。电影、⾳乐、聊天、视频、⽹络资讯,缺了⽹络,什么都搞不起。不过随着上⽹的时间越来越久,就会发现家庭⽹络不
怎么好⽤,或者说是家⾥的路由器不怎么好⽤。带宽越来越快,影⾳下载速度飞快,下载的电影没地⽅放,放在电脑上占空间,⽽且共享给家庭中的其他设备使⽤也⿇烦,电脑
不能整天的开机吧;偶尔想科学上⽹,电脑上配置起来也很⿇烦,同样没法共享给其他设备;做个家庭智能⽹关,还需要专门买个设备。路由器全天开机,应该最适合做这些事
情呀。
是时候给路由器升级⼀下,换个系统了。好多⼚商,⼩⽶、360、极路由都⽣产了基于OpenWRT系统的智能路由器,功能强⼤。除了这些路由器,OpenWRT还⽀持给很多路由
器刷机。根据我的⽇常使⽤,整理了⼀系列基本的OpenWRT使⽤⽅法,第⼀篇先介绍如何给路由器刷OpenWRT系统。
OpenWRT是⼀个⾼度模块化、⾼度⾃动化的嵌⼊式Linux系统,拥有强⼤的⽹络组件和扩展性,常常被⽤于⼯控设备、电话、⼩型机器⼈、智能家居、路由器以及VOIP设备
中。同时,它还提供了100多个已编译好的软件,⽽且数量还在不断增加,⽽ OpenWrt SDK 更简化了开发软件的⼯序。
OpenWrt 项⽬由 2004 年 1 ⽉开始, 第⼀个版本是基于 Linksys 提供的 GPL 源码及 uclibc 中的 buildroot 项⽬, 这个版本称为 “stable” 版, 在⽹上⾄今仍有很多项⽬使⽤这个版本,
较为有名 Freifunk-Firmware 和 Sip@Home.
到了2005年初, ⼀些新的开发⼈员加⼊了这项⽬, ⼏个⽉后他们释出了第⼀个 “experimental” 版本, 这和以前版本不同的是, 这版本差不多完全舍弃了 Linksys 的 GPL 源码, 使⽤了
buildroot2 作为核⼼技术, 将 OpenWrt 完全模块化,OpenWrt 使⽤ Linux 正式发⾏的核⼼源码(2.4.30),加上了⼀些补丁和⽹络驱动,开发队伍更为OpenWrt添加了许多免费的
⼯具,可以直接把Image写⼊ Flash (mtd)⾥⾯,设定⽆线功能和VLAN交换功能,这个版本名为“White Russian”,⽽1.0版本于2005年底公布。
判断路由器是否⽀持OpenWRT
OpenWRT官⽅⽀持的路由器有⼀份列表,如果在这份表格内,就可以直接下载官⽅编译好的固件直接刷机。如果不在这个表格内,就需要搜索⼀下,是否有⽹友⾃⼰编译好的
两会开几天
固件,或者编译步骤,按照这个编译步骤⾃⼰搭建编译环境编译。
可以看到,常见的路由器品牌,如TP-Link、D-Link、Buffalo、Asus、Huawei、Linksys、Mercury、MikroTik、Netgear都有不少⽀持的版本。点击设备名称可以进⼊详细的设
备介绍,可以看到设备的硬件信息、⽀持情况等。
固件下载
generic、mikrotik、nand这些是同⼀平台的特殊硬件⽀持,generic、nand是两种不同的flash memory类型,mikrotik是特定于mikrotik路由器硬件。如果在硬件的详细页⾯中,没
抖音怎么直播有特殊说明flash类型,则选择generic。
进⼊后就可以看到具体的固件,基本的后缀有⼀下⼏种:
凡包含factory字样的,是在原机界⾯上直接刷机⽤的。bin、img根据原⼚的不同有所区别,如bin⽤在TP-Link系列上,img⽤在⽹件Netgare上。三国2007
包含sysupgrade字样的,是在OpenWRT系统⾥的界⾯,更新固件⽤的。tftp固件是⽤tftp⽅式刷机⽤的。⽹件和巴法络都⽀持tftp⽅式刷机。
tar格式是直接在界⾯上传刷机,不需要解压,在刷机的时候它⾃动在路由⾥进⾏解压。
openwrt-*-factory.bin      标准镜像,⽤于⼯⼚刷机模式,⼀般使⽤squashfs的⽂件
openwrt-*-factory.img      标准镜像,⽤于⼯⼚刷机模式
openwrt-*-sysupgrade.bin  标准镜像,⽤于系统升级模式,⼀般使⽤squashfs的⽂件
openwrt-*-sysupgrade.tar
openwrt-*-tftp.bin        标准镜像,⽤于tftp刷机模式,⼀般使⽤squashfs的⽂件
TP-Link 刷OpenWRT中专有哪些专业
1. 根据上⾯的内容,到对应的openwrt固件,下载好*-factory.bin 刷机固件
2. 进⼊tp-link,管理页⾯
3. 选择[系统⼯具]->[软件升级]->[浏览选择固件]->点击[升级]
等待1-2分钟后,刷机OK,就可以开始初始配置了。初始配置请看下⼀篇
D-link 刷OpenWRT
固件升级模式
1. 下载好对应的factory固件
2. 进⼊管理页⾯,点击界⾯上部的【维护】,然后点击左侧栏的【固件】进⼊升级固件页⾯
3. 选择【浏览】,选中下载好的对应固件,【升级】
4. 等待1-2分钟,系统重启。完成升级
5. 初始配置请看下⼀篇 [OpenWRT 初始化配置]
固件恢复模式
Phase 1: OS specific quirks
Note: The firmware recovery mode has following quirks:
If you have a Windows machine available you can use Microsoft Internet Explorer 7 (a Windows running on a VM, like VMware, does not work)
* Windows 8: Firefox cannot be used to update firmware (presumably applies to other versions of Windows).
* Windows 8: Use Internet Explorer 10. Press F12. Select Browser Mode: IE8. Leave the compatibility setting at IE5 Quirks.
* Windows 7: try to turn off ipv6
If you are running Linux you can:
* Ideally use C program below, otherwise:
* Set your interface to 100Mbps using sudo ethtool -s eth0 speed 100 autoneg off, install IE7 in Wine and use it to flash.
* Later models (or some hardware combinations) may need sudo ethtool -s eth0 speed 100 duplex half autoneg off (e.g. B2, FW ver 2.05EU).
* Use the following script.
* firmware 2.02EU should still be available on ftp.dlink.de and it doesn't require IE, nor Mac.
* 2.05EUB09_7 can't be downgraded to 2.04 but fortunately can be downgraded to 2.02EU
* I had to disable both avahi, cups and IPv6 to get it working. (B2 FW ver 2.01EU)
If you are running MacOS you can use Google Chrome Opera
FW version 2.05EU seems very difficult to flash, there may be timing issues (that's just a guess). After downgrading to 2.04EU (get it from ftp.dlink.de) it worked the first time, using IE7 on a virtualbox Win XP "guest". YMMV.
Phase 2: General steps
1. Get into the D-Link recovery console with the steps below:
a. While powering up the router, press and hold the reset button until the power LED starts blinking orange (usually takes around 45 (forty-five) seconds )
b. Set a static IP on your PC to 192.168.0.100/24
c. connect to 192.168.0.1, mind the quirks!
2. Click "Browse" and select your OpenWrt image file (openwrt-ar71xx-dir-825-b1-squashfs-factory.bin, this binary image is available in the Backfire 10.0
3.1rc1 download directory and above)
3. Click "Update" and let router flash the image (don't worry if it reboots before it reaches 100%). The page should display "Device is Upgrading the Firmware" in blue letters with the current percentage in red (with an incompatible Browser it doesn
4. The router's power LED should blink orange during bootup, as soon as it stops flashing, you can connect to it
Tip! Note that default DHCP will allocate on 192.168.1.x, which is different subnet to the address you allocated above. This is why you can't connect until you change your IP address.
初始配置请看下⼀篇
Netgear刷OpenWrt
1. 下载好对应固件
2. 进⼊管理页⾯
3. [⾼级]->[管理]->[路由器升级]->选择固件升级
4. 等待1-2分钟,系统重启。完成升级
5. 初始配置请看下⼀篇 [OpenWRT 初始化配置]
OpenWRT版本升级
升级已经安装OpenWRT的路由器,就需要⽤到下载好的 openwrt-*-sysupgrade.bin 或 openwrt-*-sysupgrade.tar⽂件如果OpenWRT已经安装LuCI Web管理界⾯, 则进⼊系统管理-升级界⾯,选择sysupgrade.tar⽂件进⾏升级
四个字的网名如果未安装LuCI,则需要ssh登陆到路由器,同时把sysupgrade.bin⽂件上传⾄路由器,通过命令⾏升级。sysupgrade -v openwrt-xxx-sysupgrade.bin
这些操作,可以在后⾯的⽂章中详细介绍
其他
其他路由器的刷OpenWRT的⽅法基本类似,就不做过多介绍。
名句大全OpenWRT刷好后就需要进⾏初始化配置,配置完成后才可以联⽹畅游。马上进⼊下⼀篇

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。