Slashdot Mirror


Slow Linux 2.2.x Telnet?

RelliK asks: "I have a small LAN at home, 4 workstations and a gateway sharing a cable modem. My workstation is running SuSE 6.1 and the gateway is running Debian 2.1. Both machines are using the 2.2.9 kernel. The problem is that telnet and rlogin from my workstation to the gateway is slow to the point of being absolutely unusable. It takes several seconds for a character to appear on the sccreen after I type it. FTP is also jerky: It transfers files fast, but it appears as though it's constanly "hitting speed bumps", so to speak, especially when it's about 95% done. I've tried everything I could think of to fix the problem, but no luck. I'd *greatly* appreciate it if any of you could help me." Now this just sounds downright strange. Does anyone have any ideas as to what's causing this? Click below for more.

Rellik gives more details on his problem:
"I know it is not a network problem. Telnet from other machines to the gateway works fine. It is not a problem with my hardware either. When I telnet from windows it works fine. Also, if I boot the gateway with kernel 2.0.36, it works fine. So it appears as though the two boxes have problems talking to each other when both are running 2.2.x (doesn't seem to matter which since I tried it with 2.2.5 before). Also, if I telnet from my workstation to the outside, bypassing the gateway, it works fine. It also works if I telnet from the gateway to my workstation. And here is the weirdest thing: if I run tcpdump or iptraf while I'm telnet'ing it works fast!! But as soon as I stop them it starts crawling again...

Detailed specs:

My workstation:
Cyrix 6x86PR-200
64 Mb SDRAM
Asus TX97e motherboard
6 gig hd
ATI 3d Pro Turbo video card
PCI ne2000 compatible network card (RealTek chip)
SuSE 6.1 / kernel 2.2.9

The gateway:
AMD 486dx4-100
32 Mb RAM
1.2 gig HD
Trident 1Mb PCI video card
2x PCI ne2000 compatible network cards (RealTek chip)

network: coax ethernet

Thanks for any help in advance!"

