1、一種是linux共享局域網(wǎng)內(nèi)的windows主機上網(wǎng)
如果你的網(wǎng)卡linux能夠識別的話在安裝的時候會有網(wǎng)卡配置過程。從列表中選擇網(wǎng)絡設備,一般為eth0,點擊“編輯”,在打開的“編輯接口”對話框中,用戶可以通過DHCP來配置網(wǎng)絡,這樣也可以,不過我更喜歡定制一個靜態(tài)IP,所以去掉“使用DHCP進行配置”前面的選項,然后在下面輸入你要定制的IP地址和子網(wǎng)掩碼,確定后,在下面的網(wǎng)關和主要DNS里輸入當前局域網(wǎng)上做為主機的計算機的IP地址。這樣裝完以后就搞定。
如果你是裝完后再安裝的網(wǎng)卡的話,那可以在“系統(tǒng)設置”里選擇“網(wǎng)絡”,如果你的網(wǎng)卡安裝成功的話會在下面的列表里看到你的網(wǎng)卡,同樣設置DNS(和上面一樣),然后再回到列表里,選中你的網(wǎng)卡,點上面的編輯,選中“當計算機啟動時激活設備”,然后選擇下面的“靜態(tài)設置的IP地址”,在下面輸入和上面同樣的設置。再重新啟動就可以了。
2、另外一種就是用你的linux通過ADSL上網(wǎng)了
在linux下就集成著一個ADSL撥號軟件,打開終端,在里面輸入#adsl-setup,然后進行設置:
LOGIN NAME
Enter your Login Name (default root):(輸入你的用戶名)
INTERFACE
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 ethX, where 'X' is a number.
(default eth0):(選擇網(wǎng)絡設備)
Do you want the link to come up on demand, or stay up continuously?
If you want it to come up on demand, enter the idle time in seconds
after which the link should be dropped. If you want the link to
stay up permanently, enter 'no' (two letters, lower-case.)
NOTE: Demand-activated links do not interact well with dynamic IP
addresses. You may have some problems with demand-activated links.
Enter the demand value (default no):(選擇是按需撥號,還是持續(xù)連接)
DNS
Please enter the IP address of your ISP's primary DNS server.
If your ISP claims that 'the server will provide dynamic DNS addresses',
enter 'server' (all lower-case) here.
If you just press enter, I will assume you know what you are
doing and not modify your DNS setup.
Enter the DNS information here:(選擇DNS)
PASSWORD
Please enter your Password:
Please re-enter your Password:
USERCTRL
Please enter 'yes' (two letters, lower-case.) if you want to allow
normal user to start or stop DSL connection (default yes):(是否允許普通用戶啟動、關閉)
The firewall choices are:
0 - NONE: This script will not set any firewall rules. You are responsible
for ensuring the security of your machine. You are STRONGLY
recommended to use some kind of firewall rules.
1 - STANDALONE: Appropriate for a basic stand-alone web-surfing workstation
2 - MASQUERADE: Appropriate for a machine acting as an Internet gateway
for a LAN
Choose a type of firewall (0-2):(選擇firewall的規(guī)則)
Start this connection at boot time
Do you want to start this connection at boot time?
Please enter no or yes (default no):(選擇是否隨機啟動)
** Summary of what you entered **
Ethernet Interface:
User name:
Activate-on-demand:
DNS addresses:
Firewalling:
User Control:
Accept these settings and adjust configuration files (y/n)?(確認一下是否接受設置)
以上的設置在“系統(tǒng)設置”里 的“網(wǎng)絡”里選擇新建,建立一個xDSL連接,也可以實現(xiàn)。設置完成了以后在網(wǎng)絡里激活連接。
上面的ADSL連接就試過一次,由于我們是局域網(wǎng),所以一直用的是共享上網(wǎng),如果有什么錯誤不要罵我,還請指教?。?/p>