Adjusting for Daylight Saving Time
Problem
You want the router to automatically adjust to Daylight Saving Time.
Solution
Some areas, such as most of North America and Europe, have consistent and common rules for when to switch between winter or Standard time and summer or Daylight Saving Time. The traditional North American rule, and the default for Cisco routers when they are configured for summer time, is to move an hour ahead at 2:00 AM on the first Sunday in April, and back an hour at 2:00 AM on the last Sunday in October. We note in passing that this rule will change starting in 2007, which we discuss in more detail in Recipe 14.19:
Router#configure terminalEnter configuration commands, one per line. End with CNTL/Z. Router(config)#clock summer-timeEDTrecurringRouter(config)#endRouter#
You can also specify exact recurrence rules. You could use the following command to explicitly define the North American rules:
Router#configure terminalEnter configuration commands, one per line. End with CNTL/Z. Router(config)#clock summer-timeEDTrecurringRouter(config)#first sun apr 02:00 last sun oct 02:00endRouter#
You can modify this line to represent other standard recurrence rules. For example, in the Southern Hemisphere, Daylight Saving Time commences towards the end of the year to match their summer season. To define the rules for Australian Eastern Daylight Time (AEDT), you could use the following command:
Router#configure terminal Enter configuration commands, one per line. End ...Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access