Gossamer Forum
Home : Products : Links 2.0 : Discussions :

Undo cron event?

Quote Reply
Undo cron event?
May be a little off topic.. How to remove a cron event? I removed the old file from the server and placed another one there (different time). crontab -l only displays the latest cron. I thought the old one should be "overwritten" that all events should be placed in ONE file. Am I wrong? Please help me with this! I've got an event screwing up my database. Sometimes returning a links.db with 0 bytes. Not fun at all.
Quote Reply
Re: Undo cron event? In reply to
1) crontab -e
2) delete the cron event from your Crontab Manager
3) Ctrl-X to save Crontab
4) Y - save the Crontab

Better forum for this is in the Perl/CGI Forum.

Wink

Regards,

------------------
Eliot Lee
Anthro TECH,L.L.C
http://www.anthrotech.com
Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
----------------------





Quote Reply
Re: Undo cron event? In reply to
crontab -e displays only one line and that one is ok. Where can I find the other (at least two) event-instructions? Thanks for the instant response!
Quote Reply
Re: Undo cron event? In reply to
Uh...when you do crontab -e, it will show you all your cron jobs. Then you use your arrow keys to scroll up and down to find the cron job that you want to delete.

Then use your back space key to delete the cron job.

Regards,

------------------
Eliot Lee
Anthro TECH,L.L.C
http://www.anthrotech.com
Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
----------------------





Quote Reply
Re: Undo cron event? In reply to
Yes, but still, there is only one line. nph-build is executed at 13.40, 22.00 and 22.30. Only 13.40 is showed in "crontab -e". I think the 22.00-event is trying to build twice and thats the reason for the screwed data-file. One plan is to rename nph-build.cgi, will this cause troubles?
Quote Reply
Re: Undo cron event? In reply to
What you can do is just delete the 22.00 hour from the crontab.

If you change the name of the file, then you will have to change the reference in the build_links.sh file. But you really don't have to do that.

Regards,

------------------
Eliot Lee
Anthro TECH,L.L.C
http://www.anthrotech.com
Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
----------------------





Quote Reply
Re: Undo cron event? In reply to
Yes, but how? It's not in my mycron file??? It is not present in the crontab -e list.
Quote Reply
Re: Undo cron event? In reply to
Listen...okay...This is a typical (very typical) Crontab display via the PICO editor in most shell accounts:

Code:
# (Re)Build the Links HTML Files each day
0 1,6,13,20 * * * /path/to/build_links.sh

All you have to is delete the hourly values, like if I wanted to delete the 20 hour from this crontab, I would delete the 20 and it would look this:

Code:
# (Re)Build the Links HTML Files each day
0 1,6,13 * * * /path/to/build_links.sh

Hope this helps.

Regards,

------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
----------------------







[This message has been edited by Eliot (edited January 19, 2000).]
Quote Reply
Re: Undo cron event? In reply to
What I've got is this:
30 22 * * * /home/path.../admin/nph-build.cgi

The interesting part is that when I checked 7 hours ago only 40 13 * * *... was diplayed? I'm confused.
Quote Reply
Re: Undo cron event? In reply to
Now I'm getting it... My provider requires me to log in through a login server, from there I'm redirected to one of may be 10 machines. Somehow the cronjobs must have been spread on different servers. Don't ask me how this work, but I when I logged in directly to specific machines I found different crons. Thanks alot for your help! Think this will solve my problem!
Quote Reply
Re: Undo cron event? In reply to
Just as I suspected.. I managed to find two different crons at 2200. I'm very happy right now. Database usually screws up twice a week or so, hopefully this have come to an end now.
Quote Reply
Re: Undo cron event? In reply to
Good...Glad you figured it out. That is really screwy way to set up a Cron Daemon. They should use Pico in each account to allow access on one machine to each user's crontab manager screen.

Regards,

------------------
Eliot Lee
Anthro TECH,L.L.C
http://www.anthrotech.com
Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
----------------------





Quote Reply
Re: Undo cron event? In reply to
Everything has been working perfect since my previous posting. The problem is solved... If your database is acting strange maybe this is what happened to you too. My links.db file was sometimes cut in half, sometimes 0 bytes, no matter the flock setting. I had to use my backup up to 5 times a week...