This is a discussion on Scheduled tasks never run on time within the DB2 forums, part of the Database Server Software category; --> DB2 UDB ESE is running at V8.1 FP5 on 32-bit Solaris 7, single partition. The tools catalog database is ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| DB2 UDB ESE is running at V8.1 FP5 on 32-bit Solaris 7, single partition. The tools catalog database is on the same instance as everything else. I have not really embraced the DB2 Task Center because I can't get it to run a task anywhere close to the specified start time. In fact, any task I schedule to run daily always starts about 100 minutes late. This delay has been consistent for months, as opposed to a delay that grows over time. When I edit the task and look at the scheduled start time, it appears correct. The Journal confirms how late each job run is. Has anyone experienced this type of behavior? I have very little to go on so far, so I don't think I'll get very far opening a PMR at this point. Scouring the APAR list has revealed nothing. My Unix admins are also less than helpful, chiding me for using a flaky job scheduler instead of using Unix's crude but effective cron utility. If you're not encountering this exact behavior, but are still less than satisfied with Task Center, please reply anyway, and maybe we'll come up with something together. |
| |||
| "Another DB2 UDB DBA" <sazerac@gmail.com> wrote in message news:1102552499.414022.73590@z14g2000cwz.googlegro ups.com... > DB2 UDB ESE is running at V8.1 FP5 on 32-bit Solaris 7, single > partition. The tools catalog database is on the same instance as > everything else. > > I have not really embraced the DB2 Task Center because I can't get it > to run a task anywhere close to the specified start time. In fact, any > task I schedule to run daily always starts about 100 minutes late. This > delay has been consistent for months, as opposed to a delay that grows > over time. When I edit the task and look at the scheduled start time, > it appears correct. The Journal confirms how late each job run is. > > Has anyone experienced this type of behavior? I have very little to go > on so far, so I don't think I'll get very far opening a PMR at this > point. Scouring the APAR list has revealed nothing. My Unix admins are > also less than helpful, chiding me for using a flaky job scheduler > instead of using Unix's crude but effective cron utility. > > If you're not encountering this exact behavior, but are still less than > satisfied with Task Center, please reply anyway, and maybe we'll come > up with something together. > You should definitely open a PMR if you have a support contract. They will tell you what information they need from you and how to get that information. Or just schedule everything 100 minutes early. Cron is definitely crude. For example it cannot schedule a job to run the first Sunday of the month (although I am not sure about the DB2 Task Center). |
| |||
| Mark A wrote: > Cron is definitely crude. For example it cannot schedule a job to run the > first Sunday of the month (although I am not sure about the DB2 Task > Center). Cron can do it - quite easily: 12 0 1-7 * 0 /my/command The fifth column is the day of the week - 0 is Sunday. The third column is the day of the month; the first Sunday always falls between the 1st and the 7th of the month. See: http://www.opengroup.org/onlinepubs/009695399/toc.htm Type crontab in the search field and look at the specification. -- Jonathan Leffler #include <disclaimer.h> Email: jleffler@earthlink.net, jleffler@us.ibm.com Guardian of DBD::Informix v2003.04 -- http://dbi.perl.org/ |
| |||
| > > Cron is definitely crude. For example it cannot schedule a job to run the > > first Sunday of the month (although I am not sure about the DB2 Task > > Center). > > Cron can do it - quite easily: > > 12 0 1-7 * 0 /my/command > > > The fifth column is the day of the week - 0 is Sunday. The third > column is the day of the month; the first Sunday always falls between > the 1st and the 7th of the month. > > See: http://www.opengroup.org/onlinepubs/009695399/toc.htm > Type crontab in the search field and look at the specification. > > -- > Jonathan Leffler #include <disclaimer.h> According to the site you referenced: "Finally, if either the month or day of month is specified as an element or list, and the day of week is also specified as an element or list, then any day matching either the month and day of month, or the day of week, shall be matched." Doesn't this mean that your example will run on the first 7 days of the month (1-7), and also run on any Sunday (0) regardless of the day of the month? |
| |||
| Jonathan Leffler wrote: > > Mark A wrote: > > Cron is definitely crude. For example it cannot schedule a job to run the > > first Sunday of the month (although I am not sure about the DB2 Task > > Center). > > Cron can do it - quite easily: > > 12 0 1-7 * 0 /my/command > > The fifth column is the day of the week - 0 is Sunday. The third > column is the day of the month; the first Sunday always falls between > the 1st and the 7th of the month. > > See: http://www.opengroup.org/onlinepubs/009695399/toc.htm > Type crontab in the search field and look at the specification. > > -- > Jonathan Leffler #include <disclaimer.h> > Email: jleffler@earthlink.net, jleffler@us.ibm.com > Guardian of DBD::Informix v2003.04 -- http://dbi.perl.org/ (ranges are OR'd in crontab), but maybe: 12 0 * * 0 if [ `date +\%d` -lt 8 ]; then /my/command; fi (escape '%', as it's special in crontab). Wolfgang |
| |||
| Mark A wrote: >>> Cron is definitely crude. For example it cannot schedule a job >>> to run the first Sunday of the month (although I am not sure >>> about the DB2 Task Center). >> >>Cron can do it - quite easily: >> >>12 0 1-7 * 0 /my/command >> >> >>The fifth column is the day of the week - 0 is Sunday. The third >>column is the day of the month; the first Sunday always falls between >>the 1st and the 7th of the month. >> >>See: http://www.opengroup.org/onlinepubs/009695399/toc.htm >>Type crontab in the search field and look at the specification. >> >>-- >>Jonathan Leffler #include <disclaimer.h> > > > According to the site you referenced: > > "Finally, if either the month or day of month is specified as an element or > list, and the day of week is also specified as an element or list, then any > day matching either the month and day of month, or the day of week, shall be > matched." Didn't reread that bit, and forgot that oddit. > Doesn't this mean that your example will run on the first 7 days of the > month (1-7), and also run on any Sunday (0) regardless of the day of the > month? Yes. You can still do, just not so compactly. I started off with the 7 line version, then remembered ranges and saw that in the man page. So, moderately easily: 12 0 1 * 0 /my/command 12 0 2 * 0 /my/command 12 0 3 * 0 /my/command .... 12 0 7 * 0 /my/command Sorry for the mis-steer. There had to be a reason why I did it the long-winded way, but I'd forgotten the gotcha (so I was thoroughly gotch-me'd). -- Jonathan Leffler #include <disclaimer.h> Email: jleffler@earthlink.net, jleffler@us.ibm.com Guardian of DBD::Informix v2003.04 -- http://dbi.perl.org/ |
| |||
| "Jonathan Leffler" <jleffler@earthlink.net> wrote in message news:2k9ud.6994$0r.3965@newsread1.news.pas.earthli nk.net... > > Yes. You can still do, just not so compactly. I started off with the > 7 line version, then remembered ranges and saw that in the man page. > So, moderately easily: > > 12 0 1 * 0 /my/command > 12 0 2 * 0 /my/command > 12 0 3 * 0 /my/command > ... > 12 0 7 * 0 /my/command 12 0 1-7 * 0 /my/command > > Sorry for the mis-steer. There had to be a reason why I did it the > long-winded way, but I'd forgotten the gotcha (so I was thoroughly > gotch-me'd). > > -- > Jonathan Leffler #include <disclaimer.h> I believe that your latest attempt runs the first seven days of the month AND runs on Sundays (in fact, I think it will kick off 7 jobs on Sunday at the same time). If I am wrong, some please correct me. The original request was to run on the first Sunday of each month (or run once a month but always on Sunday). |
| |||
| Mark A wrote: > "Jonathan Leffler" <jleffler@earthlink.net> wrote in message > news:2k9ud.6994$0r.3965@newsread1.news.pas.earthli nk.net... > >>Yes. You can still do, just not so compactly. I started off with the >>7 line version, then remembered ranges and saw that in the man page. >>So, moderately easily: >> >>12 0 1 * 0 /my/command >>12 0 2 * 0 /my/command >>12 0 3 * 0 /my/command >>... >>12 0 7 * 0 /my/command > > > 12 0 1-7 * 0 /my/command > >>Sorry for the mis-steer. There had to be a reason why I did it the >>long-winded way, but I'd forgotten the gotcha (so I was thoroughly >>gotch-me'd). >> >>-- >>Jonathan Leffler #include <disclaimer.h> > > > I believe that your latest attempt runs the first seven days of the month > AND runs on Sundays (in fact, I think it will kick off 7 jobs on Sunday at > the same time). If I am wrong, some please correct me. > > The original request was to run on the first Sunday of each month (or run > once a month but always on Sunday). Maybe - OK, I give in. -- Jonathan Leffler #include <disclaimer.h> Email: jleffler@earthlink.net, jleffler@us.ibm.com Guardian of DBD::Informix v2003.04 -- http://dbi.perl.org/ |
| ||||
| I finally opened a PMR, and it appears that the problem goes away in V8 FP6a and newer. For what it's worth, I was able to reproduce the problem on a couple different installations of V8 FP5, so anyone else experiencing problems with scheduled jobs at FP5 should consider upgrading. |