From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 101705 invoked by alias); 10 Oct 2017 15:14:48 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 101453 invoked by uid 89); 10 Oct 2017 15:14:47 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-6.8 required=5.0 tests=BAYES_00,GIT_PATCH_2,KAM_ASCII_DIVIDERS,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: esa6.dell-outbound.iphmx.com Received: from esa6.dell-outbound.iphmx.com (HELO esa6.dell-outbound.iphmx.com) (68.232.149.229) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 10 Oct 2017 15:14:44 +0000 Received: from esa4.dell-outbound2.iphmx.com ([68.232.154.98]) by esa6.dell-outbound.iphmx.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 Oct 2017 10:14:43 -0500 From: "Gluszczak, Glenn" Received: from mailuogwhop.emc.com ([168.159.213.141]) by esa4.dell-outbound2.iphmx.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 Oct 2017 21:14:42 +0600 Received: from maildlpprd06.lss.emc.com (maildlpprd06.lss.emc.com [10.253.24.38]) by mailuogwprd03.lss.emc.com (Sentrion-MTA-4.3.1/Sentrion-MTA-4.3.0) with ESMTP id v9AFEb3U010053 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Tue, 10 Oct 2017 11:14:41 -0400 X-DKIM: OpenDKIM Filter v2.4.3 mailuogwprd03.lss.emc.com v9AFEb3U010053 X-DKIM: OpenDKIM Filter v2.4.3 mailuogwprd03.lss.emc.com v9AFEb3U010053 Received: from mailusrhubprd02.lss.emc.com (mailusrhubprd02.lss.emc.com [10.253.24.20]) by maildlpprd06.lss.emc.com (RSA Interceptor); Tue, 10 Oct 2017 11:14:13 -0400 Received: from MXHUB105.corp.emc.com (MXHUB105.corp.emc.com [10.253.50.22]) by mailusrhubprd02.lss.emc.com (Sentrion-MTA-4.3.1/Sentrion-MTA-4.3.0) with ESMTP id v9AFEDaP013160 (version=TLSv1 cipher=AES128-SHA bits=128 verify=FAIL); Tue, 10 Oct 2017 11:14:19 -0400 Received: from MX204CL04.corp.emc.com ([fe80::5c2f:a83c:a32d:4b29]) by MXHUB105.corp.emc.com ([10.253.50.22]) with mapi id 14.03.0352.000; Tue, 10 Oct 2017 11:14:15 -0400 To: "Fournier, Danny G" , "cygwin@cygwin.com" Subject: RE: ERROR: A specified logon session does not exist. It may already have been terminated Date: Tue, 10 Oct 2017 15:14:00 -0000 Message-ID: <91DCAC3CB99C724EB365BB64677FBE7B1EFC1B90@MX204CL04.corp.emc.com> References: <513AA0729B894545B2D793D01FFF8B6D4719B909@SVNSBIOMBX01.ENT.dfo-mpo.ca> <91DCAC3CB99C724EB365BB64677FBE7B1EFC1B60@MX204CL04.corp.emc.com> <513AA0729B894545B2D793D01FFF8B6D4719B986@SVNSBIOMBX01.ENT.dfo-mpo.ca> In-Reply-To: <513AA0729B894545B2D793D01FFF8B6D4719B986@SVNSBIOMBX01.ENT.dfo-mpo.ca> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Sentrion-Hostname: mailusrhubprd02.lss.emc.com X-RSA-Classifications: public X-IsSubscribed: yes X-SW-Source: 2017-10/txt/msg00099.txt.bz2 It may still work but you don't see the other terminal window unless you're= on the desktop. To prove, try this command instead. runas /noprofile /user:orawin\administrator echo hello > a Then look for the file "a". I was just wondering if perhaps the issue was due to spawning a separate wi= ndow. Might be unrelated. I've never used schtasks. ----------------------------------------------------- Glenn, I suspect that runas doesn't work through SSH. I ran it without any paramet= ers which resulted in no output in the terminal. However, if I run runas through the Windows Command Prompt, I clearly see o= utput indicating that I missed required parameters. Thanks, Dan Does schtasks.exe open a separate/new terminal session? You could check if a command like "runas" works through ssh. runas /noprofile /user:mymachine\administrator dir Glenn --------------------------------------------------------------------------- We recently upgraded Cygwin to 2.9.0(0.318/5/3) from 2.0.4(0.287/5/3) on Wi= ndows Server 2008 R2. Once we connect to the server using SSH, using a user where we have exchang= ed keys for, we call the following command: schtasks.exe /Run /TN "SomeJobName" This will give the following error: ERROR: A specified logon session does not exist. It may already have been t= erminated. We will also get the same error by simply invoking schtasks.exe without any= parameters, which is supposed to list the jobs currently configured on the= server. What we have done: -Most articles found state to change the following Local Policy to disabled= (which was set already): Network access: Do not allow storage of passwords and credentials for netwo= rk authentication -We have also added the user into the following Local Policy: Log on as a b= atch job and Log on as a service -The user has permission to read and execu= te schtasks.exe -We regenerated passwd and group files -Command prompts in = Windows, running as the specific user, can run schtasks.exe without any pro= blem We are able to successfully call other executables: icacls.exe, robocopy.ex= e, sc.exe and even powershell.exe. We also tested against another server with Cygwin 2.7.0(0.306/5/3) and got = the same issue. Dan -- 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 -- 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 -- 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