www.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2008/08/21/16:12:36

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
To: cygwin AT cygwin DOT com
From: Andrew Schulman <schulman DOT andrew AT epamail DOT epa DOT gov>
Subject: Re: SSH and reattaching screen
Date: Thu, 21 Aug 2008 16:11:38 -0400
Lines: 37
Message-ID: <khira4pcn6vdj4fjo4707s86pt5ksf57qc@4ax.com>
References: <40a53b430808200813g47528a6dsef1a88566fe709 AT mail DOT gmail DOT com>
Mime-Version: 1.0
X-Archive: encrypt
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

> Is there a known problem with Cygwin's SSH and trying to reattach to
> screen sessions?  This seems to be a random occurrence but while
> trying to reattach to a screen session screen will hang indefinitely.
> I'm using ssh on a Mac OS X 10.5.4 system to ssh into a Windows 2003
> Cygwin installation.  Using a bash alias ( alias sshhs='ssh -t
> domain.com '\''screen -xDr session || screen -S session bash '\''' )
> to connect and try to reattach to a session named session and if that
> fails create a new screen session called session.  I've seen this hang
> occur from accedently closing a Terminal window to telling ssh to
> close connection ( etner ~  . ).  It is not a timed based problem
> because I've let sessions sit for days that I could reattach to and
> sessions that were disconnected for a second that would hang.  Also
> something to take note, options like -list or -wipe will also hang
> screen.  So for instance if screen is hanging I can ssh in normally
> and try to do screen -list or screen -wipe and that screen will hang.
> The solution to the problem currently is to ssh or Remote Desktop into
> the machine and kill the hanging screen PID.  Is there something
> fundmently wrong that I'm doing with ssh or screen that's causing this
> in Cygwin? Thanks.

Hi Derek.  I haven't heard of this particular problem before, where the reattach
hangs.  In the past screen had frequent problems reattaching in Cygwin, but in
all the cases I'm aware of the session was unreachable, i.e. it was listed but
the socket was dead so screen wouldn't let you reattach at all.

The reattachment problems are mostly solved in the current version of screen in
Cygwin AFAIK.  I use it every day and I have only occasional problems
reattaching-- not frequent and nothing I've ever been able to pin down. However,
I'm using a console window, not logging in via ssh.  Not sure how much
difference that makes.

Last year IIRC, one person reported that he couldn't reattach, and he was also
using ssh.  In his case, I believe that at least part of the problem had to do
with bad permissions on the socket files, in /tmp/uscreens.

HTH,
Andrew.


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019