Page 1 of 2
Auto stop and restart program
Posted: Tue 17 Jan 2012 4:44 am
by PaulMy
I would like to set up a scheduled stop and restart of Yawcam once a day but Windows Task Scheduler has only a Start option, not a Stop. How can I do this?
The reason I want to do this is that quite often the Yawcam FTP to Weather Underground has a connect error and regularly fails to reconnect. A manual stop and restart of Yawcam always fixes it for a few days or so and I would like to automate this.
Paul
Re: Auto stop and restart program
Posted: Tue 17 Jan 2012 9:09 am
by mcrossley
In Task Scheduler you can set a job to stop after running for a defined time period. You could use that in combination with a start schedule.
Re: Auto stop and restart program
Posted: Tue 17 Jan 2012 4:33 pm
by PaulMy
Thanks Mark,
I've now gotten deeper into Task Scheduler and found more setting options and have set to stop after 1438 min (23 hrs 58 min). I'll see tomorrow if this works. Another lesson learned!
Paul
Re: Auto stop and restart program
Posted: Tue 17 Jan 2012 9:22 pm
by hills
YAWCAM seems to be getting worse with FTP so I've changed mine to just store it locally and then downloaded "fling" to do the ftp. Touch wood it has done the ftping and recovered from all connection problems without interaction.
I've also had to change my PHP code and xmlswf slideshow as I now don't have YAWCAM renaming every file each time, but that was no problem.
Re: Auto stop and restart program
Posted: Wed 18 Jan 2012 12:06 am
by PaulMy
I may have to wait longer to see if the task scheduler works; my weather computer monitor just seemed to have blown up in front of me. As I was working on some files the monitor just quit and went black. Changed with another monitor and the same thing. I can get a full screen of garbage graphics and the monitor settings to show on top of that so expect a video card failed. Yawcam still seems to be working, as is Cumulus and website updates. What is the best way to shut the computer down without a monitor?
Re: Auto stop and restart program
Posted: Wed 18 Jan 2012 12:16 am
by beteljuice
Not sure about new OS, but old stlye was <CNTL>+<ALT>+<DEL> (all together) TWICE
Re: Auto stop and restart program
Posted: Wed 18 Jan 2012 12:28 am
by PaulMy
Thanks beteljuice, I should have known that

It is Windows 7 but will try that when I am ready to take it to a shop or something. I guess some type of remote monitoring and access software would have come in handy?
Paul
Re: Auto stop and restart program
Posted: Wed 18 Jan 2012 12:41 am
by beteljuice
Hmm ... that might force a soft reboot.
Try <CNTL>+<ALT>+<DEL> then <ALT>+U TWICE
Re: Auto stop and restart program
Posted: Wed 18 Jan 2012 3:03 am
by PaulMy
Thanks again beteljuice,
I have noted your suggestion and will let the computer run until I can take the box to an expert (that certainly is not me) to check the video card and replace if needed, likely later in the week, so the least amount of down time.
So far looks like Cumulus is running fine and uploads to WU data and webcam, CWOP, PWS, etc. seems to be okay.
Paul
Re: Auto stop and restart program
Posted: Wed 18 Jan 2012 4:27 am
by serowe
Why not run the software as a service and then use something like AlwaysUp? I use this for a number of programs on my server (used it when I was using Cumulus) and it has the option to restart an application if it stops, hangs for a predetermined time, uses too much memory or CPU or even force it to restart every day or a particular day of the week (and also allows conditions to be met for this to happen).
Commercial package but reasonably priced ($US40) - only drawback it is tied to a specific computer BUT the author is very quick at getting back if you have to update the PC or move it.
http://www.coretechnologies.com/products/AlwaysUp/
(Nope I have no ties to it, just quite satisfied with its performance and ease of use)
Re: Auto stop and restart program
Posted: Wed 18 Jan 2012 7:29 am
by uncle_bob
PaulMy wrote: What is the best way to shut the computer down without a monitor?
I just pull the power cord

Re: Auto stop and restart program
Posted: Thu 19 Jan 2012 2:36 am
by PaulMy
I've now gotten deeper into Task Scheduler and found more setting options and have set to stop after 1438 min (23 hrs 58 min). I'll see tomorrow if this works. Another lesson learned!
It must have worked because the Yawcam upload to WU is still going, as is all the other weather related programs (Cumulus, Toolbox, Sunrecorder, webcam live stream, CWOP and PWS) even though I can't directly access the computer without a working monitor.
I'll have time on Friday to shut down the computer, and hopefully pulling the plug would be my last resort. Not sure what such a stop will do to Cumulus, data and uploads, but will have no other choice. Thanks for your help.
Paul
Re: Auto stop and restart program
Posted: Thu 19 Jan 2012 6:56 am
by geoffp
I always use System Scheduler from
http://www.splinterware.com/tour/wincron.htm I use the free version that is plenty good enough for my needs.
Re: Auto stop and restart program
Posted: Thu 19 Jan 2012 10:21 am
by AllyCat
uncle_bob wrote:PaulMy wrote: What is the best way to shut the computer down without a monitor?
I just pull the power cord

Hi,
Recent versions of Windows seem more tolerant of "pulling the plug" than early versions, but still a "clean" shut-down is preferable. I remember the days when proper IT support guys could do remarkable things using just keyboard shortcuts and no monitor. I'm still using XP but the following might be worth a try:
<Windows key> (=Start) , <Up Arrow> (= Turn off computer) , <Enter> , <Right Arrow> (=Turn Off) , <Enter> . Maybe Win7 is slightly different , the only flaw I found with my Dell with XP is that the "Cancel" option actually Hibernated the PC.
If that fails, a slightly cleaner way might be to hold in the power button (for up to 10 seconds).
Cheers, Alan.
Re: Auto stop and restart program
Posted: Thu 19 Jan 2012 10:57 am
by serowe
AllyCat wrote:<Windows key> (=Start) , <Up Arrow> (= Turn off computer)
That in Win 7 takes you to Programs...