close
STEP 1. 修改 /etc/ppp/ppp.conf

#################################################################
# PPP Sample Configuration File
# Originally written by Toshiharu OHNO
# Simplified 5/14/1999 by wself@cdrom.com
#
# See /usr/share/examples/ppp/ for some examples
#
# $FreeBSD: src/etc/ppp/ppp.conf,v 1.10 2004/11/19 17:12:56 obrien Exp $
#################################################################

default:
set log Phase Chat LCP IPCP CCP tun command
ident user-ppp VERSION (built COMPILATIONDATE)

# Ensure that "device" references the correct serial port
# for your modem. (cuad0 = COM1, cuad1 = COM2)
#
set device PPPoE:sk0 //加入此行 sk0為網卡裝置名稱

set speed 115200
set dial "ABORT BUSY ABORT NO\\sCARRIER TIMEOUT 5 \
\"\" AT OK-AT-OK ATE1Q0 OK \\dATDT\\T TIMEOUT 40 CONNECT"
set timeout 180 # 3 minute idle timer (the default)
enable dns # request DNS info (for resolv.conf)

papchap:
#
# edit the next three lines and replace the items in caps with
# the values which have been assigned by your ISP.
#

set phone PHONE_NUM
set authname xxxxxx@ip.hinet.net 帳號
set authkey xxxxxx 密碼
set dial 設定撥接
set login 登入
set ifaddr 10.0.0.1/0 10.0.0.2/0 255.255.255.0 0.0.0.0
add default HISADDR # Add a (sticky) default route

STEP 2.修改 /etc/rc.conf

ppp_enable="YES" <- 開機自動啟用 PPPoE 連線
ppp_mode="ddial" <- 連接方式為撥接
ppp_profile="papchap" <- 啟動 PPPoE 的撥接名稱,剛才說要記得的部份
ppp_user="root" <-使用者為 root


參考來源:http://blog.pixnet.net/bojack/post/4305438
arrow
arrow
    全站熱搜
    創作者介紹
    創作者 daky 的頭像
    daky

    奇幻世界 賦予你奇妙的感覺

    daky 發表在 痞客邦 留言(0) 人氣()