1 Star 0 Fork 16

Bruceli_1019 / raspi_router

forked from ksc / raspi_router 
Create your Gitee Account
Explore and code with more than 8 million developers,Free private repositories !:)
Sign up
This repository doesn't specify license. Please pay attention to the specific project description and its upstream code dependency when using it.
Clone or Download
contribute
Sync branch
Cancel
Notice: Creating folder will generate an empty file .keep, because not support in Git
Loading...
README.md

#把树莓派打造成智能无线路由器

###使用方法

你可以 用git检出一份

apt-get install git
git clone http://git.oschina.net/ksc/raspi_router

或者直接下载zip压缩包

wget http://git.oschina.net/ksc/raspi_router/repository/archive?ref=master -O t.zip
unzip t.zip
cd raspi_router/

check.py 检查你前几步的设置是否有效 若你用的是openvpn 一般不需要修改,直接运行即可

#若网络设备名称和默认不一致,
cp readme/config.example.ini config.ini 
#将对应的设备名修改

root@coolpi:~/raspi_route# ./check.py
eth0 ok
eth0_ip=192.168.2.11
wlan0 ok
wlan0_ip=192.168.10.1/24
tun0 ok
tun0_ip=10.2.2.10
p-t-p:10.2.2.9
检查通过 请运行一下命令生成 路由及转发脚本
./build_sh.py  

安照提示运行上述命令

root@coolpi:~/raspi_route# ./build_sh.py
/root/raspi_route/route.txt
linux_route.sh 及 linux_nat.sh 已经生成 请运行

然后执行

./linux_route.sh && ./linux_nat.sh

以后若ip信息都没有变化的话 ,直接运行如下命令即可

ifup wlan0 #若wlan0已经启用并获取ip地址了、则不用执行此命令
service hostapd start
service isc-dhcp-server start
openvpn client.conf #具体看你的配置文件而定
./linux_route.sh 
./linux_nat.sh

###最后

  1. route表是我从网上搜集的,只有几个常用的网段,不是很全。
  2. 上述过程我检查了几遍,但难免有疏漏的地方。若您发现请指正

Repository Comments ( 0 )

Sign in to post a comment

About

把你的树莓派改成称无线路由 expand collapse
Python
Cancel

Releases

No release

Contributors

All

Activities

Load More
can not load any more
Python
1
https://gitee.com/bruceli-ten/raspi_router.git
git@gitee.com:bruceli-ten/raspi_router.git
bruceli-ten
raspi_router
raspi_router
master

Search

10d9f8b4 4838521 8bde8327 4838521