
{"id":62,"date":"2013-07-12T17:35:38","date_gmt":"2013-07-12T17:35:38","guid":{"rendered":"http:\/\/pages.charlotte.edu\/mark-hamrick\/?p=62"},"modified":"2013-07-09T14:30:28","modified_gmt":"2013-07-09T14:30:28","slug":"puppet-ntp-and-hiera","status":"publish","type":"post","link":"https:\/\/pages.charlotte.edu\/mark-hamrick\/blog\/2013\/07\/12\/puppet-ntp-and-hiera\/","title":{"rendered":"Puppet, NTP and Hiera"},"content":{"rendered":"<p><!--\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\np,\nblockquote {\nmargin: 0;\npadding: 0;\n}\nbody {\nfont-family: \"Helvetica Neue\", Helvetica, \"Hiragino Sans GB\", Arial, sans-serif;\nfont-size: 13px;\nline-height: 18px;\ncolor: #737373;\nbackground-color: white;\nmargin: 10px 13px 10px 13px;\n}\ntable {\nmargin: 10px 0 15px 0;\nborder-collapse: collapse;\n}\ntd,th {\nborder: 1px solid #ddd;\npadding: 3px 10px;\n}\nth {\npadding: 5px 10px;\n}\n\na {\ncolor: #0069d6;\n}\na:hover {\ncolor: #0050a3;\ntext-decoration: none;\n}\na img {\nborder: none;\n}\np {\nmargin-bottom: 9px;\n}\nh1,\nh2,\nh3,\nh4,\nh5,\nh6 {\ncolor: #404040;\nline-height: 36px;\n}\nh1 {\nmargin-bottom: 18px;\nfont-size: 30px;\n}\nh2 {\nfont-size: 24px;\n}\nh3 {\nfont-size: 18px;\n}\nh4 {\nfont-size: 16px;\n}\nh5 {\nfont-size: 14px;\n}\nh6 {\nfont-size: 13px;\n}\nhr {\nmargin: 0 0 19px;\nborder: 0;\nborder-bottom: 1px solid #ccc;\n}\nblockquote {\npadding: 13px 13px 21px 15px;\nmargin-bottom: 18px;\nfont-family:georgia,serif;\nfont-style: italic;\n}\nblockquote:before {\ncontent:\"\\201C\";\nfont-size:40px;\nmargin-left:-10px;\nfont-family:georgia,serif;\ncolor:#eee;\n}\nblockquote p {\nfont-size: 14px;\nfont-weight: 300;\nline-height: 18px;\nmargin-bottom: 0;\nfont-style: italic;\n}\ncode, pre {\nfont-family: Monaco, Andale Mono, Courier New, monospace;\n}\ncode {\nbackground-color: #fee9cc;\ncolor: rgba(0, 0, 0, 0.75);\npadding: 1px 3px;\nfont-size: 12px;\n-webkit-border-radius: 3px;\n-moz-border-radius: 3px;\nborder-radius: 3px;\n}\npre {\ndisplay: block;\npadding: 14px;\nmargin: 0 0 18px;\nline-height: 16px;\nfont-size: 11px;\nborder: 1px solid #d9d9d9;\nwhite-space: pre-wrap;\nword-wrap: break-word;\n}\npre code {\nbackground-color: #fff;\ncolor:#737373;\nfont-size: 11px;\npadding: 0;\n}\nsup {\nfont-size: 0.83em;\nvertical-align: super;\nline-height: 0;\n}\n* {\n-webkit-print-color-adjust: exact;\n}\n@media screen and (min-width: 914px) {\nbody {\nwidth: 854px;\nmargin:10px auto;\n}\n}\n@media print {\nbody,code,pre code,h1,h2,h3,h4,h5,h6 {\ncolor: black;\n}\ntable, pre {\npage-break-inside: avoid;\n}\n}\n-->For the past several years, a locally written Puppet module has been used to setup NTP. The local NTP module was created to support Ubuntu 10.04. The RHEL\/CENTOS 5\/6 machines were configured to setup NTP during kickstart. Recently some RHEL 6 and Ubuntu 12.04 machines were brought under puppet server without having NTP setup.<\/p>\n<p>Fortunately I bumped into Garret Honeycutt at SELF, and decided to use the NTP module he has on GitHub since it support both RHEL and Ubuntu. Hiera support is also included. The module is available at the link below.<\/p>\n<pre><code>https:\/\/github.com\/ghoneycutt\/puppet-module-ntp\r\n<\/code><\/pre>\n<p>The module is now in production using Hiera and the puppet common module.<\/p>\n<p>Using Hiera, we can now set a common set of NTP servers, then override via FQDN if necessary.<\/p>\n<p>For example, in the common.yaml file the following servers are set:<\/p>\n<pre><code>ntp::servers:\r\n    - notarealtimeserverA.someu.edu\r\n    - notarealtimeserverb.someu.edu\r\n<\/code><\/pre>\n<p>In the file for notaserver.someu.edu.yaml in the FQDN directory we can then do the following:<\/p>\n<pre><code>ntp::servers:\r\n    - notarealtimeserver1.someu.edu\r\n    - notarealtimeserver2.someu.edu\r\n<\/code><\/pre>\n<p>This overrides the standard server settings in the common.yaml for notaserver.someu.edu.yaml<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>For the past several years, a locally written Puppet module has been used to setup NTP. The local NTP module was created to support Ubuntu 10.04. The RHEL\/CENTOS 5\/6 machines were configured to setup NTP during kickstart. Recently some RHEL 6 and Ubuntu 12.04 machines were brought under puppet server without having NTP setup. Fortunately [&hellip;]<\/p>\n","protected":false},"author":22,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-62","post","type-post","status-publish","format-standard","hentry","category-updates"],"_links":{"self":[{"href":"https:\/\/pages.charlotte.edu\/mark-hamrick\/wp-json\/wp\/v2\/posts\/62","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pages.charlotte.edu\/mark-hamrick\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pages.charlotte.edu\/mark-hamrick\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pages.charlotte.edu\/mark-hamrick\/wp-json\/wp\/v2\/users\/22"}],"replies":[{"embeddable":true,"href":"https:\/\/pages.charlotte.edu\/mark-hamrick\/wp-json\/wp\/v2\/comments?post=62"}],"version-history":[{"count":5,"href":"https:\/\/pages.charlotte.edu\/mark-hamrick\/wp-json\/wp\/v2\/posts\/62\/revisions"}],"predecessor-version":[{"id":66,"href":"https:\/\/pages.charlotte.edu\/mark-hamrick\/wp-json\/wp\/v2\/posts\/62\/revisions\/66"}],"wp:attachment":[{"href":"https:\/\/pages.charlotte.edu\/mark-hamrick\/wp-json\/wp\/v2\/media?parent=62"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pages.charlotte.edu\/mark-hamrick\/wp-json\/wp\/v2\/categories?post=62"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pages.charlotte.edu\/mark-hamrick\/wp-json\/wp\/v2\/tags?post=62"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}