LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Distributions (https://www.linuxquestions.org/questions/linux-distributions-5/)
-   -   [SuSE] 'Netdate': Cron Daemon Error (https://www.linuxquestions.org/questions/linux-distributions-5/%5Bsuse%5D-netdate-cron-daemon-error-66235/)

DavidMD 06-17-2003 05:06 PM

[SuSE] 'Netdate': Cron Daemon Error
 
Hello, everyone.

I am running SuSE Linux 8.2 Professional.

I was using 'netdate' to set the system time, but I read that the NTP protocol is more accurate, so I am now using 'xntp' (http://www.ntp.org/downloads.html), after uninstalling 'netdate' and removing all traces of it. (My first step was to remove 'netdate' with YaST2.)

My problem is not with 'xntp', but with a remnant of 'netdate' that I cannot locate.

My system is set to send mail to 'root' to my account. Every two hours, I get the following e-mail message:

Code:

-------------------------------------------------------------
Cron <root@linux> /usr/sbin/setdate > /dev/null
-------------------------------------------------------------
From: root@linux.local (Cron Daemon)
To: root@linux.local
Date: Yesterday 18:00:00
-------------------------------------------------------------
/bin/sh: line 1: /usr/sbin/setdate: No such file or directory
-------------------------------------------------------------

I have used 'glimpse' and 'locate' to try to find this remnant of 'netdate', but I am at a complete loss.

Does anyone have any suggestions? I have been trying to track down this problem for several days. :(

Thank you, very much, in advance! :)

Cordially,

David
--
http://ddickerson.igc.org/

:newbie:

DavidMD 06-17-2003 06:21 PM

[SuSE] 'Netdate': Cron Daemon Error
 
Hello again, everyone.

Incidentally, I have checked my 'crontab' file and I see nothing unusual:

Code:

SHELL=/bin/sh
PATH=/usr/bin:/usr/sbin:/sbin:/bin:/usr/lib/news/bin
MAILTO=root
#
# check scripts in cron.hourly, cron.daily, cron.weekly, and cron.monthly
#
-*/15 * * * *  root  test -x /usr/lib/cron/run-crons && /usr/lib/cron/run-crons >/dev/null 2>&1
59 *  * * *    root  rm -f /var/spool/cron/lastrun/cron.hourly
14 0  * * *    root  rm -f /var/spool/cron/lastrun/cron.daily
29 0  * * 6    root  rm -f /var/spool/cron/lastrun/cron.weekly
44 0  1 * *    root  rm -f /var/spool/cron/lastrun/cron.monthly

In addition, I have checked all of the 'cron.*' directories, which are empty.

I am continuing to do Google searches and to read 'cron' documentation.

Thank you very much, in advance! :)

Cordially,

David
--
http://ddickerson.igc.org/

DavidMD 06-17-2003 06:36 PM

[SuSE] 'Netdate': Cron Daemon Error
 
Hello again, everyone.

I think that I am a little closer to a solution. :study:

I checked '/var/spool/cron/tabs/root' and the 'root' file contains the following:

Code:

# DO NOT EDIT THIS FILE - edit the master and reinstall.
# (/tmp/crontab.3590 installed on Fri Jun  6 18:11:19 2003)
# (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
00 08 * * *          /usr/sbin/setdate > /dev/null
00 10 * * *          /usr/sbin/setdate > /dev/null
00 12 * * *          /usr/sbin/setdate > /dev/null
00 14 * * *          /usr/sbin/setdate > /dev/null
00 16 * * *          /usr/sbin/setdate > /dev/null
00 18 * * *          /usr/sbin/setdate > /dev/null
00 20 * * *          /usr/sbin/setdate > /dev/null
00 22 * * *          /usr/sbin/setdate > /dev/null
00 23 * * *          /usr/sbin/setdate > /dev/null

Do I just need to create a new 'crontab' file from scratch (and make it empty)?

Thank you very much, in advance! :)

Cordially,

David
--
http://ddickerson.igc.org/

jvannucci 06-17-2003 09:53 PM

Basically, yes. But you said you had checked YOUR crontab. But not root's. So issue:

$ su -
# crontab -l

You should see the setdate stuff. Now change it:

# crontab -e

DavidMD 06-18-2003 01:10 PM

[SuSE] 'Netdate': Cron Daemon Error
 
Hi, Joe.

Thank you very much for your message.

I apologize for my lack of clarity earlier. I was referring to the 'crontab' file for 'root' (which I displayed in my previous message).

Oddly, I can open a console session as 'root' and use 'crontab -l', but when I enter 'crontab -e', I don't open the 'crontab' file with 'vi'; instead, I get the error message below. :(

I did not have this problem when I ran 'crontab -e' previously, and I have done several Google/Linux searches -- with most of the results suggesting setting up a symbolic link for 'vi' (but I have never had this problem before with 'vi').

If anyone has any suggestions of other sources of information that I might research, I would be grateful.

Thank you again, Joe!

Cordially,

David
--
http://ddickerson.igc.org

Code:

ddickerson@linux:/etc> su
Password:
linux:/etc # crontab -l
# DO NOT EDIT THIS FILE - edit the master and reinstall.
# (/tmp/crontab.3590 installed on Fri Jun  6 18:11:19 2003)
# (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
00 08 * * *          /usr/sbin/setdate > /dev/null
00 10 * * *          /usr/sbin/setdate > /dev/null
00 12 * * *          /usr/sbin/setdate > /dev/null
00 14 * * *          /usr/sbin/setdate > /dev/null
00 16 * * *          /usr/sbin/setdate > /dev/null
00 18 * * *          /usr/sbin/setdate > /dev/null
00 20 * * *          /usr/sbin/setdate > /dev/null
00 22 * * *          /usr/sbin/setdate > /dev/null
00 23 * * *          /usr/sbin/setdate > /dev/null

linux:/etc # crontab -e
/bin/sh: line 1: /opt/kde3/share/apps/kedit: is a directory
crontab: "/opt/kde3/share/apps/kedit" exited with status 126

Quote:

Originally posted by jvannucci
Basically, yes. But you said you had checked YOUR crontab. But not root's. So issue:

$ su -
# crontab -l

You should see the setdate stuff. Now change it:

# crontab -e


jvannucci 06-18-2003 01:39 PM

From 'man 1 crontab':
The -e option is used to edit the current crontab using the editor
specified by the VISUAL or EDITOR environment variables. After you
exit from the editor, the modified crontab will be installed automati-
cally.

So I suspect that your EDITOR or VISUAL env variables are set to kedit, or something like that. Try setting it to /usr/bin/vim, or whatever your vi clone path is.

DavidMD 06-18-2003 04:33 PM

[SuSE] 'Netdate': Cron Daemon Error
 
Hi, Joe.

I was able to edit the 'root' 'crontab' file by rebooting and logging in as 'root'. The EDITOR variable for 'root' was still 'vim', so 'crontab -e' (and 'crontab -l') worked as expected.

I have also edited the '.bashrc' file for my account ('ddickerson'); I made 'vim' the value for the EDITOR variable ('export EDITOR=/usr/bin/vim').

Thanks very much, Joe, for your time and help! I am very grateful.

Cordially,

David
--
http://ddickerson.igc.org/


All times are GMT -5. The time now is 04:06 PM.