Advertisement
Lyphereus

ntp config

Feb 20th, 2024
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.44 KB | None | 0 0
  1. Router 1 Configuration
  2. Router>enable
  3. Router#configure terminal
  4. Router(config)#hostname R1
  5. R1(config)#no ip domain-lookup
  6. R1(config)#banner motd #Unauthorized access is prohibited!#
  7. R1(config)#service password-en
  8. Router 1 - Intrinsic Configuration
  9. R1(config)#enable secret class
  10. R1(config)#line con 0
  11. R1(config-line)#password cisco
  12. R1(config-line)#login
  13. R1(config-line)#logging synchronous
  14. R1(config-line)#exit
  15. R1(config)#line vty 0 4
  16. R1(config-line)#password cisco
  17. R1(config-line)#login
  18. R1(config-line)#end
  19. R1#configure terminal
  20. R1(config)#int S0/0/0
  21. R1(config-if)#ip add 10.1.1.1 255.255.255.252
  22. R1(config-if)#clock rate 128000
  23. R1(config-if)#no shutdown
  24. R1(config-if)#end
  25. --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
  26. Router 2 Configuration
  27. Router2>enable
  28. Router2#configure terminal
  29. Router2(config)#hostname R2
  30. R2(config)#no ip domain-lookup
  31. R2(config)#banner motd #Unauthorized access prohibited!#
  32. R2(config)#service password-encryption
  33. R2(config)#line con 0
  34. R2(config-line)#password cisco
  35. R2(config-line)#login
  36. R2(config-line)#logging synchronous
  37. R2(config-line)#exit
  38. R2(config)#line vty 0 4
  39. R2(config-line)#password cisco
  40. R2(config-line)#login
  41. R2(config-line)#end
  42. R2#configure terminal
  43. R2(config)#int S0/0/0
  44. R2(config-if)#ip add 10.1.1.2 255.255.255.252
  45. R2(config-if)#no shutdown
  46. R2(config-if)#end
  47. R2(config)#enable secret class
  48. R2(config)#int g0/0
  49. R2(config-if)#ip add 172.16.2.1 255.255.255.0
  50. R2(config-if)#no shut
  51.  
  52. Clock Configuration
  53. R1#clock set 10:43:00 19 feb 2024
  54. R1#config t
  55. R1(config)#clock timezone SGT 2
  56. R1(config)#exit
  57. R1#sh clock detail
  58. 12:43:45.278 SGT Mon Feb 19 2024
  59. Time source is user configuration
  60. --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
  61. NTP Configuration
  62. R1(config)#ntp ?
  63. authenticate Authenticate time sources
  64. authentication-key Authentication key for trusted time sources
  65. master Act as NTP master clock
  66. server Configure NTP server
  67. trusted-key Key numbers for trusted time sources
  68. update-calendar Configure NTP to update the calendar.
  69. R1(config)#ntp master 5
  70. R2(config)#ntp server 10.1.1.1
  71. R2(config)#ntp update-calendar
  72. R2#sh ntp ?
  73. > associations NTP associations
  74. > status NTP status
  75. R2#sh ntp associations
  76. --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
  77. SysLog Configuration
  78. R2(config)#service timestamps ?
  79. R2(config)#service timestamps log ?
  80. R2(config)#service timestamps log datetime msec
  81. R2#
  82. *Mar 01, 00:02:43.022: %SYS-5-CONFIG_I: Configured from console by console
  83. R2#sh run | include timestamp
  84. service timestamps log datetime msec
  85. no service timestamps debug datetime msec
  86. R2#config t
  87.  
  88. --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
  89. Additional
  90. R2(config)#logging 172.16.2.3
  91. R2(config)#logging trap debugging
  92. R2(config)#int lo 0
  93. Note : These commands may be unavailable in Packet Tracer. Opt for a physical device that supports the latest definitions of Cisco IOS CLI interface.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement