hi i have a script that connects to the internet, sends and receives email, then disconnects. i want it to run 3 times a day - at 8:30, 12:00 and 16:30 on all days except sunday. it looks like CRON is a sort of scheduling program, but from what the man pages say, it only runs when a user is logged on and that user has the event set up in their area. as it will be running on a server, no users will be directly logged on to the machine, so how can i get round this. what is the exact procedure or where can i find a step-by-step guide - is there a howto on the subject? many thanks, Andrew Smith <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HEAD> <META content="text/html; charset=iso-8859-1" http-equiv=Content-Type> <META content="MSHTML 5.00.2614.3401" name=GENERATOR> <STYLE></STYLE> </HEAD> <BODY bgColor=#ffffff> <DIV><FONT size=2>hi</FONT></DIV> <DIV> </DIV> <DIV><FONT size=2>i have a script that connects to the internet, sends and receives email, then disconnects. i want it to run 3 times a day - at 8:30, 12:00 and 16:30 on all days except sunday. it looks like CRON is a sort of scheduling program, but from what the man pages say, it only runs when a user is logged on and that user has the event set up in their area. as it will be running on a server, no users will be directly logged on to the machine, so how can i get round this. what is the exact procedure or where can i find a step-by-step guide - is there a howto on the subject?</FONT></DIV> <DIV> </DIV> <DIV><FONT size=2>many thanks,</FONT></DIV> <DIV> </DIV> <DIV> </DIV> <DIV> </DIV> <DIV><FONT size=2>Andrew Smith</FONT></DIV></BODY>
Cron is indeed what you want, and it's irrelevant who is logged on or what the machine is doing. Not sure where you got that idea. Just read the crontab man page, look at your existing /etc/crontab and /etc/cron.* files to understand how SuSE have set it up (so you don't break the rebuild of your locate db, etc), and add the config lines you need. You won't need to worry about starting the cron daemon or anything as all SuSE installations run it by default. I don't think there's a howto - it's too simple even for that. Be very careful with your script though. I note you're in the UK so if it goes wrong your phone bill is going to be rather large... I think, in fact, BT forbid this kind of unattended auto-dial thing unless they have authorised the program. Not that this should stop you, but don't expect sympathy if you end up paying to be connected for hours on end.
i have a script that connects to the internet, sends and receives email, then disconnects. i want it to run 3 times a day - at 8:30, 12:00 and 16:30 on all days except sunday. it looks like CRON is a sort of scheduling program, but from what the man pages say, it only runs when a user is logged on and that user has the event set up in their area. as it will be running on a server, no users will be directly logged on to the machine, so how can i get round this. what is the exact procedure or where can i find a step-by-step guide - is there a howto on the subject?
-- To unsubscribe send e-mail to suse-linux-e-unsubscribe@suse.com For additional commands send e-mail to suse-linux-e-help@suse.com Also check the FAQ at http://www.suse.com/Support/Doku/FAQ/
Derek Fountain wrote:
Cron is indeed what you want, and it's irrelevant who is logged on or what the machine is doing. Not sure where you got that idea. Just r
Each user can have thier own cron file. You just need to it with the crontab command. Nick -- -------------------------------------------------- Nick Zentena "Microsoft has unjustifiably jeopardized the stability and security of the operating system." U.S. District Judge Thomas Penfield Jackson Nov 5/1999 -------------------------------------------------- -- To unsubscribe send e-mail to suse-linux-e-unsubscribe@suse.com For additional commands send e-mail to suse-linux-e-help@suse.com Also check the FAQ at http://www.suse.com/Support/Doku/FAQ/
hi thanks for you help everyone. i'll have a play around and see how i get on. the email was running by a win95 machine running FTgate mail server which dialed up periodically, so the numerous dialups don't concern me. the phone bill is quite big, but as yet i can't find a solution that is any cheaper - leased lines cost the earth, and other 'always on' lines don't look much cheaper. if anyone knows of any good deals (like adsl before bt pushed the price through the roof) please let me know. thanks again, Andrew ----- Original Message ----- From: Derek Fountain <fountai@hursley.ibm.com> To: SuSE English <suse-linux-e@suse.com> Sent: 29 December 1999 16:11 Subject: Re: [SLE] Cron?
Cron is indeed what you want, and it's irrelevant who is logged on or what the machine is doing. Not sure where you got that idea. Just read the crontab man page, look at your existing /etc/crontab and /etc/cron.* files to understand how SuSE have set it up (so you don't break the rebuild of your locate db, etc), and add the config lines you need. You won't need to worry about starting the cron daemon or anything as all SuSE installations run it by default. I don't think there's a howto - it's too simple even for that.
Be very careful with your script though. I note you're in the UK so if it goes wrong your phone bill is going to be rather large... I think, in fact, BT forbid this kind of unattended auto-dial thing unless they have authorised the program. Not that this should stop you, but don't expect sympathy if you end up paying to be connected for hours on end.
i have a script that connects to the internet, sends and receives email, then disconnects. i want it to run 3 times a day - at 8:30, 12:00 and 16:30 on all days except sunday. it looks like CRON is a sort of scheduling program, but from what the man pages say, it only runs when a user is logged on and that user has the event set up in their area. as it will be running on a server, no users will be directly logged on to the machine, so how can i get round this. what is the exact procedure or where can i find a step-by-step guide - is there a howto on the subject?
-- To unsubscribe send e-mail to suse-linux-e-unsubscribe@suse.com For additional commands send e-mail to suse-linux-e-help@suse.com Also check the FAQ at http://www.suse.com/Support/Doku/FAQ/
-- To unsubscribe send e-mail to suse-linux-e-unsubscribe@suse.com For additional commands send e-mail to suse-linux-e-help@suse.com Also check the FAQ at http://www.suse.com/Support/Doku/FAQ/
Arent BT planning a 30quid-a-month-for-unlimited-net-use service in the spring? dont quote me on that tho ;-/
leased lines cost the earth, and other 'always on' lines don't look much cheaper. if anyone knows of any good deals (like adsl before bt pushed the price through the roof) please let me know.
thanks again,
Andrew
-- To unsubscribe send e-mail to suse-linux-e-unsubscribe@suse.com For additional commands send e-mail to suse-linux-e-help@suse.com Also check the FAQ at http://www.suse.com/Support/Doku/FAQ/
Arent BT planning a 30quid-a-month-for-unlimited-net-use service in the spring? dont quote me on that tho ;-/
leased lines cost the earth, and other 'always on' lines don't look much cheaper. if anyone knows of any good deals (like adsl before bt pushed
hi yeh, i heard somewhere about free phone call access - OFTEL have finally decided that it is 'non-monopolistic' or something like that. bt are already offering 0800 access at weekends only. knowing bt, however, there will be a catch with this no call charges service - like you can't be connected for more than 10 hours, after which you are automatically disconnected. and so many people will be using the free bt servers that they will grind down to a snails pace... have a happy new year, Andrew ----- Original Message ----- From: ve <kick@c2i.net> To: <suse-linux-e@suse.com> Sent: 29 December 1999 18:26 Subject: Re: [SLE] Cron? the
price through the roof) please let me know.
thanks again,
Andrew
-- To unsubscribe send e-mail to suse-linux-e-unsubscribe@suse.com For additional commands send e-mail to suse-linux-e-help@suse.com Also check the FAQ at http://www.suse.com/Support/Doku/FAQ/
-- To unsubscribe send e-mail to suse-linux-e-unsubscribe@suse.com For additional commands send e-mail to suse-linux-e-help@suse.com Also check the FAQ at http://www.suse.com/Support/Doku/FAQ/
Andrew Smith wrote:
hi
i have a script that connects to the internet, sends and receives email, then disconnects. i want it to run 3 times a day - at 8:30, 12:00 and 16:30 on all days except sunday. it looks like CRON is a sort of scheduling program, but from what the man pages say, it only runs when a user is logged on and that user has the event set up in their area. as it will be running on a server, no users will be directly logged on to the machine, so how can i get round this. what is the exact procedure or where can i find a step-by-step guide - is there a howto on the subject?
cron is intended to run continuously and it starts commands as near to the scheduled time as it can. No-one needs to be logged in at all. The easiest way to handle cron IMHO is to use crontab -e to edit your crontab file, man 5 crontab will show you the details. You example requires 2 lines: 30 8,16 * * 1-6 script with arguments 0 12 * * 1-6 script with arguments If you change it to run at 12:30 you only need one. I don't like running things at even times because all too many others do and so using a prime number for the minutes spreads the load. /Michael -- To unsubscribe send e-mail to suse-linux-e-unsubscribe@suse.com For additional commands send e-mail to suse-linux-e-help@suse.com Also check the FAQ at http://www.suse.com/Support/Doku/FAQ/
participants (5)
-
andrew@andrew.dabsol.co.uk
-
fountai@hursley.ibm.com
-
kick@c2i.net
-
Michael.Salmon@uab.ericsson.se
-
zentena@hophead.dyndns.org