ssh disconnecting [WAS: Getting Cut-Off]

Wayne Sierke ws+freebsd-questions at au.dyndns.ws
Sun Mar 7 04:33:33 PST 2004


On Sun, 2004-03-07 at 08:17, Rishi Chopra wrote:
> Wayne,
> 
> I left an SSH connection open to my server last night, and it was still 
> connected this morning; the amount of time exceeded that of past 
> sessions when I was unexpectedly disconnected.
> 
> I understand your reasoning when stating this is not a configuration 
> issue, and given what you've written below, I tend to agree.  I'm using 
> two Realtek 8139 cards in my server and an Intel 21041 in my Win2k box.
> 
> What type of onboard NIC does your new motherboard have?
> 
> Also, I have not messed with the default ACPI settings; are they enabled 
> or disabled by default?  Interesting to note is that the server has been 
> up for weeks now, and even though a particular SSH session is dropped, 
> the server is still up and running, and will accept new SSH connections 
> after unexpecteded termination of previous connections.  This leads me 
> to believe that this is *not* and ACPI problem.

Well, I think I've determined where my problems are stemming from.

I have the server plus three workstations, LANned via a D-Link 5 port
switch, which in turn is linked to a D-Link DI-614+ router for Internet
access.

I set up a number of ssh sessions from each of the workstations to my
server with a couple of variations: I used the server's local hostname
to connect in some instances, and it's IP address in others. It appears
that, so far at least, the connections that are established using the IP
address stay up, whereas those established using the server's hostname
are the one's that fail. The reason? I'm not sure exactly but I'm
guessing it's because the three workstations get their dns service
provided by the D-Link router (I use this arrangement because I'm on a
dynamic IP address scheme and the router receives my provider's DNS
Server addresses).

As it happens, I've fixed my server's local IP address, so it doesn't
use the DHCP from the router and the router doesn't know its (the
server's) local IP address (at least, not related to a hostname). So
what's happening is that the router, in response to a DNS request for
the server's hostname is returning the current Internet IP address (and
all incoming Internet traffic is directed at the server). I'm guessing
that for whatever reason, the router is failing to maintain the proper
connection info and as each connection remains idle for long enough, the
routing info is being discarded.

The short of it is that none of the connections that have been
established using the server's local IP address have yet failed.

This is a snapshot of the ssh connections, those where the foreign
address starts with "ppp36" were established by hostname rather than IP
address:

tcp4 0 0 lillith-iv.ssh ppp36-152.lns1.a.63836 ESTABLISHED
tcp4 0 0 lillith-iv.ssh 192.168.100.132.49296  ESTABLISHED
tcp4 0 0 lillith-iv.ssh ppp36-152.lns1.a.62654 ESTABLISHED
tcp4 0 0 lillith-iv.ssh 192.168.100.6.1070     ESTABLISHED
tcp4 0 0 lillith-iv.ssh 192.168.100.6.1067     ESTABLISHED
tcp4 0 0 lillith-iv.ssh 192.168.100.6.1064     ESTABLISHED
tcp4 0 0 lillith-iv.ssh 192.168.100.6.1063     ESTABLISHED
tcp4 0 0 lillith-iv.ssh ppp36-152.lns1.a.62296 ESTABLISHED
tcp4 0 0 lillith-iv.ssh ppp36-152.lns1.a.62293 ESTABLISHED
tcp4 0 0 lillith-iv.ssh 192.168.100.130.1599   ESTABLISHED
tcp4 0 0 lillith-iv.ssh 192.168.100.130.1595   ESTABLISHED

Sorry for hijacking your thread, Rishi, I guess at least this gives you
one more avenue to check out, as unlikely as it seems that it's going to
apply to your setup.

In response to your questions, the server (an EPIA 5000) uses a vr (Via
Rhine) network adapter, two of my workstations use Realtek cards and the
third has an on-board 3C920 adapter.

I don't recall you saying what version of FreeBSD you're using, 5.2
appears to have ACPI enabled by default, I don't recall for the 4.x
series.




More information about the freebsd-questions mailing list