測(cè)試環(huán)境:
OS:Redhat 9.0 (vmware虛擬機(jī)中安裝的)
Kernel version:2.4.20-8
所需軟件:
rp-pppoe-3.5-8.i386.rpm
rp-pppoe-3.5.tar.gz
軟件下載可在ftp://61.139.52.111/Linux/Other/下找到
ADSL Modem類型:
SmartAX MT800 華為的產(chǎn)品
內(nèi)置IP為192.168.1.1
配置過程:
1、 網(wǎng)卡配置。
eth0為撥號(hào)網(wǎng)卡,IP:192.168.1.2掩碼均為255.255.255.0
2、 PPPoE軟件的升級(jí)與安裝
安裝rp-pppoe。以root身份執(zhí)行
rpm -Uvh rp-pppoe-3.5-8.i386.rpm
2‘ 如果是通過源代碼安裝的話。請(qǐng)按下面的步驟進(jìn)行
tar zxvf rp-pppoe-3.5.tar.gz
cd rp-pppoe-3.5
./go
在上面的go運(yùn)行時(shí),系統(tǒng)自動(dòng)會(huì)進(jìn)行以下3的步驟。
3、 PPPoE客戶端配置
在rp-pppoe-3.5-8.i386.rpm安裝完畢后,接下來就可進(jìn)行PPPoE客戶端配置了。過程如下。
#/usr/sbin/adsl-setup
>>> Enter your PPPoE user name: ——此處輸入撥號(hào)賬號(hào)的用戶名
>>> Enter the Ethernet interface connected to the ADSL modem For Solaris, this is likely to be something like /dev/hme0. For Linux, it will be ethn, where n is a number. (default eth0): ——輸eth0
>>> Enter the demand value (default no): ——輸no
>>> Enter the DNS information here: ——直接回車好了
>>> Please enter your PPPoE password: ——輸入撥號(hào)上網(wǎng)的口令
>>> Choose a type of firewall (0-2): ——輸0
>>> Accept these settings and adjust configuration files (y/n)? ——輸y
4、 撥號(hào)連接管理
啟動(dòng):
adsl-start
成功連接后,屏幕顯示Connected。
此時(shí)這臺(tái)linux已可以上網(wǎng)瀏覽了。
關(guān)閉:
adsl-stop
測(cè)試當(dāng)前ADSL連接狀態(tài):
adsl-status
5、 開機(jī)自啟動(dòng)
為了使Linux服務(wù)器能夠自動(dòng)撥號(hào),執(zhí)行下面步驟。
1)chkconfig --add adsl
2)ntsysv
3)選中ADSL
4)OK退出
疑難問題:
1、撥號(hào)成功了,可不能上網(wǎng)?
這個(gè)問題比較復(fù)雜,參考doc/HOW-TO-CONNECT文檔
發(fā)現(xiàn)下面一些東西:
DO NOT assign an IP address to the Ethernet card. DO NOT configure the
card to come up at boot time.
就是說在使用ADSL撥號(hào)上網(wǎng)時(shí),不需要設(shè)定網(wǎng)卡的一些屬性什么的。我已經(jīng)設(shè)置了,那又該怎么辦呢?
很簡(jiǎn)單:先ifconfig eth0 down然后重新adsl-setup多半就可以了。
本站僅提供存儲(chǔ)服務(wù),所有內(nèi)容均由用戶發(fā)布,如發(fā)現(xiàn)有害或侵權(quán)內(nèi)容,請(qǐng)
點(diǎn)擊舉報(bào)。