一、基础环境选择及搭建
1.支持硬件设备列表:
http://wiki.openwrt.org/toh/start#supported.hardware.-.router.type
- 最佳:
联想 newifi mini 1200M AC 智能无线路由器 双频千兆穿墙 newifi mini纯净版OpenWRT兼容内核固件,集成rt2860v2、mt76x2e驱动
小米路由器mini: http://ngiux.com/miwifi-mini-openwrt-openvpn/ http://blog.csdn.net/huyaoyu/article/details/42810383 http://www.tianruosk.com/technical/yjwj/1904.html
- 可选:
TL-WR842ND http://wiki.openwrt.org/toh/tp-link/tl-wr842nd
TP-LINK WR703N http://www.jb51.net/network/113081.html
番茄dualwan: http://detail.1688.com/offer/1277654521.html
2.系统安装
设备选型:Newifi Mini Y1版本 系统选型:小云xCloud V2.1.0.5900 安装工具:路由助手 1.0.13
3.开启SSH权限
高级设置-系统-管理权,分别设置Lan/Wan两个ssh访问权限
4.登录配置opkg
libc安装
cd /tmp
wget http://mirrors.ustc.edu.cn/openwrt/barrier_breaker/14.07/ramips/mt7620a/packages/base/libc_0.9.33.2-1_ramips_24kec.ipk
## 安装libc
opkg install libc_0.9.33.2-1_ramips_24kec.ipk
ssh 192.168.99.1
opkg update #更新报错了,考虑更换软件源
#软件源参考,同款xCloud可用源http://www.enjoydiy.com/3199.html
vim /etc/opkg.conf
## opkg.conf start
dest root /opt
dest ram /tmp
lists_dir ext /var/opkg-lists
option overlay_root /overlay
arch all 100
arch ramips_24kec 200
arch ramips 300
arch mips 400
arch unkown 500
src/gz barrier_breaker_base http://mirrors.ustc.edu.cn/openwrt/barrier_breaker/14.07/ramips/mt7620a/packages/base
src/gz barrier_breaker_luci http://mirrors.ustc.edu.cn/openwrt/barrier_breaker/14.07/ramips/mt7620a/packages/luci
src/gz barrier_breaker_management http://mirrors.ustc.edu.cn/openwrt/barrier_breaker/14.07/ramips/mt7620a/packages/management
src/gz barrier_breaker_oldpackages http://mirrors.ustc.edu.cn/openwrt/barrier_breaker/14.07/ramips/mt7620a/packages/oldpackages
src/gz barrier_breaker_packages http://mirrors.ustc.edu.cn/openwrt/barrier_breaker/14.07/ramips/mt7620a/packages/packages
src/gz barrier_breaker_routing http://mirrors.ustc.edu.cn/openwrt/barrier_breaker/14.07/ramips/mt7620a/packages/routing
src/gz barrier_breaker_telephony http://mirrors.ustc.edu.cn/openwrt/barrier_breaker/14.07/ramips/mt7620a/packages/telephony
## opkg.conf end
5.opkg常用命令
Package Manipulation:
update Update list of available packages
upgrade <pkgs> Upgrade packages
install <pkgs> Install package(s)
configure <pkgs> Configure unpacked package(s)
remove <pkgs|regexp> Remove package(s)
flag <flag> <pkgs> Flag package(s)
<flag>=hold|noprune|user|ok|installed|unpacked (one per invocation)
Informational Commands:
list List available packages
list-installed List installed packages
list-upgradable List installed and upgradable packages
list-changed-conffiles List user modified configuration files
files <pkg> List files belonging to <pkg>
search <file|regexp> List package providing <file>
find <regexp> List packages whose name or description matches
## 打印帮助
opkg -h
## 更新资源列表
opkg update
## 更新软件版本
opkg upgrade openvpn
## 列出已安装的包
opkg list-installed
## find后安装线上软件
opkg find shadowsocks*
opkg find openvpn*
opkg install openvpn-nossl
## wget后安装本地ipk包
opkg install /tmp/wget_openvpn.ipk
二、进阶配置
系统清理
## opkg 清理
rm -r /tmp/opkg-*