redhat下設定ADSL

來源:互聯網
上載者:User
ADSL(rp-pppoe 工具)安裝、使用方法(本文基於 linuxCN 的原創文章修改而成,原文參見:http://www.linuxfans.org/nuke/modules.php?name=Forums&file=viewtopic&t=218&highlight=ADSL)

《配置網卡》
首先運行 netconfig 並選擇 DHCP,儲存、退出。

《安裝 rp-pppoe》
然後下載最新的 rp-pppoe 源碼檔案(Google 裡搜尋一下)並在 root 下安裝,Magic linux 裡預設已經安裝了。
例如:進入linux,解壓 rp-pppoe-3.5.tar.gz :
#tar -zxf rp-pppoe-3.5.tar.gz
進入產生的目錄:
#cd rp-pppoe-3.5
在所在目錄內運行指令碼 go:
#./go
將自動進行編譯和安裝。

《配置撥號》
調用 /usr/sbin/adsl-setup 進行配置
#adsl-setup
當出現
>>> Enter your PPPoE user name :
輸入ADSL帳號的使用者名稱
當出現
>>> 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 ,這是ADSL相連的網卡的名字
當出現
>>> Enter the demand values (default no):
輸入 no
當出現
>>> Enter the DNS inFORMation here:
輸入相應的 DNS 伺服器 IP 位址(一般有2個),在 magic linux 下通常需要輸入 server,即讓系統自動分配 ip 地址
當出現
>>> Please enter your PPPoE password:
輸入你的 ADSL 帳號的密碼
當出現
>>> Choose a type of firewall (0-2):
輸入 0 或 1
當出現
>>> Accept these settings and adjust configuration files (y/n)?
如果輸入的資訊正確,輸入 y ,完成配置,否則,輸入 n 重新輸入。

《撥接》
完成後使用命令:
adsl-start 啟動 PPPOE 用戶端軟體,進行串連,如果成功,將出現
Connected;
adsl-stop 斷開和ISP的串連
adsl-status 查看當前串連的狀態

《技巧提示》
如果想在Linux系統啟動時自動啟動ADSL串連,輸入以下命令
#chkconfig --add adsl
將在當前的運行級下加入ADSL的自啟動指令碼
不想自動運行,則每次上網前選在終端下運行adsl-start即可!
如果不知道相應DNS伺服器的IP地址,可在 windows 裡撥號後,在 MS-DOS 視窗裡運行 ipconfig/all 查看 DNS Server 的 IP 位址(一般有兩個)。如果本機上沒有Windows,那麼在本地區的其他裝有 Windows 的機子上操作也可。

例如:
I:>ipconfig /all

Windows 2000 IP Configuration

Host Name . . . . . . . . . . . . : star
Primary DNS Suffix . . . . . . . :
Node Type . . . . . . . . . . . . : Broadcast
IP Routing Enabled. . . . . . . . : No
WINS Proxy Enabled. . . . . . . . : No

Ethernet adapter 本地串連:

Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Realtek RTL8139(A) PCI Fast Etherne
Adapter
Physical Address. . . . . . . . . : 00-D0-F8-3D-CA-D8
DHCP Enabled. . . . . . . . . . . : Yes
Autoconfiguration Enabled . . . . : Yes
Autoconfiguration IP Address. . . : 169.222.23.123
Subnet Mask . . . . . . . . . . . : 255.255.0.0
Default Gateway . . . . . . . . . :
DNS Servers . . . . . . . . . . . :

PPP adapter 串連裝置 Realtek RTL8139(A) PCI Fast Ethernet Adapter:

Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : WAN (PPP/SLIP) Interface
Physical Address. . . . . . . . . : 00-53-45-00-00-00
DHCP Enabled. . . . . . . . . . . : No
IP Address. . . . . . . . . . . . : 221.206.209.250
Subnet Mask . . . . . . . . . . . : 255.255.255.255
Default Gateway . . . . . . . . . : 221.206.209.250
DNS Servers . . . . . . . . . . . : 202.106.100.213
202.106.87.65
NetBIOS over Tcpip. . . . . . . . : Disabled

可以看出:
DNS Servers . . . . . . . . . . . : 202.106.100.213
202.106.87.65'

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.