delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-SWARE-Spam-Status: | No, hits=-1.9 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW |
X-Spam-Check-By: | sourceware.org |
Received-SPF: | pass (google.com: domain of adwulf AT gmail DOT com designates 10.229.135.85 as permitted sender) client-ip=10.229.135.85; |
Authentication-Results: | mr.google.com; spf=pass (google.com: domain of adwulf AT gmail DOT com designates 10.229.135.85 as permitted sender) smtp.mail=adwulf AT gmail DOT com; dkim=pass header.i=adwulf AT gmail DOT com |
MIME-Version: | 1.0 |
Date: | Tue, 21 Feb 2012 14:53:12 +0000 |
Message-ID: | <CA+YUqE1Ts0kPGzmfb7wc678wdm=NBNZAk=KitjcpD=2UNUB-qw@mail.gmail.com> |
Subject: | Fork/resource unavailable - SSH/Citrix |
From: | Adam Thompson <adwulf AT gmail DOT com> |
To: | cygwin AT cygwin DOT com |
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 |
Dear all, About 3.5 years ago, I was looking into why a lot of Citrix Presentation Servers were seeing their SSH services fall over. I did actually discover the issue in the end, but neglected to post back here. I found that the issue was the Citrix API hooking, which messes with the fork() call. I am not a developer, but my understanding is that when a process calls fork(), it is expecting to have a child process created with an exact copy of all its pages. I'm guessing that the injected DLLs prevent this from being an exact copy, and therefore the fork() call fails. I'm not sure why it fails with err 11 (EAGAIN: Resource temporarily unavailable). I would have thought that err 4 (EINTR: Interrupted system call) would be a better fit in this instance. But then, I suppose this depends on how Cygwin interprets what is returned to it in its own NT/Win32 API calls. Anyhow.... there's a Citrix KB article on how to disable hooking on a per-executable basis at: http://support.citrix.com/article/CTX107825 I found that adding sshd.exe and cygrunsrv.exe to the ExcludedImageNames key was enough to fix the problem on the servers I saw the problem on. As this applies to all versions of Citrix Metaframe Presentation Server / XenApp, it might be worth adding these to BLODA. The hooking is done via AppInit_DLLs [1], so for at least Win2000/2003/XP, this key would be a good place to start looking for unexplained fork() failures, and perhaps also merits a mention on the BLODA page. -- AdamT [1] http://blogs.msdn.com/b/oldnewthing/archive/2007/12/13/6648400.aspx -- 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
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |