Changes

1,148 bytes added ,  14:59, 19 April 2018
no edit summary
Line 34: Line 34:  
For the sake of example, I've added a Ping Reboot rule to the router's configuration. In the figure above you can see that creating such a rule also generates an entry (encapsulated in green) in the crontab list. Let's examine this entry:
 
For the sake of example, I've added a Ping Reboot rule to the router's configuration. In the figure above you can see that creating such a rule also generates an entry (encapsulated in green) in the crontab list. Let's examine this entry:
   −
* The '''/sbin/ping_reboot 1 8.8.8.8 NULL 2 56 5 1 0 cfg02c21d''' part indicates the action that is to be taken. In this case it is the ''/sbin/ping_reboot'' command with the options ''1 8.8.8.8 NULL 2 56 5 1 0 cfg02c21d''
+
* '''/sbin/ping_reboot 1 8.8.8.8 NULL 2 56 5 1 0 cfg02c21d''' - indicates the action that is to be taken. In this case it is the ''/sbin/ping_reboot'' command with the options ''1 8.8.8.8 NULL 2 56 5 1 0 cfg02c21d''
* The '''*/5 * * * *''' part indicates the frequency at which the action is executed. It consists out of five segments: '''minute''', '''hour''', '''day of month''', '''month''' and '''day of week''' in that order. A table of examples on how to specify this frequency is presented below:
+
* '''*/5 * * * *''' - indicates the frequency at which the action is executed. It consists out of five segments: '''minute''', '''hour''', '''day of month''', '''month''' and '''day of week''' in that order. A table of examples on how to specify this frequency is presented below:
    
{| class="wikitable"
 
{| class="wikitable"
Line 72: Line 72:  
| style="text-align: center; vertical-align: top;" | 11
 
| style="text-align: center; vertical-align: top;" | 11
 
| style="text-align: center; vertical-align: top;" | 15
 
| style="text-align: center; vertical-align: top;" | 15
| style="text-align: center; vertical-align: top;" | 1/6/12
+
| style="text-align: center; vertical-align: top;" | 1,6,12
 
| style="text-align: center; vertical-align: top;" | *
 
| style="text-align: center; vertical-align: top;" | *
 
| style="text-align: left; vertical-align: top;"  | At 11:57 Hrs on 15th of Jan, June & Dec.
 
| style="text-align: left; vertical-align: top;"  | At 11:57 Hrs on 15th of Jan, June & Dec.
Line 79: Line 79:  
| style="text-align: center; vertical-align: top;" | 6
 
| style="text-align: center; vertical-align: top;" | 6
 
| style="text-align: center; vertical-align: top;" | *
 
| style="text-align: center; vertical-align: top;" | *
| style="text-align: center; vertical-align: top;" | 1
+
| style="text-align: center; vertical-align: top;" | *
 
| style="text-align: center; vertical-align: top;" | 5
 
| style="text-align: center; vertical-align: top;" | 5
 
| style="text-align: left; vertical-align: top;"  | At 6:25 AM every weekday (Mon-Fri)
 
| style="text-align: left; vertical-align: top;"  | At 6:25 AM every weekday (Mon-Fri)
Line 90: Line 90:  
| style="text-align: left; vertical-align: top;"  | At midnight on 4th, 12th and 26th of every month
 
| style="text-align: left; vertical-align: top;"  | At midnight on 4th, 12th and 26th of every month
 
|-
 
|-
| style="text-align: center; vertical-align: top;" | 5.10
+
| style="text-align: center; vertical-align: top;" | 5,10
| style="text-align: center; vertical-align: top;" | 9.14
+
| style="text-align: center; vertical-align: top;" | 9,14
 
| style="text-align: center; vertical-align: top;" | 10
 
| style="text-align: center; vertical-align: top;" | 10
 
| style="text-align: center; vertical-align: top;" | *
 
| style="text-align: center; vertical-align: top;" | *
Line 98: Line 98:  
|-
 
|-
 
|}
 
|}
 +
 +
There are several nuances to discuss here:
 +
* an '''asterisk''' ('''*''') stands for every possible value of the relevant time unit. For example, if placed in the hour section, it indicates that an action should be taken every hour
 +
* a '''number''' indicates the exact time at which an action should occur. For example, if the number 5 was placed in the minute section, the specified action would be taken at the fifth minute of every hour
 +
* numbers separated by '''commas''' (''',''') indicate multiple specific time stamps at which an action should occur. For example, if the numbers 6,9,10 were placed in the hour section, the specified action would be taken at 6:00 AM, 9:00 AM and 10 AM every day
 +
* an asterisk and a number separated by a '''forward slash''' ('''/''') indicate a periodicity. For example, */10 placed in the minute section would indicate that the specified action should occur every 10 minutes
 +
* the '''day of week''' segment functions a bit differently than the others:
 +
** 0 indicates Sunday and 1-6 indicate Monday through Saturday
 +
** since weekdays shift throughout the year (i.e., they are not dependent on specific days of a month)
    
==External links==
 
==External links==
    
https://www.chiark.greenend.org.uk/~sgtatham/putty/latest.html - PuTTY downloads page link
 
https://www.chiark.greenend.org.uk/~sgtatham/putty/latest.html - PuTTY downloads page link

Navigation menu