This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: cron error can't switch user context



Le 16/04/2010 20:42, Tom Schutter a écrit :

I have number of machines running Windows2003 and Cygwin 1.7.5. On most cron works. But on one (lemon) it does not. It appears that on lemon cron cannot switch the user context.


Cronevents on lemon shows:

2010/04/15 17:19:01 [SYSTEM] /usr/sbin/cron: PID 656: (tschutter) CMD (/usr/bin/python /cygdrive/f/production-sync/production-sync.py)
2010/04/15 17:19:01 [SYSTEM] /usr/sbin/cron: PID 656: (CRON) error (can't switch user context)

/var/log/cron.log is empty on all machines.

let's configure syslogd from inetutils to have some logs : syslogd-config --yes

you may need to configure sshd before to have the right permissions
on /var/empty, etc. (ssh-host-config --yes --user "${CYGSERVER_USER}" --pwd "${CYGSERVER_PASS}" where CYGSERVER_USER=cyg_server and CYGSERVER_PASS=whatever you want)


PS : well, I prefer the legacy one than the ng one...

PS2: IMHO, linux^Wcygwin cron(^W^Wlinux) sucks bcoz it doesn't report on tasks return codes as a true unix does... (i.e.: < root 1331 c Tue Feb 2 17:32:36 MET 2010 rc=1)

The cron daemon is running as SYSTEM on all machines.

2K3 may need to be running under cyg_server ?


to configure cron, I use :

cron-config << EOF
yes

no
no
no
${CYGSERVER_PASS}
${CYGSERVER_PASS}
no
EOF

PS : doesn't support csih yet :-(

cyglsa is running on all machines.

did you reboot after configuring cyglsa ?


cygserver is not running on any machine.

2K3 may need cygserver as well as passwd -D?


I have rerun cron-config, rebooted, etc.

well, ok, you surelly have rebooted :-)


I have searched the net, but most solutions seem to involve Cygwin 1.5 and no cyglsa.

Does anyone have any suggestions?

done.


Cordialement,

Cyrille Lefevre
--
mailto:Cyrille.Lefevre-lists@laposte.net



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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]