OS2 World Community Forum
OS/2, eCS & ArcaOS - Technical => Utilities => Topic started by: Mike Snyder on August 14, 2020, 04:47:28 pm
-
For years I used a unix port called cron/2 to perform various backup and other tasks. At some time between ArcaOS 5 and 5.04, it stopped working. By that I mean that while the program runs, it will not start any applicatiions. I've also tried a cron application written in REXX, but it won't start anything for me either. Does anyone know of one that works on the current version of ArcaOS?
-
Hey Michael,
Ugh?
I am using CRON/2 today, albeit not with AOS...nevertheless, I am curious, what are the errors you are seeing?
-Dariusz
-
Hi Michael, the simplest is to create a program object for the program you want to run then set it to run when you want in the Properties under the Schedule tab.
-
Dave,
I don't seem to have a schedule tab on any of my properties notebooks. How did you get them?
-
Dariusz,
I don't get any error messages. If I launch cron/2, it just sets there. It does not start any of the programs listed in the cron2.dat file. They're mostly rar commands to do backups. I get no backup and no error messages.
-
Dave,
I don't seem to have a schedule tab on any of my properties notebooks. How did you get them?
If you are using ArcaOS, it is there.
Right click on a program object. At the top of the properties tabs, one of the tabs should be labed "Schedule".
Attached is a picture.
-
As David said, it has to be a program object. If it is a script, the program object has to be for cmd.exe with the parameters /c x:\path\to\script.cmd or such and likely the working directory set correctly too.
-
For years I used a unix port called cron/2 to perform various backup and other tasks. At some time between ArcaOS 5 and 5.04, it stopped working. By that I mean that while the program runs, it will not start any applicatiions. I've also tried a cron application written in REXX, but it won't start anything for me either. Does anyone know of one that works on the current version of ArcaOS?
You can create a cron like with rexx.
Just write a daemon (started under startup folder)) which uses defined rules for applications, at the date/time specified into the rules, the process start
(So i'm currently do with the exception that rules are set through a GUI under ClamAV scheduler)
To show what could be done with basic rules (this one was recently alpha build updated _ a few tests were ok for me)
It was specifically build for use with ClamAV-GUI (uses same ini file) but it could be upgraded to a more general use.
-
I'm trying program objects. Thanks to all for the help.
-
Hi Michael,
Dariusz,
I don't get any error messages. If I launch cron/2, it just sets there. It does not start any of the programs listed in the cron2.dat file. They're mostly rar commands to do backups. I get no backup and no error messages.
Ahh, OK, got it. I have to say the cron/2 documentation is hard to understand (for me it was anyways) in that the cron2.dat file structure just didn't seem to make sense. Most likely that's b/c it does not seem to follow the Unix cron configuration, so any on-line references you find out there just don't seem to readily translate to the cron/2 port.
Having said that, here are a couple of examples that I was toying with:
1) do a continuous refresh of a NAS folder
0-59/5,0-23,1-31,1-12,0-7 * * * * OS2 BG FULL- g:\util\misc\refresh_folder.cmd V:\public\syslog
2) do a MONTHLY refresh of a NAS folder
* * 1 * * OS2 BG FULL- g:\util\misc\folder_refresh.cmd V:\public\syslog
3) Force the EVERY_5_MINUTES folder refresh for: V:\public\syslog
0,5,10,15,20,25,30,35,50,45,50,55 * * * * OS2 BG FULL- g:\util\misc\folder_refresh.cmd V:\public\syslog
Of the above three just the 3rd one worked, the first two I just couldn't make work, and those were defined using the Unix documentation which cron/2 claims to support.
Anyways, if you are still looking to use cron/2 I would say give that a try.
-
Another suggestion for a chron-like utility
https://hobbes.nmsu.edu/?dir=%2F&stype=all&sort=type_name&search=atrgf (https://hobbes.nmsu.edu/?dir=%2F&stype=all&sort=type_name&search=atrgf)
I used this on some eCS and ArcaOS systems. But it is trying to be AT rather than chron.
-
Thanks to all for your suggestions. The program objects schedule page works well for me now. Don't know how I missed that it existed, but after reading the help, it is just as easy as cron.