[讨论] 使用DHCP,网络设置与WindowsXP下相同,但是不能上网的朋友看过来

Web、Mail、Ftp、DNS、Proxy、VPN、Samba、LDAP 等基础网络服务
回复
sissi
帖子: 17
注册时间: 2006-09-22 21:17

[讨论] 使用DHCP,网络设置与WindowsXP下相同,但是不能上网的朋友看过来

#1

帖子 sissi » 2006-11-19 11:53

我去ubuntuforums问这个问题了:

1. Please post output of ifconfig eth0 (Depends on your interface number)
2. Please post output of lspci | grep Eth
3. Please post output of route -n
4. Please post output of cat /etc/resolv.conf
5. Please post output of cat /etc/network/interfaces
6. Please post output of cat /etc/dhcp3/dhclient.conf
7. Please copy entire output of windows ipconfig /all command here

you might have to disbale IPv6 and also look at DNS but one step at a time.

1. 请贴出 ifconfig eth0 的结果(如果你用的网卡是eth1,eth2那就要做相应更改;
2. 贴出 lspci | grep Eth 的结果;
3. 贴出 route -n 的结果;
4. 贴出 cat /etc/resolv.conf
5. 贴出cat /etc/network/interfaces
6. 贴出cat /etc/dhcp3/dhclient.conf
7. 贴出 在Windows命令提示符下运行ipconfig /all的结果

大牛的建议是先试着禁用一下IPv6,看看情况,然后再看看DNS的情况
sissi
帖子: 17
注册时间: 2006-09-22 21:17

#2

帖子 sissi » 2006-11-19 11:55

有这种同样问题的朋友就把这些东西贴出来吧。我再去问
brucezhao
帖子: 207
注册时间: 2006-10-24 10:37
联系:

#3

帖子 brucezhao » 2006-11-20 9:05

好人啊,太感谢了,我来贴一下吧。

1.ifconfig eth0
eth0 Link encap:Ethernet HWaddr 00:03:47:E9:40:0F
inet addr:172.31.16.109 Bcast:172.31.16.255 Mask:255.255.255.0
inet6 addr: fe80::203:47ff:fee9:400f/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:5629 errors:0 dropped:0 overruns:0 frame:0
TX packets:157 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:2112795 (2.0 MiB) TX bytes:20570 (20.0 KiB)

2.lspci | grep Eth
02:08.0 Ethernet controller: Intel Corporation 82801BA/BAM/CA/CAM Ethernet Controller (rev 03)

3.route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
172.31.16.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
0.0.0.0 172.31.16.1 0.0.0.0 UG 0 0 0 eth0

4.cat /etc/resolv.conf
nameserver 172.16.1.139
nameserver 172.16.1.141

5.cat /etc/network/interfaces
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet static
address 172.31.16.109
netmask 255.255.255.0
gateway 172.31.16.1

auto eth1
iface eth1 inet dhcp

auto eth2
iface eth2 inet dhcp

auto ath0
iface ath0 inet dhcp

auto wlan0
iface wlan0 inet dhcp

6.cat/etc/dhcp3/dhclient.conf
# Configuration file for /sbin/dhclient, which is included in Debian's
# dhcp3-client package.
#
# This is a sample configuration file for dhclient. See dhclient.conf's
# man page for more information about the syntax of this file
# and a more comprehensive list of the parameters understood by
# dhclient.
#
# Normally, if the DHCP server provides reasonable information and does
# not leave anything out (like the domain name, for example), then
# few changes must be made to this file, if any.
#

#send host-name "andare.fugue.com";
#send dhcp-client-identifier 1:0:a0:24:ab:fb:9c;
#send dhcp-lease-time 3600;
#supersede domain-name "fugue.com home.vix.com";
#prepend domain-name-servers 127.0.0.1;
request subnet-mask, broadcast-address, time-offset, routers,
domain-name, domain-name-servers, host-name,
netbios-name-servers, netbios-scope;
#require subnet-mask, domain-name-servers;
#timeout 60;
#retry 60;
#reboot 10;
#select-timeout 5;
#initial-interval 2;
#script "/etc/dhcp3/dhclient-script";
#media "-link0 -link1 -link2", "link0 link1";
#reject 192.33.137.209;

#alias {
# interface "eth0";
# fixed-address 192.5.5.213;
# option subnet-mask 255.255.255.255;
#}

#lease {
# interface "eth0";
# fixed-address 192.33.137.200;
# medium "link0 link1";
# option host-name "andare.swiftmedia.com";
# option subnet-mask 255.255.255.0;
# option broadcast-address 192.33.137.255;
# option routers 192.33.137.250;
# option domain-name-servers 127.0.0.1;
# renew 2 2000/1/12 00:00:01;
# rebind 2 2000/1/12 00:00:01;
# expire 2 2000/1/12 00:00:01;
#}

7.在Windows命令提示符下运行ipconfig /all
Windows IP Configuration

Host Name . . . . . . . . . . . . : rj-zhaoyiping1
Primary Dns Suffix . . . . . . . :
Node Type . . . . . . . . . . . . : Unknown
IP Routing Enabled. . . . . . . . : No
WINS Proxy Enabled. . . . . . . . : No

Ethernet adapter 本地连接:

Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Intel(R) PRO/100 VE Network Connection
Physical Address. . . . . . . . . : 00-03-47-E9-40-0F
Dhcp Enabled. . . . . . . . . . . : No
IP Address. . . . . . . . . . . . : 172.31.16.109
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 172.31.16.1
DNS Servers . . . . . . . . . . . : 172.16.1.139
172.16.1.141
brucezhao
帖子: 207
注册时间: 2006-10-24 10:37
联系:

#4

帖子 brucezhao » 2006-11-20 9:07

不过我不是DHCP,我家里两台电脑DHCP反倒都可以上网,这是公司的一台固定IP,原来一直可以上网,前几天突然不能了,没有改任何的设置。
sissi
帖子: 17
注册时间: 2006-09-22 21:17

#5

帖子 sissi » 2006-11-20 10:43

另一位让先关闭一下IPv6试试

to disable ipv6:

add "blacklist ipv6"
to /etc/modprobe.d/blacklist

您用的是Dapper还是Edgy? WinXP or Win2k?
brucezhao
帖子: 207
注册时间: 2006-10-24 10:37
联系:

#6

帖子 brucezhao » 2006-11-21 10:35

我试过了,还是不行。

那台电脑是Edgy+WinXP,公司局域网,固定IP
xuechl
帖子: 2
注册时间: 2006-11-24 9:13

我也不能上网

#7

帖子 xuechl » 2006-11-24 9:22

我是网上下载的6.06。家里有一台tp-link的路由器,我设置成dhcp,我看了ifconfig 和 route 都没问题。为什么就是不能上网呀?win2000是好的。
xuechl
帖子: 2
注册时间: 2006-11-24 9:13

#8

帖子 xuechl » 2006-11-30 18:32

problem is sovled. method please look
http://www.ubuntuforums.org/showthread.php?t=309134
回复