delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2006/09/08/22:27:22

X-Spam-Check-By: sourceware.org
Message-ID: <45022675.4030609@cygwin.com>
Date: Fri, 08 Sep 2006 22:27:01 -0400
From: "Larry Hall (Cygwin)" <reply-to-list-only-lh AT cygwin DOT com>
Reply-To: cygwin AT cygwin DOT com
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.0.5) Gecko/20060727 Fedora/1.5.0.5-1.fc4.remi Thunderbird/1.5.0.5 Mnenhy/0.7.4.0
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: problem starting crontab services
References: <450202F7 DOT 4030108 AT thetus DOT com>
In-Reply-To: <450202F7.4030108@thetus.com>
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

On 09/08/2006, Jon Barber wrote:
> hello cygwin gurus
> 
> i can't get crontab services to start.  i just followed the instruction 
> from running cron_diagnose.sh version 1.5, and there were a number of 
> things it reported wrong that i tried to fix.  the final problem is when i 
> try to start cron, i get the following error:
> 
>        $ cygrunsrv --start cron
>        cygrunsrv: Error starting a service: QueryServiceStatus:  Win32
>        error 1062:
>        The service has not been started.
> 
> attached is the output of 'cygcheck -srv > cygcheck.txt'
> 
> any help very much appreciated
> 
> jon barber
> 
> ----------------------------
> 
> my entire log of steps i tried is this:
> 
> following the instructions here:  
> http://sources.redhat.com/ml/cygwin/2004-03/msg00379.html, which involves 
> successively running a diagnostic script to find config errors
> 
>    * i downloaded and ran the cron_diagnose.sh script
>    * it first reported the following
> 
>        The permissions on the file /etc/passwd are not correct.
>        Please run 'chmod +r /etc/passwd', and run this script again.
> 
>    * when i looked in /etc, i saw that many of the files were owned by
>      "thadmin", which was the administrative account we originally used
>      to setup the machine.
>    * so i chown'ed most of those files to Administrator, and chmod'ed
>      them +r, and ran the script again.    * it still complained that 
> /etc/passwd had incorrect permissions -
>      turns out /etc/passwd is "-rwxr-xr--+", so i modified the script
>      to accept the + sign in hopes that doesn't matter
>    * it then reported the following
> 
>        The permissions on the file /etc/group are not correct.
>        Please run 'chmod +r /etc/group', and run this script again.
> 
>    * so i chmod'ed it +r, and ran the script again.    * it then reported 
> the following
> 
>        The group membership of your crontab file should be SYSTEM,
>        as documented in the file /usr/share/doc/Cygwin/cron.README.
>        You can change this setting with:
>                 chgrp SYSTEM /var/cron/tabs/Administrator
>        Please check your crontab's group membership, and
>        run this script again. 

I wouldn't recommend this procedure.  Better to run getfacl/setfacl to
solve the problem of the extra permissions access.

You're also using W2K3.  The LocalSystem (SYSTEM) account on W2K3 doesn't
have the permissions necessary to switch user contexts, which is necessary
to run cron in the traditional way.  Since you've already configured and
installed OpenSSH, you can use the sshd_server as the user account for the
cron service as well.  sshd_server has the necessary permissions to switch
user contexts.  Doing this though will likely mean that the files you
changed to be owned by SYSTEM need to have their ownerships changed to
sshd_server.  Rerunning cron_diagnose will likely catch other files that
need to have the ownership changed.  But use sshd_server in place of
SYSTEM.

You may want to update your cygwin package as well.

This may not be enough to solve all your problems but it's not obvious to
me where other problems may be but this should be a start.

-- 
Larry Hall                              http://www.rfk.com
RFK Partners, Inc.                      (508) 893-9779 - RFK Office
216 Dalton Rd.                          (508) 893-9889 - FAX
Holliston, MA 01746

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