{"id":4112,"date":"2021-02-14T11:54:43","date_gmt":"2021-02-14T02:54:43","guid":{"rendered":"https:\/\/lab4ict.com\/system\/?p=4112"},"modified":"2023-06-22T05:22:25","modified_gmt":"2023-06-21T20:22:25","slug":"ubuntu-20-04%e3%81%abzabbix%e3%82%92%e3%82%a4%e3%83%b3%e3%82%b9%e3%83%88%e3%83%bc%e3%83%ab%e3%81%99%e3%82%8b%ef%bc%81","status":"publish","type":"post","link":"https:\/\/lab4ict.com\/system\/archives\/4112","title":{"rendered":"Zabbix\uff08Server\uff09\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\uff01\uff08Ubuntu 20.04\uff09"},"content":{"rendered":"<p>Ubuntu 20.04\u306bZabbix\u306eServer\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n<h2>\u4f7f\u7528\u3057\u305f\u74b0\u5883<\/h2>\n<ul>\n<li>Ubuntu Desktop 20.04 LTS (20.04.1)<\/li>\n<\/ul>\n<h2>\u7ba1\u7406\u8005\u30e6\u30fc\u30b6\u306b\u30b9\u30a4\u30c3\u30c1\u3059\u308b\uff01<\/h2>\n<p>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u4f5c\u696d\u306f\u57fa\u672c\u7684\u306broot\u30e6\u30fc\u30b6\u3067\u884c\u3046\u305f\u3081\u3001\u6700\u521d\u306broot\u30e6\u30fc\u30b6\u306b\u30b9\u30a4\u30c3\u30c1\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ sudo su -\r\n#\r\n<\/pre>\n<h2>MariaDB\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\uff01<\/h2>\n<p>MariaDB\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n<h3>MariaDB\u3092\u30d1\u30c3\u30b1\u30fc\u30b8\u304b\u3089\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\uff01<\/h3>\n<p>MariaDB\u3092\u30d1\u30c3\u30b1\u30fc\u30b8\u304b\u3089\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# apt update\r\n# apt install -y mariadb-server\r\n<\/pre>\n<h3>MariaDB\u306e\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u8a2d\u5b9a\u3092\u884c\u3046\uff01<\/h3>\n<p>\u300cmysql_secure_installation\u300d\u30b3\u30de\u30f3\u30c9\u3067\u3001MariaDB\u306e\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u8a2d\u5b9a\u3092\u884c\u3044\u307e\u3059\u3002root\u30e6\u30fc\u30b6\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u3068\u5404\u7a2e\u554f\u3044\u5408\u308f\u305b\u306b\"y\"\u3092\u5165\u529b\u3057\u3066\u3001\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u5bfe\u5fdc\u3092\u884c\u3044\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# mysql_secure_installation\r\n<\/pre>\n<h2>Zabbix\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\uff01<\/h2>\n<p>\u4ee5\u4e0b\u306e\u30da\u30fc\u30b8\u3067\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u74b0\u5883\u306e\u9078\u629e\u3092\u884c\u3044\u3001Zabbix\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n<ul>\n<li><a href=\"https:\/\/www.zabbix.com\/download\" target=\"_blank\" rel=\"noopener\">Download and install Zabbix<\/a><\/li>\n<\/ul>\n<p>\u4eca\u56de\u306f\u3001\u4ee5\u4e0b\u306e\u74b0\u5883\u306e\u9078\u629e\u3092\u884c\u3044\u307e\u3059\u3002<\/p>\n<ul>\n<li>Zabbix version : 5.0 LTS<\/li>\n<li>OS Distribution : Ubuntu<\/li>\n<li>OS Version : 20.04 (Focal)<\/li>\n<li>Database : MySQL<\/li>\n<li>Web Server : Apache<\/li>\n<\/ul>\n<h3>Zabbix\u306e\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u767b\u9332\u3059\u308b\uff01<\/h3>\n<p>Zabbix\u306e\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u767b\u9332\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# wget https:\/\/repo.zabbix.com\/zabbix\/5.0\/ubuntu\/pool\/main\/z\/zabbix-release\/zabbix-release_5.0-1+focal_all.deb\r\n# dpkg -i zabbix-release_5.0-1+focal_all.deb\r\n# apt update\r\n<\/pre>\n<h3>Zabbix\u306e\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\uff01<\/h3>\n<p>Zabbix\u306e\u30b5\u30fc\u30d0\u3001\u30d5\u30ed\u30f3\u30c8\u30a8\u30f3\u30c9\u3001\u30a8\u30fc\u30b8\u30a8\u30f3\u30c8\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# apt install zabbix-server-mysql zabbix-frontend-php zabbix-apache-conf zabbix-agent\r\n<\/pre>\n<h3>Zabbix\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3092\u4f5c\u6210\u3059\u308b\uff01<\/h3>\n<p>Zabbix\u7528\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3092\u4f5c\u6210\u3057\u307e\u3059\u3002password\u306f\u3001mysql_secure_installation\u3067\u6307\u5b9a\u3057\u305froot\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u5165\u529b\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# mysql -uroot -p\r\npassword\r\nmysql&gt; create database zabbix character set utf8 collate utf8_bin;\r\nmysql&gt; create user zabbix@localhost identified by 'zabbix';\r\nmysql&gt; grant all privileges on zabbix.* to zabbix@localhost;\r\nmysql&gt; quit;\r\n<\/pre>\n<h3>Zabbix\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3092\u521d\u671f\u8a2d\u5b9a\u3059\u308b\uff01<\/h3>\n<p>Zabbix\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3092\u521d\u671f\u8a2d\u5b9a\u3057\u307e\u3059\u3002\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u805e\u304b\u308c\u307e\u3059\u304c\u3001\u76f4\u524d\u3067\u8a2d\u5b9a\u3057\u305fzabbix\u30e6\u30fc\u30b6\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\uff08zabbix\uff09\u3092\u5165\u529b\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# zcat \/usr\/share\/doc\/zabbix-server-mysql*\/create.sql.gz | mysql -uzabbix -p zabbix\r\n<\/pre>\n<p>Zabbix\u306e\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb\u306b\u3001DB\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u8a2d\u5b9a\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# vi \/etc\/zabbix\/zabbix_server.conf\r\n...\r\nDBPassword=zabbix\r\n...:wq\r\n\r\n<\/pre>\n<h3>PHP\u306e\u30bf\u30a4\u30e0\u30be\u30fc\u30f3\u3092\u8a2d\u5b9a\u3059\u308b\uff01<\/h3>\n<p>Apache\u306ePHP\u306e\u8a2d\u5b9a\u3067\u3001timezone\u3092\u8a2d\u5b9a\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# vi \/etc\/php\/7.4\/apache2\/php.ini\r\n...\r\n&#x5B;Date]\r\n; Defines the default timezone used by the date functions\r\n; http:\/\/php.net\/date.timezone\r\n;date.timezone =\r\ndate.timezone = Asia\/Tokyo\r\n...\r\n<\/pre>\n<h3>Zabbix\u3092\u8d77\u52d5\u3059\u308b\uff01<\/h3>\n<p>Zabbix\u306e\u30b5\u30fc\u30d3\u30b9\u3092\u518d\u8d77\u52d5\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n# systemctl restart zabbix-server zabbix-agent apache2\r\n# systemctl enable zabbix-server zabbix-agent apache2\r\n<\/pre>\n<h2>Zabbix\u306eWebUI\u306e\u521d\u671f\u8a2d\u5b9a\u3092\u884c\u3046\uff01<\/h2>\n<p>Zabbix\u306eWebUI\u306e\u521d\u671f\u8a2d\u5b9a\u3092\u884c\u3044\u307e\u3059\u3002<\/p>\n<h3>Zabbix\u306eWebUI\u306b\u30a2\u30af\u30bb\u30b9\u3059\u308b\uff01<\/h3>\n<p>Zabbix\u306eWebUI\u306b\u306b\u30a2\u30af\u30bb\u30b9\u3057\u307e\u3059\u3002<\/p>\n<ul>\n<li><a href=\"http:\/\/localhost\/zabbix\" target=\"_blank\" rel=\"noopener\">Zabbix Welcome Page (localhost) : http:\/\/localhost\/zabbix<\/a><\/li>\n<\/ul>\n<p>\u30a6\u30a3\u30b6\u30fc\u30c9\u304c\u8868\u793a\u3055\u308c\u308b\u306e\u3067\u3001\u9806\u306b\u9032\u3081\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<h3>\u300cCheck of pre-requisites\u300d\u753b\u9762<\/h3>\n<p>\u3059\u3079\u3066\u3001\u300cOK\u300d\u306b\u306a\u3063\u3066\u3044\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3057\u3066\u3001\u300cNext step\u300d\u30dc\u30bf\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3057\u307e\u3059\u3002<\/p>\n<h3>\u300cConfigure DB connection\u300d\u753b\u9762<\/h3>\n<p>DB\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u300czabbix\u300d\u3092\u5165\u529b\u3057\u3066\u3001\u300cNext step\u300d\u30dc\u30bf\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3057\u307e\u3059\u3002<\/p>\n<h3>\u300cConfigure DB connection\u300d\u753b\u9762<\/h3>\n<p>Name\u306b\u8b58\u5225\u540d\u300czabbix-server-01\u300d\uff08\u4efb\u610f\uff09\u3092\u5165\u529b\u3057\u3066\u3001\u300cNext step\u300d\u30dc\u30bf\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3057\u307e\u3059\u3002<\/p>\n<h3>\u300cPre-installation summary\u300d\u753b\u9762<\/h3>\n<p>\u8a2d\u5b9a\u5185\u5bb9\u3092\u78ba\u8a8d\u3057\u3066\u3001\u300cNext step\u300d\u30dc\u30bf\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3057\u307e\u3059\u3002<\/p>\n<h3>\u300cInstall\u300d\u753b\u9762<\/h3>\n<p>\u554f\u984c\u306a\u304f\u521d\u671f\u8a2d\u5b9a\u304c\u5b8c\u4e86\u3059\u308c\u3070\u3001\u300cCongratulations! You have successfully installed Zabbix frontend.\u300d\u306e\u30e1\u30c3\u30bb\u30fc\u30b8\u304c\u8868\u793a\u3055\u308c\u308b\u306e\u3067\u3001\u300cFinish\u300d\u30dc\u30bf\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3057\u307e\u3059\u3002<\/p>\n<h2>Zabbix\u306b\u30ed\u30b0\u30a4\u30f3\u3059\u308b\uff01<\/h2>\n<p>\u30ed\u30b0\u30a4\u30f3\u753b\u9762\u304c\u8868\u793a\u3055\u308c\u308b\u306e\u3067\u3001\u30e6\u30fc\u30b6\u300cAdmin\u300d\u3001\u30d1\u30b9\u30ef\u30fc\u30c9\u300czabbix\u300d\u3067\u30ed\u30b0\u30a4\u30f3\u3057\u307e\u3059\u3002<\/p>\n<h2>\u304a\u308f\u308a\u306b<\/h2>\n<p>Zabbix\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306f\u3001\u82e5\u5e72\u9577\u624b\u9806\u3067\u3059\u304c\u3001\u96e3\u3057\u3044\u3068\u3053\u308d\u306f\u5c11\u306a\u3044\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<h2>\u53c2\u8003\u60c5\u5831<\/h2>\n<ul>\n<li><a href=\"https:\/\/www.zabbix.com\/\" target=\"_blank\" rel=\"noopener\">Zabbix<\/a><\/li>\n<\/ul>\n<h2>\u95a2\u9023\u8a18\u4e8b<\/h2>\n<div class=\"sc_getpost\"><a class=\"clearfix\" href=\"https:\/\/lab4ict.com\/system\/archives\/4198\" ><div class=\"sc_getpost_thumb post-box-thumbnail__wrap\"><img decoding=\"async\" src=\"data:image\/gif;base64,R0lGODdhAQABAPAAAN3d3QAAACwAAAAAAQABAAACAkQBADs=\" width=\"150\" height=\"150\" alt=\"\u3010\u8a18\u4e8b\u4e00\u89a7\u3011Zabbix\u3067\u904b\u7528\u76e3\u8996\u3092\u884c\u3046\uff01\" loading=\"lazy\" data-src=\"https:\/\/lab4ict.com\/system\/wp-content\/uploads\/2021\/02\/eycatch_zabbix_01-150x150.png\" class=\"lazyload\"><\/div><div class=\"title\">\u3010\u8a18\u4e8b\u4e00\u89a7\u3011Zabbix\u3067\u904b\u7528\u76e3\u8996\u3092\u884c\u3046\uff01<\/div><div class=\"substr\">Zabbix\u3067\u904b\u7528\u76e3\u8996\u3092\u884c\u3046\u305f\u3081\u306e\u8a18\u4e8b\u4e00\u89a7\u3092\u63b2\u8f09\u3057\u307e\u3059\u3002...<\/div><\/a><\/div>\n<h2>Zabbix\u66f8\u7c4d\uff08Amazon\uff09<\/h2>\n<p><iframe sandbox=\"allow-popups allow-scripts allow-modals allow-forms allow-same-origin\" style=\"width:120px;height:240px;\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\" frameborder=\"0\" src=\"\/\/rcm-fe.amazon-adsystem.com\/e\/cm?lt1=_blank&bc1=000000&IS2=1&bg1=FFFFFF&fc1=000000&lc1=0000FF&t=infotecr-22&language=ja_JP&o=9&p=8&l=as4&m=amazon&f=ifr&ref=as_ss_li_til&asins=B07TX5FXS5&linkId=7523c356aa348c010b768f66ad14e9f6\"><\/iframe><\/p>\n<hr \/>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Ubuntu 20.04\u306bZabbix\u306eServer\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002 \u4f7f\u7528\u3057\u305f\u74b0\u5883 Ubuntu Desktop 20.04 LTS (20.04.1) \u7ba1\u7406\u8005\u30e6\u30fc\u30b6\u306b\u30b9\u30a4\u30c3\u30c1\u3059\u308b\uff01 \u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u4f5c\u696d\u306f\u57fa\u672c\u7684\u306broot\u30e6\u30fc\u30b6\u3067\u884c\u3046\u305f\u3081\u2026<\/p>\n","protected":false},"author":1,"featured_media":7004,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[127],"tags":[51,562,461],"class_list":["post-4112","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-zabbix","tag-ubuntu","tag-zabbix","tag-461"],"_links":{"self":[{"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/posts\/4112","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/comments?post=4112"}],"version-history":[{"count":1,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/posts\/4112\/revisions"}],"predecessor-version":[{"id":12494,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/posts\/4112\/revisions\/12494"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/media\/7004"}],"wp:attachment":[{"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/media?parent=4112"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/categories?post=4112"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lab4ict.com\/system\/wp-json\/wp\/v2\/tags?post=4112"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}