delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2006/05/08/12:35:48

X-Spam-Check-By: sourceware.org
MIME-Version: 1.0
Subject: RE: Win2003 server and cron/sshd as services (1.5.19)
Date: Mon, 8 May 2006 12:33:29 -0400
Message-ID: <C874DBE9D30B584587F8CD0EC34DA8BE017ECE93@EX00.idirect.net>
From: "Harig, Mark" <maharig AT idirect DOT net>
To: "Mike Dunn" <mike DOT dunn AT well-dunn DOT com>, <cygwin AT cygwin DOT com>
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
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
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id k48GZf6R009705

>
> mdunn AT h-dlt ~
> $ cygrunsrv -I sshd --shutdown -p /usr/sbin/sshd -a "-D -ddd" \
>    -d "CYGWIN  sshd" -u sshd_server -w a_fine_password -e 
>    "CYGWIN=binmode ntsec tty"

1. I assume that you meant to provide a "\" after '-e' in the
   second line of your command above, correct?

2. In my earlier code, I had provided the following option to
   the cygrunsrv program: --args "-D"

   Note the double quotes around the '-D', above.  I never would
   have suspected it, but those double quotes -- when used to
   install the cron service -- will cause cygrunsrv to fail when
   attempting to start cron.  This surprised me because I use
   the double quotes around '-D' when starting sshd.  In the case
   of starting 'sshd' the double quotes do not cause any problem.
   Going forward, for consistency, I have no quotes around '-D'
   for either 'cron' or 'sshd'.

   Can anyone else on the Cygwin mailing list test this behavior?
   Here are the prerequisites:  Windows 2003 and an 'sshd_server'
   user account in your /etc/passwd (usually created by the script
   named 'ssh-host-config'), with a corresponding password for that
   special user account.

   The following command consistently fails:

   cygrunsrv --install cron --path /usr/sbin/cron --shutdown --args "-D"
\
    --disp "Cygwin cron" --desc "Cygwin vixie-cron service" \
    --user sshd_server --passwd your-fine-password;

   The following command consistently works:

   cygrunsrv --install cron --path /usr/sbin/cron --shutdown --args -D \
    --disp "Cygwin cron" --desc "Cygwin vixie-cron service" \
    --user sshd_server --passwd your-fine-password;

3. If you are still not getting cron to start, then I would
   suspect that the password you are entering for the special
   account 'sshd_server' is incorrect.  Here are some steps 
   you could try to confirm the password:

   a. Log off your Windows account
   b. At the Windows login dialog, enter 'sshd_server' in the
      'User name' field.
   c. Enter the password for this account (do NOT press [Enter]
      or click on 'OK').
   d. In the 'Log on to' field, select the 'hostname' (this computer)
      value so that you are NOT logging on to your local network, if
any).
   e. Click on 'OK' or press [Enter].

   If the error message:

    "The system could not log you on.  Make sure your User name
     and domain are correct, then type your password again"

   is displayed, then either you typed the wrong password or your
   knowledge of the password is incorrect.

   If the error message:

    "The local policy of this system does not permit you to
     logon interactively" 

   is displayed, then your knowledge of the 'sshd_server' user
   account's password is correct.


--
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