FREEBSD settings under PPPOE
Lu wenzhong [netizen submission]
Hardware requirements: Two PCs with FreeBSD 4.1, one to do server, and other clients.
Both PCs are equipped with Ethernet cards, in this case, NE2000-compatible network cards,
The network interface name is ED0.
Basic configuration: The following kernel configuration is performed on the Server side and Client ends:
Options netgraph
Options netgraph_pppoe
Options netgraph_socket
Options Netgraph_ETHER
Options netgraph_iface
Pseudo-Device Tun
There is also a corresponding Ethernet card driver, for example:
DEVICE ED0 AT ISA? Port 0x300 IRQ 10 IOMEM 0xD8000
Rebate the kernel and start using the new kernel. And run the following command to activate the Ethernet interface:
IFConfig ED0 UP
PPP software is installed on the server side and the client.
Server end configuration:
Get the patch file from the following address:
http://www.freesco.org/~jlin/files/pppoe-server/patch.txt
Execute the following command to patch patch for PPPOED:
# CD / usr / src / libexec / pppoed; enter the PPPOED source code directory
# patch # Make && make Install Write a PPP.conf file similar to: PPPoe: Set log phrase ipcp LCP Debug Allow Mode Direct SET MRU 1492 Set MTU 1492 Set speed sync ENABLE LQR Enable Proxy SET CD 5 SET IFADDR 192.168.1.1 192.168.1.2-192.168.1.12 If you need authentication, you have to join in the PPP.conf file: ENABLE PAP or ENABLE CHAP Write the PPP.Secret file, the file format is: user name password, each user occupies a line. Then start the PPPOED server as follows: / usr / libexec / pppoed -p /var/run/pppoed.pid -p pppoe ED0 The last ED0 is replaced with your NIC interface name. So, Server is OK. Client End Configuration: Write a PPP.conf file similar to: DEFAULT: SET Device PPPoe: ED0 Set speed sync SET MRU 1492 Set MTU 1492 Set CTSRTS OFF ENABLE LQR Set log phse tun Add Default Hisaddr Enable DNS PPPoe: Set Authname Username Set Authkey Password If the server is not required to authenticate, run the command: ppp -ddial, If the server is required to authenticate, use the server-side PPP.Secret file. Username and password replace the above UserName and Password, then run the command: PPP -DDial PPPoe If everything is normal, run the ifconfig command, please pay attention to the TUN0 device, the two PCs have passed The network interface is connected together, there is a prompt: Tun0: 192.168.1.1 Point-to-Point 192.168.1.2 If an error occurs, please check the server and client /var/log/ppp.log responsive files. Find the cause of the error. Main reference articles: How to setup a pppoe server on freebsd 4.1.1-release by jason lin FreeBSD on Telstra's BigPond Adsl Network by Paul Hoadley Cheace Broadband with freebsd on dsl by renaud Waldura