Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 13 May 2009 17:44:18 +0200
From:      Jose Garcia Juanino <jjuanino@gmail.com>
To:        Steve Kargl <sgk@troutmask.apl.washington.edu>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Disabling ssh timeouts?
Message-ID:  <20090513154417.GA11716@banach>
In-Reply-To: <20090513152610.GA62964@troutmask.apl.washington.edu>
References:  <20090513050333.GA4509@troutmask.apl.washington.edu> <20090513145432.GA10978@banach> <20090513152610.GA62964@troutmask.apl.washington.edu>

next in thread | previous in thread | raw e-mail | index | archive | help

--2oS5YaxWCcQjTEyO
Content-Type: text/plain; charset=iso-8859-1
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

El mi=E9rcoles 13 de mayo a las 17:26:10 CEST, Steve Kargl escribi=F3:
> On Wed, May 13, 2009 at 04:54:33PM +0200, Jose Garcia Juanino wrote:
> > El mi=E9rcoles 13 de mayo a las 07:03:33 CEST, Steve Kargl escribi=F3:
> > > Is there anyway to disable sshd from timing out a connection?
> > > I've tried setting  ClientAliveCountMax and ClientAliveInterval
> > > and TCPKeepAlive in sshd.conf, but no combination that I've
> > > tried has worked.
> > >=20
> > >
> > > Running /usr/home/sgk/gcc/gcc4x/gcc/testsuite/gfortran.dg/dg.exp ...
> > >=20
> > > Read from remote host troutmask.apl.washington.edu: Connection reset =
by peer
> > > Connection to troutmask.apl.washington.edu closed.
> > >=20
> > > The only way I'v efound to complete a run of the GCC testsuite
> > > is to sit at the terminal and hit enter every so often.  Also
> > > note, nohup and backgrounding the job does not inhibit sshd
> > > dropping the connection and losing all testsuite results.
> >=20
> > I have fixed that problems with ServerAliveInterval option. Give it a
> > try:
> >=20
> > ssh -o "ServerAliveInterval 60" -l <user> <host>
> >=20
> > (screen is a goog idea, as other people have pointed out, but sometimes
> > it is not posible to install programs on the server)
> >=20
>=20
> Thanks for the tip about ServerAliveInterval.
>=20
> Also, thanks, everyone for the tip about screen.

A last tip, if ServerAliveInterval does not work as expected:

$ ssh -l <user> <host>
$ gccCompilation > /tmp/gccCompilation.log 2>&1 < /dev/null

At this point, it would be possible to exit from the ssh session with
"exit" or CTRL+D. Yo only must to guaranteed this process will not
output anything to stdout, and will not read anything from stdin.

Best regards

--2oS5YaxWCcQjTEyO
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.11 (FreeBSD)

iEYEARECAAYFAkoK6tEACgkQFOo0zaS9RnIV/gCeOjdy06RpOEA4y39v3qhBse4v
N2cAnRXlXPUR0McKhfN9uoi27uEvCAwa
=IRDM
-----END PGP SIGNATURE-----

--2oS5YaxWCcQjTEyO--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090513154417.GA11716>