1 |
On 03/22/2017 12:46 AM, Alan McKinnon wrote: |
2 |
> On 22/03/2017 02:27, thelma@×××××××××××.com wrote: |
3 |
>> I have a cron tab entry: |
4 |
>> 5 18 3 * 1-5 |
5 |
>> |
6 |
>> To my understanding it will run 18:05 on the 3rd day of the month, from |
7 |
>> Mon-Fri. |
8 |
>> |
9 |
>> So why did this cron entry run today? |
10 |
>> |
11 |
> |
12 |
> You have not read the man page. |
13 |
> |
14 |
> Fields 3 & 4 plus 5 are not anded like you are assuming. It is more |
15 |
> |
16 |
> (3 AND 4) OR 5 giving you this: |
17 |
> Run at 18:05 on the 3rd, |
18 |
> and also |
19 |
> Run at 18:05 every Mon-Fri |
20 |
> |
21 |
> and it's all in the man page, and you are having an alarming tendency to |
22 |
> not read them. Please deal with this internal lack. |
23 |
|
24 |
Yes, you are correct; I have to work on it. |
25 |
|
26 |
> |
27 |
> Now this all makes sense. You cannot possibly have the 3rd day of the |
28 |
> month happen Monday to Friday |
29 |
|
30 |
You are correct it should be: |
31 |
5 18 3 * * |
32 |
|
33 |
-- |
34 |
Thelma |