22 comments

  1. NE2000 cards are the worse kind of ethernet by Anonymous Coward · · Score: 0

    NE2000 cards barely qualify as ethernet cards, you should avoid them. Even the PCI ones... Get another card, say a 3Com or SMC, and you'll get decent hardware with decent drivers.

    What does 'ifconfig' tell you about these interfaces? any errors? there are lots of stats to take a look at. Also, try disabling the 2nd NIC on your gateway and see if that helps.

    1. Re:NE2000 cards are the worse kind of ethernet by Anonymous Coward · · Score: 0

      Yes, they are not the best, but i work at a network company, and i wrote a benchmark program for one of the linux boxs that has 3 ne2000 cards in it. With two cards pluged back to back i could get 850-870Mbits through both cards depending on cpu load of machine.

      So they may be the worst but they still can move large volumes of data fast.

    2. Re:NE2000 cards are the worse kind of ethernet by dattaway · · Score: 2

      I'm happy with NE2000 clones as they seem to meet my needs. Between the PCI Realtek NE2000 clone on my workstation and the PCMCIA NE2000 clone on my laptop, they ftp about 1MBs between eachother when transferring ISO images. All that between 75 feet of cheap 8 conductor telephone cable too.

      The only problem I have had was an ISA NE2000 clone had a problem with my P2B motherboard that is seriously overclocked. It would for some reason not load the address into the card causing the kernel to report the transmitter was busy. It migh have been something to do with the wait states on the bus, but I did not mess with them that much...

    3. Re:NE2000 cards are the worse kind of ethernet by \u@\h · · Score: 1

      I can easily get transfer rates of 800kb/s between two NE2000 clones. OS doesn't matter (if you care, over the time it was Linux 2.[02], FreeBSD 2.2.x,3.1, and now 4.0-current, NetBSD 1.[34], Solaris 2.6)

      He should see whether upgrading to 2.2.10acx helps. And always use gcc 2.7.2.x for compiling kernels.

    4. Re:NE2000 cards are the worse kind of ethernet by Sausalito · · Score: 1

      Actually, some of my favorite ethernet cards are LinkSys and Realteks - NE2000 compat cards. They never failed me on Linux installations.

      I had more trouble with 3Coms. I guess you're a recent Linux convert, because 3Com PCI models had problems with Linux because they would not release the specs a while back. It left such a bad taste in my mouth that even now I think twice about buying 3Com.

      And if you're using 3c509, don't forget to turn the damn plug-and-pray feature OFF.

  2. Reverse Authority by Anonymous Coward · · Score: 0

    Usually if it takes a long time to get a prompt, it cannot reverse the domain you put in. Make sure it can find itself forward and reverse and it will work fine.

    1. Re:Reverse Authority by Anonymous Coward · · Score: 0

      It would help here if you put an entry in your host file with your IP and the loopback port with the hostname with the FQDN in there... if you have one.

  3. Re:gcc versions by Anonymous Coward · · Score: 0

    I've used pgcc from 1.1 to 1.1.1 and 1.1.2 (egcs versions, dunno what the pgcc ones were...) and I've never had a problem. I thought the problems were mostly exhibited in the 2.1.x tree and solved with the latest 2.2.x builds starting from 2.2.5?

  4. Re:gcc versions by Anonymous Coward · · Score: 0

    No wonder.... -O6 has is as optimized as you can get... well... not fully, but close. Anyway, -O2 and -O3 work for me.. anything higher bombs out.

    I doubt -O6 works reliably with gcc 2.7.2.3

  5. Re:gcc versions by Anonymous Coward · · Score: 0

    No wonder.... -O6 has is as optimized as you can get... well... not fully, but close. Anyway, -O2 and -O3 work for me.. anything higher bombs out.



    I doubt -O6 works reliably with gcc 2.7.2.3

  6. Re:gcc versions by Anonymous Coward · · Score: 0

    Two things... I find this confusing:
    On the other hand, -O6 (which is equivalent to -O3 in gcc 2.7.2.3), works fine with gcc 2.7.2.3.

    And just wondering, what C compiler is Redhat 6 shipping these days? I did a base install, about 20-30 megs and installed a binary egcs 1.1.1, used it to bootstrap pgcc 1.1.3 (or was it 1.1.2?) and then removed the binary egcs 1.1.1, and I've never had any trouble since... I'll try out gcc 2.7.2.3 though, since I've had a similar problem where I couldn't telnet into the local interface when the remote one was down... It would take a really long time.... or never.

  7. MSS? by Anonymous Coward · · Score: 0

    Well, my friend had the same problem (although that was on Windows 98 boxen.. ugh), and he said changing the MSS fixed the problem completely. *shrug*
    Try "route add default gw mss 1460 dev eth0" (I think that's the syntax :o)

    1. Re:MSS? by FunOne · · Score: 1

      Sorry, what is MSS? I've never hear of it.

      FunOne

      --
      FunOne
  8. Get "tulip" cards by Anonymous Coward · · Score: 0

    I've got no qualms against NE2k cards (okeys
    so it's a little high on CPU load, but still it's
    usually quite negligable unless you're serving up
    lots of pages). On the other hand, it does
    well for its price range (incl. PCI NE2k).
    But for serious networking performance, I'd go
    for the "tulip" chipsets (DEC..erm.. I mean Intel
    DC21143 based NICs). They're even rated by
    Donald Becker as probably the most efficient
    of the 10/100 Fast Ethernet cards (I use an Alloy 1430TX - 21143PD chipset - tulip 0.91 driver)

  9. gcc versions by Sesse · · Score: 1

    I'm not sure which gcc version you are using, but using egcs or pgcc on 2.x kernels gives me big trouble with networking code (like only replying to the first ping it gets from any machine...).

    gcc 2.7.2.3 usually works much better. Try adding -V2.7.2.3 to CFLAGS, and probably a -b flag to (on my Slack 3.4 box it's -bi486-unknown-linux-gnulibc1, check your /usr/lib and find it there)

    /* Steinar */

    --
    (This comment is of course GPLed.)
    1. Re:gcc versions by Sesse · · Score: 1

      I've been using about the same versions as you, and I've found problems both with 2.1 and 2.2. In fact, 2.2 is worse for me than 2.1. (Well, I bootstrap with -O6 -- I guess some pgcc bugs went back into the compiler...)

      /* Steinar */

      --
      (This comment is of course GPLed.)
    2. Re:gcc versions by Sesse · · Score: 1

      It bombs with -O2 also.

      On the other hand, -O6 (which is equivalent to -O3 in gcc 2.7.2.3), works fine with gcc 2.7.2.3.

      /* Steinar */

      --
      (This comment is of course GPLed.)
    3. Re:gcc versions by Sesse · · Score: 1

      What's so confusing? OK, to take it again:

      1. In gcc, -O3 is the highest possible optimization level. Anything above -O3 (-O4, -O5, -O6 and even -O9) gets changed to -O3.

      2. If you compile your kernel with gcc 2.7.2.3, and the optimization set to -O3, it works.

      And for RH: I don't know, and I don't care. I don't use Red Hat :-)

      /* Steinar */

      --
      (This comment is of course GPLed.)
  10. Similar problem by Drew+M. · · Score: 1

    I've had a similar problem with a computer running a 2.2.9 kernel. While doing a redhat 6.0 installation over ftp on a 10bT network, the server all of a sudden decided to slow down to the point that it was almost not responding. I couldn't even telnet into it. If you pinged it, the response time would be in the >2000 ms range. It has a 3com 3c905 card in it, while the receiving computer had a 3com 3c905B.

    Ifconfiging the server up and down didn't seem to do anything, but as soon as I removed and inserted the ethernet card's module, it started working happily again. I still to this day have not figured the problem out, but I know for a fact, that when that machine was running 2.0.36, it never had a problem like that. It seems to me to be a kernel issue, but I have not been able to reproduce it again.

    I have seen about 3 other people post comments to slashdot having the same problem. Hopefully this can get fixed quickly.

    I'm currently running 2.2.10 with the latest development 3c59x driver without any problems.

    Hmm, about the tcpdump and iptraf, they both are probably putting the card in promiscious mode, you can set this mode manually by typing as root
    /sbin/ifconfig eth0 promisc
    this may give you a temporary fix.

  11. tcpdump -p by blueHal · · Score: 1

    if you can't observe it with normal tcpdump, try
    keeping it out of promiscuous mode to observe the problem.

    ifconfig eth0 -promisc; tcpdump -np

    unfortunately, packets have to get a little ways
    through the kernel before tcpdump can grab them.

    also, you might look at netstat -nt to see if
    the bytes are being queued... I'm not sure what
    that stuff really means, but when I have network
    woes, queueing usually pops up there.

    I have had a similar problem, but I haven't been
    able to track it down; it seems to only afflict
    my laptop with whole second (often up to 15
    second) ping delays. If, when you run ping between
    these hosts, you see latencies that are really
    close to whole seconds, we might have an epidemic
    here.

  12. TCP/IP slowdown by josepha48 · · Score: 1

    I have heard that the current Linux kernel (2.2) mainly the ppp code experiences slowdowns.

    --

    Only 'flamers' flame!

  13. Similar Problem by Blue+Monger · · Score: 1

    A while back, after first installing RH6 on my gateway (3c509), it began acting suspicious. Any traffic between my desktop (3c905TX, Win98, ugh), and the gateway would slow down to a crawl, then eventually drop packets. Bringing the interfaces down and up would fix it, but 5 mins later, it would slow back down again. I had a continuous ping -t running from my desktop to the gateway, and I noticed that it started slowing down when I started downloading/browsing from the 'net. If the line was idle, everything was fine.

    After the swearing, and about a day, the problem completely disappeared. The only thing I can think of that would have fixed it was that I rebooted...