LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 1600|回复: 3

求助:windows下上网不掉线,但linux下总掉线

[复制链接]
发表于 2007-12-1 09:57:02 | 显示全部楼层 |阅读模式
windows下上网不掉线,但linux下总掉线

我是adsl拨号上网,机器是双系统windows vista/debain4.0r1。在windows下上网不掉线,但linux下差不多上网后10分钟左右就就会掉线,不知是何原因。
因为windows下上网没问题,所以我认为可以排除是硬件连接的故障。我上网查了一下这个问题,有人说是adsl配置中的timeout值设置不对造成的,作者指的是redhat系统,但在debian系统下,我不知该在哪个文件中进行设置。也不知是不是这个原因。
我是个初学者,敬请各位老师不吝赐教。


我的硬件系统(在windows下用EVEREST Ultimate Edition查看的信息,部分节录):


CPU 类型               DualCore AMD Athlon 64 X2, 2200 MHz (11 x 200) 4200+

主板名称                MSI K9N4 Ultra-F (MS-7310)  (3 PCI, 1 PCI-E x1, 1 PCI-E x16, 2 DDR2 DIMM, Audio, Gigabit LAN)

主板芯片组              nVIDIA nForce 500 Ultra, AMD Hammer
网络适配器              NVIDIA nForce 网络控制器  (192.168.1.50)



--------[ Windows 网络 ]-----------------



  [ NVIDIA nForce 网络控制器 ]



    网络适配器属性:

      网络适配器                                        NVIDIA nForce 网络控制器

      接口类型                                          Ethernet

      硬件地址(MAC)                                     00-16-17-F2-E7-D3

      连接名称                                          本地连接

      连接速度                                          100 Mbps

      MTU                                               1500 字节

      DHCP 租约获取                                     2007/12/1 8:48:39

      DHCP 租约超期                                     2007/12/1 9:38:39

      已接收字节                                        4878 (4.8 KB)

      已发送字节                                        120780 (117.9 KB)



    网络适配器地址:

      IP地址/子网掩码                                   192.168.1.50 / 255.255.255.0

      网关地址                                          192.168.1.254

      DHCP                                              192.168.1.254

      DNS                                               192.168.1.254

-------[ PCI/PnP 网络 ]----------------



    nVIDIA nForce4 (CK8-04) - LAN Controller (PHY: Vitesse VSC8601)                   PCI





--------[ RAS ]-----------------------



  [ net123 ]



    网络属性:

      连接名称                                          net123

      状态                                              已中断连接

      设备类型                                          pppoe

      设备名称                                          WAN 微型端口(PPPOE)

      用户名称                                          84318296

      国家或地区码                                      未指定

      电话号码                                          未指定

      备用号码                                          未指定

      IP 地址                                           动态

      DNS 地址                                          动态

      WINS 地址                                         动态

      网络通讯协议                                      TCP/IP

      框架通讯协议                                      PPP

      登录脚本文件                                      未指定



    网络特征:

      使用当前帐号和密码                                否

      使用远程网络网关                                  是

      登录到网络                                        已禁用

      IP 字头压缩                                       已禁用

      软件压缩                                          已禁用

      扩展 PPP 连接控制协议                             已启用

      拨号前打开终端设备                                已禁用

      拨号后打开终端设备                                已禁用

      需要加密口令                                      否

      需要 MS 加密口令                                  否

      需要数据加密                                      否

      本地安全文件                                      已禁用



==============


linux下

wisdom:~# ifconfig
eth0      Link encap:Ethernet  HWaddr 00:16:17:F2:E73
          inet addr:192.168.1.50  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::216:17ff:fef2:e7d3/64 Scopeink
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:909 errors:0 dropped:0 overruns:0 frame:0
          TX packets:941 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:707378 (690.7 KiB)  TX bytes:162800 (158.9 KiB)
          Interrupt:217 Base address:0xc000

lo        Link encapocal Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:16 errors:0 dropped:0 overruns:0 frame:0
          TX packets:16 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:800 (800.0 b)  TX bytes:800 (800.0 b)

ppp0      Link encapoint-to-Point Protocol
          inet addr:221.208.64.141  P-t-P:172.16.200.1  Mask:255.255.255.255
          UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1492  Metric:1
          RX packets:745 errors:0 dropped:0 overruns:0 frame:0
          TX packets:710 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:3
          RX bytes:678262 (662.3 KiB)  TX bytes:132047 (128.9 KiB)

wisdom:~# route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
172.16.200.1    *               255.255.255.255 UH    0      0        0 ppp0
192.168.1.0     *               255.255.255.0   U     0      0        0 eth0
default         *               0.0.0.0         U     0      0        0 ppp0

wisdom:~# cat /etc/ppp/peers/dsl-provider
# Minimalistic default options file for DSL/PPPoE connections

