首 页 网站运营 网络编程 网页制作 图象媒体 数据库 建站资源 网管专区 下载专区 最新资讯
IT学堂|红色黑客联盟
设为首页
加入收藏
联系站长
您所在的位置:首页>网管专区>网络组建>文章内容
使用freebsd构建pppoe server服务器
来源: 作者: 发布时间:2007-04-11

相对于在linux下做pppoe server服务器,在freebsd下要简单得多。

一、安装freebsd,安装内核的源码或者用cvsup同步最新的内核源码。

二、重新编译内核。

1. 在内核配置文件中添加以下选项,然后重新编译和安装内核:
options NETGRAPH
options NETGRAPH_PPPOE
options NETGRAPH_SOCKET

2. 编辑 /etc/rc.conf, 添加:
pppoed_enable="YES"
pppoed_flags="-d -P /var/run/pppoed.pid -a "server" -l "default" "
pppoed_interface="fxp1"

3. 编辑/etc/ppp/ppp.conf
default:
 set log Chat Command Phase             #turn on some logging. See man ppp.conf
 enable pap                                          #turn on chap and pap accounting
 enable chap
 allow mode direct                      #turn on ppp bridging
 enable proxy                           #turn on ppp proxyarping (redundant of a
 disable ipv6cp                         #we don't use ipv6, don't want the errors
 set mru 1492                           #set mru below 1500 (PPPoE MTU issue)
 set mtu 1492                           #set mtu below 1500 (PPPoE MTU issue)
 set ifaddr 10.0.0.1 10.0.1.1-10.0.5.254
 set speed sync
 set timeout 0
 enable lqr
 accept dns

4. 编辑 /etc/ppp/ppp.secret 设置好用户名和口令
username password

最后重新启动.

Hint:
You could configure ipfw firewall to deny any to any and then make a script (easy) for every ppp connection to add a rule in firewall to allow ip for that connection.

Valuable Advices:
- If you use different versions of windows boxes (not only xp) let enable pap and chap too
- If you want a user to be connected only once (so users cannot give username and passowords to others to use the same account) you must setup a radius server
(freeradius or radius-cistron, from ports collection).
- If you have problems login in from windows box than set speed sync from /etc/ppp/ppp.conf might help you
- pppoed daemon consumes some cpu so a faster cpu is better, also for many users is better to have more ram (512 or 1024 MB)
- If you have problems stop your pppoed process (/etc/rc.d/pppoed stop) then launch pppoed with -Fd option instead -d, from command line to have pppoed in foreground to see errors.
- On a lan with many users I had a problem, i guess some of the clients had a misconfigured pppoed server so it keeps asking for connection to pppoed server, flooding, forking the pppoed daemon continously. It is a patch that might solve this problem, I've read about it here: http://lists.freebsd.org/pipermail/freebsd-hackers/2005-February/010136.html , but could not find that patch.


[推荐] [返回顶部] [打印本页] [关闭窗口]
热点文章
·动态域名更新的实现方法
·site to site ipsec vpn
·hosspot设置说明
·设置ROUTEROS为透明桥接防火墙
·虚拟路由冗余协议 Virtual Router Red
·使用ROUTEROS建立PPPOE服务器
·如何在ROUTEOS中做IP转向
·ROS下实现数据镜像
·routeros和radius对接设置
·routeros端口映射内网无法访问自身公
相关文章
·FreeBSD + PF + Shell Scritp + Load
·基于freebsd建立内核模式的pppoe服务
·OpenBSD & PF 之橋接 Bridge Mode
·OpenBSD & PF 之基本防火牆設定
·OpenBSD 初體驗
·封包轉換+防火牆+頻寬管理 Natd+Ipfw+
·防火牆+橋接器+頻寬管理 Ipfw+Bridge+
·IPNAT+Ipfilter+Bridge 超級防火牆
·IPNAT+Ipfilter+Squid Transparent Pr
·IPNAT+Ipfilter 超級防火牆調校
文章检索
Google
相关文章
·FreeBSD + PF + Shell S
·基于freebsd建立内核模
·OpenBSD & PF 之橋
·OpenBSD & PF 之基
·OpenBSD 初體驗
·封包轉換+防火牆+頻寬管
·防火牆+橋接器+頻寬管理
·IPNAT+Ipfilter+Bridge
·IPNAT+Ipfilter+Squid T
·IPNAT+Ipfilter 超級防
·FreeBSD 5.3 Release PF
·FreeBSD + Ipfilter NAT
·m0n0wall Embedded Free
·m0n0wall 嵌入式 FreeBS
·802.1x 認證 + 無線 AP