{"id":1694,"date":"2017-10-25T02:47:45","date_gmt":"2017-10-24T17:47:45","guid":{"rendered":"http:\/\/matoken.org\/blog\/?p=1694"},"modified":"2017-10-25T03:58:43","modified_gmt":"2017-10-24T18:58:43","slug":"raspbian-jessie-ntp-setting","status":"publish","type":"post","link":"https:\/\/matoken.org\/blog\/2017\/10\/25\/raspbian-jessie-ntp-setting\/","title":{"rendered":"Raspbian jessie\u306entp\u8a2d\u5b9a"},"content":{"rendered":"<p>Raspbian\u306bntpd\u3084chrony\u3084ntpdate\u3068\u304b\u5c45\u306a\u3044\u3051\u3069\u4f55\u304c\u9762\u5012\u898b\u3066\u308b\u3093\u3060\u308d\u3046\u3066\u3053\u3068\u3067\u78ba\u8a8d\uff0e<br \/>\nsystemd\u304c\u9762\u5012\u898b\u3066\u3066timeatectl\u30b3\u30de\u30f3\u30c9\u3067\u78ba\u8a8d\u8a2d\u5b9a\u304c\u3067\u304d\u308b\u3089\u3057\u3044\uff0e<\/p>\n<pre><code>$ dpkg -l|egrep -i &quot;ntp|chrony&quot;\r\n$ systemctl -a | grep -i ntp\r\n<\/code><\/pre>\n<h2>\u4eca\u306e\u72b6\u614b\u3092\u78ba\u8a8d<\/h2>\n<pre><code>$ timedatectl status\r\n      Local time: Wed 2017-10-25 02:01:14 JST\r\n  Universal time: Tue 2017-10-24 17:01:14 UTC\r\n        RTC time: n\/a\r\n       Time zone: Asia\/Tokyo (JST, +0900)\r\n Network time on: yes\r\nNTP synchronized: yes\r\n RTC in local TZ: no\r\n<\/code><\/pre>\n<h2>NTP\u540c\u671f\u3092\u7121\u52b9\u306b\u3057\u3066\u307f\u308b<\/h2>\n<pre><code>$ sudo timedatectl set-ntp false\r\n<\/code><\/pre>\n<p>\u7121\u52b9\u306b\u306a\u3063\u305f( <em>Network time on: no<\/em> )<br \/>\n\u518d\u8d77\u52d5\u3059\u308b\u3068 <em>NTP synchronized<\/em> \u3082  <em>no<\/em> \u306b\u3082\u306a\u308b\uff0e<\/p>\n<pre><code>$ timedatectl status\r\n      Local time: Wed 2017-10-25 02:01:39 JST\r\n  Universal time: Tue 2017-10-24 17:01:39 UTC\r\n        RTC time: n\/a\r\n       Time zone: Asia\/Tokyo (JST, +0900)\r\n Network time on: no\r\nNTP synchronized: yes\r\n RTC in local TZ: no\r\n<\/code><\/pre>\n<h2>\u304a\u307e\u3051<\/h2>\n<h3>\u30bf\u30a4\u30e0\u30be\u30fc\u30f3\u306e\u78ba\u8a8d<\/h3>\n<pre><code>$ timedatectl list-timezones | grep -i tokyo\r\nAsia\/Tokyo\r\n<\/code><\/pre>\n<h3>\u30bf\u30a4\u30e0\u30be\u30fc\u30f3\u306e\u8a2d\u5b9a<\/h3>\n<pre><code>$ sudo timedatectl set-timezone\r\n<\/code><\/pre>\n<h3>\u4efb\u610f\u306entp server\u306e\u6307\u5b9a<\/h3>\n<p>dhcpd\u304b\u3089\u6e21\u3063\u3066\u304d\u305f\u3082\u306e\uff0e<\/p>\n<p>hdcpd\u306b\u7121\u3044\u5834\u5408 <strong>\/etc\/systemd\/timesyncd.conf<\/strong><br \/>\n\u306e <strong>NTP<\/strong> \u3068 <strong>FallbackNTP<\/strong><\/p>\n<h2>\u74b0\u5883<\/h2>\n<p>Raspbian stretch lite 2017-09-07(\u672aupdate)<\/p>\n<pre><code>$ lsb_release -a\r\nNo LSB modules are available.\r\nDistributor ID: Raspbian\r\nDescription:    Raspbian GNU\/Linux 9.1 (stretch)\r\nRelease:        9.1\r\nCodename:       stretch\r\n$ uname -a\r\nLinux raspberrypi 4.9.41+ #1023 Tue Aug 8 15:47:12 BST 2017 armv6l GNU\/Linux\r\n<\/code><\/pre>\n<p><iframe style=\"width:120px;height:240px;\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\" frameborder=\"0\" src=\"\/\/rcm-fe.amazon-adsystem.com\/e\/cm?lt1=_blank&#038;bc1=000000&#038;IS2=1&#038;bg1=FFFFFF&#038;fc1=000000&#038;lc1=0000FF&#038;t=matokensmeme-22&#038;o=9&#038;p=8&#038;l=as4&#038;m=amazon&#038;f=ifr&#038;ref=as_ss_li_til&#038;asins=B01CSFZ4JG&#038;linkId=2946871293902d278ffaffca5986d620\"><\/iframe><iframe style=\"width:120px;height:240px;\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\" frameborder=\"0\" src=\"\/\/rcm-fe.amazon-adsystem.com\/e\/cm?lt1=_blank&#038;bc1=000000&#038;IS2=1&#038;bg1=FFFFFF&#038;fc1=000000&#038;lc1=0000FF&#038;t=matokensmeme-22&#038;o=9&#038;p=8&#038;l=as4&#038;m=amazon&#038;f=ifr&#038;ref=as_ss_li_til&#038;asins=B018K9NNJW&#038;linkId=9bbe9b7e26fae6d7622a3b49a938da10\"><\/iframe><iframe style=\"width:120px;height:240px;\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\" frameborder=\"0\" src=\"\/\/rcm-fe.amazon-adsystem.com\/e\/cm?lt1=_blank&#038;bc1=000000&#038;IS2=1&#038;bg1=FFFFFF&#038;fc1=000000&#038;lc1=0000FF&#038;t=matokensmeme-22&#038;o=9&#038;p=8&#038;l=as4&#038;m=amazon&#038;f=ifr&#038;ref=as_ss_li_til&#038;asins=B075CXX8FV&#038;linkId=eb6f6788b65560d546dc2446ac49c4ac\"><\/iframe><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Raspbian\u306bntpd\u3084chrony\u3084ntpdate\u3068\u304b\u5c45\u306a\u3044\u3051\u3069\u4f55\u304c\u9762\u5012\u898b\u3066\u308b\u3093\u3060\u308d\u3046\u3066\u3053\u3068\u3067\u78ba\u8a8d\uff0e systemd\u304c\u9762\u5012\u898b\u3066\u3066timeatectl\u30b3\u30de\u30f3\u30c9\u3067\u78ba\u8a8d\u8a2d\u5b9a\u304c\u3067\u304d\u308b\u3089\u3057\u3044\uff0e $ dpkg -l|egrep [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"webmentions_disabled_pings":false,"webmentions_disabled":false,"activitypub_content_warning":"","activitypub_content_visibility":"","activitypub_max_image_attachments":4,"activitypub_interaction_policy_quote":"anyone","activitypub_status":"","footnotes":""},"categories":[98,91],"tags":[259,44,102],"class_list":["post-1694","post","type-post","status-publish","format-standard","hentry","category-rasbian_jessie","category-raspberry-pi","tag-ntp","tag-raspberrypi","tag-raspbian"],"_links":{"self":[{"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/posts\/1694","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/comments?post=1694"}],"version-history":[{"count":0,"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/posts\/1694\/revisions"}],"wp:attachment":[{"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/media?parent=1694"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/categories?post=1694"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/tags?post=1694"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}