noipdefault
defaultroute
replacedefaultroute
hide-password
#lcp-echo-interval 30
#lcp-echo-failure 4
noauth
persist
#mtu 1492
#persist
#maxfail 0
#holdoff 20
plugin rp-pppoe.so eth0
user "84318296"
usepeerdns

wisdom:~# cat /etc/ppp/peers/provider
# example configuration for a dialup connection authenticated with PAP or CHAP
#
# This is the default configuration used by pon(1) and poff(1).
# See the manual page pppd(8) for information on all the options.

# MUST CHANGE: replace myusername@realm with the PPP login name given to
# your by your provider.
# There should be a matching entry with the password in /etc/ppp/pap-secrets
# and/or /etc/ppp/chap-secrets.
user "myusername@realm"

# MUST CHANGE: replace ******** with the phone number of your provider.
# The /etc/chatscripts/pap chat script may be modified to change the
# modem initialization string.
connect "/usr/sbin/chat -v -f /etc/chatscripts/pap -T ********"

# Serial device to which the modem is connected.
/dev/modem

# Speed of the serial line.
115200

# Assumes that your IP address is allocated dynamically by the ISP.
noipdefault
# Try to get the name server addresses from the ISP.
usepeerdns
# Use this connection as the default route.
defaultroute

# Makes pppd "dial again" when the connection is lost.
persist

# Do not ask the remote to authenticate.
noauth


wisdom:~# cat /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
allow-hotplug eth0
iface eth0 inet dhcp

auto dsl-provider
iface dsl-provider inet ppp
pre-up /sbin/ifconfig eth0 up # line maintained by pppoeconf
provider dsl-provider

auto eth0


wisdom:~#
发表于 2007-12-1 17:52:39 | 显示全部楼层
我虽然没有你的系统,但想问问,你的Linux驱动都装了些什么?
lsmod的结果贴出来看看。

还有就是你10分钟掉线是什么现象?
ppp0没有了?
掉线后ping外网的地址,例如ping g.cn是怎么个情况。
回复 支持 反对

使用道具 举报

 楼主| 发表于 2007-12-2 02:09:57 | 显示全部楼层
掉线多是在网络空闲时

wisdom:~# lsmod
Module                  Size  Used by
button                 12192  0
ac                     10376  0
battery                15496  0
ipt_TCPMSS              8960  1
xt_tcpmss               6912  1
xt_tcpudp               7936  1
iptable_mangle          7552  1
ip_tables              25576  1 iptable_mangle
x_tables               22024  4 ipt_TCPMSS,xt_tcpmss,xt_tcpudp,ip_tables
pppoe                  23296  2
pppox                   8592  1 pppoe
ipv6                  286048  12
ppp_generic            33952  6 pppoe,pppox
slhc                   11392  1 ppp_generic
nls_utf8                6656  6
ntfs                  190728  6
dm_snapshot            20664  0
dm_mirror              25216  0
dm_mod                 62800  2 dm_snapshot,dm_mirror
loop                   20112  0
snd_intel8x0           39592  2
snd_ac97_codec        106456  1 snd_intel8x0
snd_ac97_bus            7296  1 snd_ac97_codec
snd_pcm_oss            48672  1
snd_mixer_oss          21888  1 snd_pcm_oss
snd_pcm                89096  3 snd_intel8x0,snd_ac97_codec,snd_pcm_oss
i2c_nforce2            12544  0
snd_timer              29192  1 snd_pcm
i2c_core               27776  1 i2c_nforce2
pcspkr                  7808  0
snd                    65256  8 snd_intel8x0,snd_ac97_codec,snd_pcm_oss,snd_mixe r_oss,snd_pcm,snd_timer
parport_pc             41640  0
parport                44684  1 parport_pc
psmouse                44432  0
serio_raw              12036  0
soundcore              15392  2 snd
snd_page_alloc         14864  2 snd_intel8x0,snd_pcm
tsdev                  13056  0
evdev                  15360  1
ext3                  138512  1
jbd                    65392  1 ext3
mbcache                14216  1 ext3
ide_cd                 45088  0
cdrom                  40488  1 ide_cd
usbhid                 45088  0
sd_mod                 25856  9
amd74xx                19504  0 [permanent]
generic                10500  0 [permanent]
ide_core              147584  3 ide_cd,amd74xx,generic
forcedeth              46340  0
ehci_hcd               36104  0
ohci_hcd               24836  0
sata_nv                17412  8
libata                106784  1 sata_nv
scsi_mod              153008  2 sd_mod,libata
thermal                20240  0
processor              38248  1 thermal
fan                     9864  0
wisdom:~#
掉线以后:
wisdom:~# ping www.baidu.com
ping: unknown host www.baidu.com
wisdom:~#
回复 支持 反对

使用道具 举报

 楼主| 发表于 2007-12-2 09:05:01 | 显示全部楼层
问题暂时已解决
方法:设成静态地址,重启系统即可。
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表