X-Recipient: archive-cygwin@delorie.com
X-SWARE-Spam-Status: No, hits=-0.8 required=5.0	tests=AWL,BAYES_00
X-Spam-Check-By: sourceware.org
Date: Wed, 11 May 2011 16:37:26 -0500
From: Doug Morse <dm@dougmorse.org>
To: cygwin@cygwin.com
Subject: Re: GNU screen on Cygwin: Cannot seem to reattach, no matter what I try
Message-ID: <20110511213725.GA20693@ikrg.com>
Reply-To: Doug Morse <dm@dougmorse.org>
References: <aj2js656aa8s3rhg16ol319lj9lundnfnk@4ax.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <aj2js656aa8s3rhg16ol319lj9lundnfnk@4ax.com>
User-Agent: Mutt/1.4.1i
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

Hi Andrew and Corinna,

Yep, something about FAT32 appears to be the problem.  As Corinna correctly
notes, permissions are faked on FAT32.  Doesn't matter what chmod I run, it's
all 644 or 755.  Apparently, GNU screen does not like this, but apparently it
also doesn't give any error message that that's the problem.  Might be worth
adding a few lines to the source to provide somewhat more diagnostic error
messages re: when socket files cannot be found or opened?!?

At any rate, it works great now -- thanks!!!  I set SCREENDIR=/cygdrive/c/tmp
(an NTFS volume).  Bingo, I can reattach.  From same tty or different tty,
whether console or remote.  It's just like the old SCO Xenix days with Wyse 60
terminals -- woo-hoo!  :)  Only I'd take SCO Xenix over cmd.exe any day. :)

Perhaps one for the FAQs...?

Thanks again,
Doug

P.S., BTW, gotta love the Romans: we're just like 'em! :) :)


On Tue, May 10, 2011 at 03:07:03PM -0400, Andrew Schulman wrote:
> > 1. Output of 'cygcheck -svr' appended to the end of this message.
> 
> Thanks, looks okay.
> 
> > 2. I have the problem whether I run GNU screen from a cmd.exe prompt or 
> > under rxvt.  I tried Peter Li's suggestion of trying to run screen under 
> > mintty -- still no joy.  It does not matter if I running GNU screen from 
> > the console or if I'm logged in remotely, or if I try to detach and 
> > re-attach from the same tty or different ones.  All efforts yield the 
> > same result: GNU screen cannot find anything to which to re-attach, even 
> > a session that I detached on the same tty just seconds before.
> > 
> > 3. chmod 666 on the socket file did not work (its permissions were 
> > already 644, owned my 'morse', as shown in my original session long).
> 
> No, I suggested that you try 0600, on the theory that your 0640 permissions
> might be too permissive, and screen would refuse to use the socket.
> Unlikely, but worth a try.
> 
> However, if your socket is on a FAT file system, I don't know if you can
> set 0600 permissions.
> 
> > HOWEVER, I am wondering: my Cygin /tmp *IS* on a FAT32 filesystem, *NOT* 
> > an NTFS filesystem.  Would that matter?  Are socket files properly 
> > handled by Cygwin on FAT32?  (I've never used a socket-based Cygwin 
> > program on this host before, at least not to my knowledge.)
> 
> Hm, that could explain it.  I don't recall this coming up before.
> 
> Looking at screen(1), it says that sockets can go in "any mode 0700
> directory", and that you can set that in $SCREENDIR.  So, I suggest trying
> the following in order:
> 
> (1) Run
> 
> chmod 0700 /tmp/uscreens/S-morse
> chmod 0600 /tmp/uscreens/S-morse/*
> 
> then try to reattach.
> 
> (2) If you can't set the above permissions because /tmp is on a FAT file
> system, then find an NTFS directory and run
> 
> export SCREENDIR=/path/to/ntfs/directory
> 
> then start a new screen session, and see if you can reattach to it.
> 

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

