{"id":7259,"date":"2021-02-05T11:33:49","date_gmt":"2021-02-05T02:33:49","guid":{"rendered":"https:\/\/pandanote.info\/?p=7259"},"modified":"2022-04-12T12:18:06","modified_gmt":"2022-04-12T03:18:06","slug":"%e3%83%90%e3%83%83%e3%82%af%e3%82%a8%e3%83%b3%e3%83%89%e3%81%aegrowi%e3%82%b5%e3%83%bc%e3%83%90%e3%81%ae%e9%9b%bb%e6%ba%90%e3%81%8c%e5%85%a5%e3%81%a3%e3%81%a6%e3%81%84%e3%81%aa%e3%81%84%e6%99%82","status":"publish","type":"post","link":"https:\/\/pandanote.info\/?p=7259","title":{"rendered":"\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u306eGROWI\u30b5\u30fc\u30d0\u306e\u96fb\u6e90\u304c\u5165\u3063\u3066\u3044\u306a\u3044\u6642\u306b\u3001\u300c503 \u305f\u3076\u3093\u30b5\u30fc\u30d0\u306e\u96fb\u6e90\u304c\u5207\u308c\u3066\u3044\u307e\u3059\u3002\u300d\u3068\u30d5\u30ed\u30f3\u30c8\u30a8\u30f3\u30c9\u306enginx\u306b\u8fd4\u3057\u3066\u3082\u3089\u3046\u305f\u3081\u306e\u8a2d\u5b9a\u306e\u3088\u3046\u306a\u3082\u306e(2\/2,\u66f8\u304d\u8fbc\u307f\u5074\u306e\u304a\u8a71)\u3002"},"content":{"rendered":"<h2>\u306f\u3058\u3081\u306b<\/h2>\n<p><a href=\"https:\/\/pandanote.info\/?p=7242\">\u524d\u306e\u8a18\u4e8b<\/a>\u3067\u30a4\u30f3\u30bf\u30fc\u30cd\u30c3\u30c8\u5074\u3067\u7a3c\u50cd\u3057\u3066\u3044\u308bnginx\u30b5\u30fc\u30d0(\u4ee5\u4e0b\u3001\u5358\u306b\u300cnginx\u30b5\u30fc\u30d0\u300d\u3068\u66f8\u304d\u307e\u3059\u3002)\u3092\u3044\u3044\u611f\u3058\u306b\u8a2d\u5b9a\u3057\u3066\u3001MariaDB\u306e\u30c6\u30fc\u30d6\u30eb\u304b\u3089\u30c7\u30fc\u30bf\u3092\u8aad\u307f\u51fa\u3059\u65b9\u6cd5\u306b\u3064\u3044\u3066\u66f8\u304d\u307e\u3057\u305f\u3002<\/p>\n<p>\u305d\u3053\u3067\u3001\u3053\u306e\u8a18\u4e8b\u3067\u306f\u81ea\u5b85\u30b5\u30fc\u30d0\u5074\u3067\u7a3c\u50cd\u3057\u3066\u3044\u308bGROWI\u30b5\u30fc\u30d0(\u4ee5\u4e0b\u3001\u5358\u306b\u300cGROWI\u30b5\u30fc\u30d0\u300d\u3068\u66f8\u304d\u307e\u3059\u3002)\u306e\u72b6\u614b\u306e\u901a\u77e5\u7528\u306e\u5165\u308c\u7269(\u4ee5\u4e0b\u5358\u306b\u300c\u5165\u308c\u7269\u300d\u3068\u66f8\u304d\u307e\u3059\u3002)\u306b\u7a3c\u50cd\u72b6\u614b\u3092\u66f8\u304d\u8fbc\u3080\u305f\u3081\u306b\u5fc5\u8981\u306a\u8a2d\u5b9a\u306b\u3064\u3044\u3066\u66f8\u304d\u307e\u3059\u3002<\/p>\n<h2>\u524d\u63d0\u6761\u4ef6<\/h2>\n<p>\u3053\u306e\u8a18\u4e8b\u3067\u767b\u5834\u3059\u308bnginx\u30b5\u30fc\u30d0\u3068GROWI\u30b5\u30fc\u30d0\u306fOpenVPN\u3067\u63a5\u7d9a\u3055\u308c\u3066\u3044\u307e\u3059(GROWI\u30b5\u30fc\u30d0\u304c\u7a3c\u50cd\u3057\u3066\u3044\u308bPC\u304cactive\u306a\u72b6\u614b\u3067\u3042\u308b\u5834\u5408\u306b\u9650\u308a\u307e\u3059)\u3002<\/p>\n<p><a href=\"https:\/\/pandanote.info\/?attachment_id=2053\" rel=\"attachment wp-att-2053\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/pandanote.info\/wordpress\/wp-content\/uploads\/2018\/05\/openvpn_chart-300x126.png\" alt=\"\" width=\"300\" height=\"126\" class=\"alignnone size-medium wp-image-2053\" srcset=\"https:\/\/pandanote.info\/wordpress\/wp-content\/uploads\/2018\/05\/openvpn_chart-300x126.png 300w, https:\/\/pandanote.info\/wordpress\/wp-content\/uploads\/2018\/05\/openvpn_chart.png 599w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>\u4e0a\u56f3\u306e&#8221;OpenVPN Server&#8221;\u5074\u306bnginx\u30b5\u30fc\u30d0\u304c\u3001&#8221;OpenVPN Client&#8221;\u5074\u306bGROWI\u30b5\u30fc\u30d0\u304c\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u308c\u3066\u3044\u308b\u30a4\u30e1\u30fc\u30b8\u3067\u3059\u3002\u81ea\u5b85\u30b5\u30fc\u30d0\u3067\u3042\u308bGROWI\u30b5\u30fc\u30d0\u306f\u300c\u6c17\u304c\u5411\u3044\u305f\u6642\u3060\u3051\u300d\u7a3c\u50cd\u3059\u308b\u30b5\u30fc\u30d0\u304c\u3067\u3042\u308b(*1)\u305f\u3081\u3001OpenVPN\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306b\u306f\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u3068\u3057\u3066\u53c2\u52a0\u3055\u305b\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u4e0a\u8a18\u306e\u6761\u4ef6(*1)\u304c\u3053\u306e\u5f8c\u3067\u767b\u5834\u3059\u308b\u8a2d\u5b9a\u306e\u5185\u5bb9\u306b\u5730\u5473\u306b\u52b9\u3044\u3066\u304d\u307e\u3059\u3002<\/p>\n<h2>\u6e96\u5099\u3059\u308b\u30d5\u30a1\u30a4\u30eb<\/h2>\n<p>nginx\u30b5\u30fc\u30d0\u4e0a\u306b\u3042\u308b\u5165\u308c\u7269\u306e\u6b63\u4f53\u306fMariaDB\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306e\u30c6\u30fc\u30d6\u30eb\u3067\u3042\u308b\u3053\u3068\u306f<a href=\"https:\/\/pandanote.info\/?p=7242\">\u524d\u306e\u8a18\u4e8b<\/a>\u3067\u66f8\u304d\u307e\u3057\u305f\u304c\u3001\u3053\u308c\u306bGROWI\u30b5\u30fc\u30d0\u306e\u7a3c\u50cd\u72b6\u614b\u3092\u66f8\u304d\u8fbc\u3080\u305f\u3081\u306b\u306f\u3001GROWI\u30b5\u30fc\u30d0\u306e\u8d77\u52d5\u30fb\u7d42\u4e86\u7528\u306e\u30d5\u30a1\u30a4\u30eb(Fedora 33\u3067\u306f\u30e6\u30cb\u30c3\u30c8\u30d5\u30a1\u30a4\u30eb)\u3092\u66f8\u304d\u3001\u305d\u306e\u30d5\u30a1\u30a4\u30eb\u304b\u3089\u5165\u308c\u7269\u306b\u5bfe\u3057\u3066\u7a3c\u50cd\u72b6\u614b\u3092\u66f8\u304d\u8fbc\u3080\u305f\u3081\u306e\u30b3\u30de\u30f3\u30c9(SQL\u6587)\u3092\u5b9f\u884c\u3059\u308c\u3070\u826f\u3055\u305d\u3046\u3067\u3059\u3002<\/p>\n<p>\u305d\u3053\u3067\u3001\u4ee5\u4e0b\u306e2\u500b\u306e\u30d5\u30a1\u30a4\u30eb\u3092\u7528\u610f\u3057\u307e\u3059\u3002<\/p>\n<ol>\n<li>growi.service: \u30e6\u30cb\u30c3\u30c8\u30d5\u30a1\u30a4\u30eb\u3067\u3059\u3002<\/li>\n<li>startgrowi.sh: \u5b9f\u969b\u306bGROWI\u30b5\u30fc\u30d0\u306e\u8d77\u52d5\u30fb\u505c\u6b62\u306e\u5b9f\u884c\u53ca\u3073\u7a3c\u50cd\u72b6\u614b\u3092\u66f8\u304d\u8fbc\u3080\u305f\u3081\u306eSQL\u6587\u306e\u767a\u884c\u3092\u884c\u3046shell script\u3002<\/li>\n<\/ol>\n<h2>\u30b3\u30fc\u30c9\u4f8b<\/h2>\n<h3>growi.service<\/h3>\n<p>growi.service\u306e\u30b3\u30fc\u30c9\u4f8b\u306f\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u611f\u3058\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p><script src=\"https:\/\/gist.github.com\/pandanote-info\/f9e5fe76aef911ff8d62cc4cdc388aa8.js\"><\/script><\/p>\n<p>nginx\u30b5\u30fc\u30d0\u53ca\u3073GROWI\u30b5\u30fc\u30d0\u306e\u9593\u306e\u63a5\u7d9a\u306fOpenVPN\u306b\u3088\u308b\u63a5\u7d9a\u306b\u306a\u308a\u307e\u3059\u306e\u3067\u3001\u63a5\u7d9a\u304c\u78ba\u7acb\u3057\u3066\u3044\u308b\u72b6\u614b\u306e\u5834\u5408\u306b\u9650\u308a\u3001\u6b21\u7bc0\u306estartgrowi.sh\u3092\u5b9f\u884c\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059(\u63a5\u7d9a\u304c\u78ba\u7acb\u3055\u308c\u305f\u72b6\u614b\u3067\u306a\u3044\u3068\u3001\u7a3c\u50cd\u72b6\u614b\u3092\u66f8\u304d\u8fbc\u3080\u305f\u3081\u306eSQL\u6587\u306e\u5b9f\u884c\u6642\u306bMariaDB\u30b5\u30fc\u30d0\u304c\u898b\u3064\u304b\u3089\u305a\u306b\u30a8\u30e9\u30fc\u306b\u306a\u3063\u3066\u3057\u307e\u3044\u307e\u3059)\u3002<\/p>\n<p>\u305d\u3053\u3067\u30013\u884c\u76ee\u306e\u8a2d\u5b9a\u306bOpenVPN\u306e\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306e\u958b\u59cb\u30fb\u7d42\u4e86\u7528\u306e\u30b5\u30fc\u30d3\u30b9\u30e6\u30cb\u30c3\u30c8\u30d5\u30a1\u30a4\u30eb(openvpn-client@client.service)\u3092\u8ffd\u52a0\u3057\u3066\u3044\u307e\u3059\u3002\u3053\u306e\u8a2d\u5b9a\u3092\u8ffd\u52a0\u3059\u308b\u3053\u3068\u3067\u3001\u30b7\u30b9\u30c6\u30e0\u8d77\u52d5\u6642\u306bOpenVPN\u306e\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u3092\u8d77\u52d5\u3057\u3066VPN\u63a5\u7d9a\u3092\u78ba\u7acb\u3057\u3066\u304b\u3089growi.service\u3092\u5b9f\u884c\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u307e\u305f\u3001\u30b7\u30b9\u30c6\u30e0\u7d42\u4e86\u6642\u306b\u306fgrowi.service\u2192OpenVPN\u306e\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306e\u9806\u756a\u306b(\u7d42\u4e86\u51e6\u7406\u3092)\u5b9f\u884c\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<h3>startgrowi.sh<\/h3>\n<p>startgrowi.sh\u306e\u30b3\u30fc\u30c9\u4f8b\u306f\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u611f\u3058\u306b\u306a\u308a\u307e\u3059(IP\u30a2\u30c9\u30ec\u30b9\u53ca\u3073\u30d1\u30b9\u30ef\u30fc\u30c9\u306e\u90e8\u5206\u306f\u66f8\u304d\u63db\u3048\u3066\u3042\u308a\u307e\u3059)\u3002<\/p>\n<p><script src=\"https:\/\/gist.github.com\/pandanote-info\/8b5de172f81542ac8e4e424e5d6231aa.js\"><\/script><\/p>\n<p>mysql\u30b3\u30de\u30f3\u30c9\u306fSQL\u6587\u3092\u5b9f\u884c\u3059\u308b\u3068\u7d42\u4e86\u3057\u3066\u51e6\u7406\u5236\u5fa1\u304cshell script\u5074(\u3053\u306e\u4f8b\u3067\u306fstartgrowi.sh)\u306b\u623b\u3063\u3066\u304f\u308b\u305f\u3081\u3001GROWI\u30b5\u30fc\u30d0\u306e\u958b\u59cb\u6642\u306b\u306fnpm\u30b3\u30de\u30f3\u30c9\u306e\u76f4\u524d\u306b\u3001\u7d42\u4e86\u6642\u306b\u306fpkill\u30b3\u30de\u30f3\u30c9\u306e\u76f4\u524d\u306b\u305d\u308c\u305e\u308c\u5b9f\u884c\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<h2>\u52d5\u4f5c\u78ba\u8a8d<\/h2>\n<h3>GROWI\u30b5\u30fc\u30d0\u306e\u7a3c\u50cd\u4e2d<\/h3>\n<p>GROWI\u30b5\u30fc\u30d0\u306e\u7a3c\u50cd\u4e2d\u306f\u3001\u6700\u65b0\u306e\u7a3c\u50cd\u72b6\u6cc1\u306f\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u611f\u3058\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre>MariaDB [serverstatus]> select * from serverstatus order by id desc limit 0,1;\r\n+----+--------+---------------------+\r\n| id | status | updated_at          |\r\n+----+--------+---------------------+\r\n| 46 |      1 | 2021-02-04 21:51:30 |\r\n+----+--------+---------------------+\r\n1 row in set (0.000 sec)\r\n<\/pre>\n<h3>GROWI\u30b5\u30fc\u30d0\u306e\u505c\u6b62\u4e2d<\/h3>\n<p>\u524d\u7bc0\u306e\u72b6\u614b\u306e\u3068\u304d\u306bGROWI\u30b5\u30fc\u30d0\u3092shutdown\u3059\u308b\u3068\u3001\u6700\u65b0\u306e\u7a3c\u50cd\u72b6\u6cc1\u306f\u2026<\/p>\n<pre>MariaDB [serverstatus]> select * from serverstatus order by id desc limit 0,1;\r\n+----+--------+---------------------+\r\n| id | status | updated_at          |\r\n+----+--------+---------------------+\r\n| 47 |      0 | 2021-02-04 22:35:17 |\r\n+----+--------+---------------------+\r\n1 row in set (0.000 sec)\r\n<\/pre>\n<p>\u306e\u3088\u3046\u306a\u611f\u3058\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u3046\u307e\u304f\u52d5\u4f5c\u3057\u3066\u3044\u308b\u3088\u3046\u3067\u3059\u3002\ud83d\udc4d<\/p>\n<p>ID\u306e\u5024\u304c\u5927\u304d\u3081\u306a\u306e\u306f\u6c17\u306b\u3057\u306a\u3044\u65b9\u5411\u3067\u304a\u9858\u3044\u3044\u305f\u3057\u307e\u3059\u3002<\/p>\n<h2>\u307e\u3068\u3081<\/h2>\n<p>OpenVPN\u63a5\u7d9a\u6642\u306e\u30e6\u30cb\u30c3\u30c8\u30d5\u30a1\u30a4\u30eb\u306e\u8a2d\u5b9a\u4f8b\u304cGoogle\u5148\u751f\u306b\u304a\u4f3a\u3044\u3092\u7acb\u3066\u3066\u3082\u898b\u3064\u304b\u3089\u305a\u3001MariaDB\u306b\u7a3c\u50cd\u72b6\u614b\u304c\u66f8\u304d\u8fbc\u3081\u306a\u3044\u5834\u5408\u304c\u3042\u3063\u3066\u3001\u305d\u306e\u539f\u56e0\u306e\u7a76\u660e\u306b\u624b\u9593\u53d6\u3063\u3066\u3057\u307e\u3063\u305f\u305f\u3081\u3001\u3053\u306e\u8a18\u4e8b\u3092\u66f8\u304f\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002<\/p>\n<p>\u307e\u305f\u3001\u8a2d\u5b9a\u306b\u5fc5\u8981\u306a\u30d5\u30a1\u30a4\u30eb\u304cOS\u306e\u8d77\u52d5\u30fb\u7d42\u4e86\u306b\u95a2\u9023\u3059\u308b\u8a2d\u5b9a\u3092\u884c\u3046\u3082\u306e\u3067\u3001<a href=\"https:\/\/pandanote.info\/?p=7242\">\u524d\u306e\u8a18\u4e8b<\/a>\u3067\u66f8\u3044\u305f\u8aad\u307f\u8fbc\u307f\u5074\u306e\u8a2d\u5b9a\u3068\u306f\u8a2d\u5b9a\u306e\u7a2e\u985e\u304c\u7570\u306a\u308b\u3088\u3046\u306b\u611f\u3058\u305f\u306e\u3067\u3001\u5225\u306e\u8a18\u4e8b\u306b\u5206\u5272\u3057\u3066\u66f8\u304f\u3053\u3068\u306b\u3057\u305f\u6b21\u7b2c\u3067\u3059\u3002<\/p>\n<p>\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306e\u30c6\u30fc\u30d6\u30eb\u306b\u72b6\u614b\u3092\u793a\u3059\u5909\u6570\u3092\u66f8\u304d\u8fbc\u3093\u3067\u30b5\u30d6\u30b7\u30b9\u30c6\u30e0\u9593\u306e\u540c\u671f\u3092\u3068\u308b\u65b9\u6cd5\u306f\u6975\u3081\u3066\u53e4\u5178\u7684\u306a\u65b9\u6cd5\u304b\u3082\u3057\u308c\u307e\u305b\u3093\u304c\u3001\u4f55\u304b\u306e\u53c2\u8003\u306b\u3057\u3066\u3044\u305f\u3060\u3051\u308b\u3068\u5e78\u3044\u3067\u3059\u3002<\/p>\n<p>\u3053\u306e\u8a18\u4e8b\u306f\u4ee5\u4e0a\u3067\u3059\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u306f\u3058\u3081\u306b \u524d\u306e\u8a18\u4e8b\u3067\u30a4\u30f3\u30bf\u30fc\u30cd\u30c3\u30c8\u5074\u3067\u7a3c\u50cd\u3057\u3066\u3044\u308bnginx\u30b5\u30fc\u30d0(\u4ee5\u4e0b\u3001\u5358\u306b\u300cnginx\u30b5\u30fc\u30d0\u300d\u3068\u66f8\u304d\u307e\u3059\u3002)\u3092\u3044\u3044\u611f\u3058\u306b\u8a2d\u5b9a\u3057\u3066\u3001MariaDB\u306e\u30c6\u30fc\u30d6\u30eb\u304b\u3089\u30c7\u30fc\u30bf\u3092\u8aad\u307f\u51fa\u3059\u65b9\u6cd5\u306b\u3064\u3044\u3066\u66f8\u304d\u307e\u3057\u305f\u3002 \u305d\u3053\u3067\u3001\u3053\u306e\u8a18\u4e8b\u3067\u306f\u81ea\u5b85\u30b5\u30fc\u30d0\u5074\u3067\u7a3c\u50cd\u3057\u3066\u3044\u308bGROWI\u30b5\u30fc\u30d0(\u4ee5\u4e0b\u3001\u5358\u306b\u300cGROWI\u30b5\u30fc\u30d0\u300d\u3068\u66f8\u304d\u307e\u3059\u3002)\u306e\u72b6\u614b\u306e\u901a\u77e5\u7528\u306e\u5165\u308c\u7269(\u4ee5\u4e0b\u5358\u306b\u300c\u5165\u308c\u7269\u300d\u3068\u66f8\u304d\u307e\u3059\u3002)\u306b\u7a3c\u50cd\u72b6\u614b\u3092\u66f8\u304d\u8fbc\u3080\u305f\u3081\u306b\u5fc5\u8981\u306a\u2026 <span class=\"read-more\"><a href=\"https:\/\/pandanote.info\/?p=7259\">Read More &raquo;<\/a><\/span><\/p>\n","protected":false},"author":1,"featured_media":7252,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8,42,15,3],"tags":[],"class_list":["post-7259","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-fedora","category-openvpn","category-pc","category-website-2"],"_links":{"self":[{"href":"https:\/\/pandanote.info\/index.php?rest_route=\/wp\/v2\/posts\/7259","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pandanote.info\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pandanote.info\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pandanote.info\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/pandanote.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=7259"}],"version-history":[{"count":15,"href":"https:\/\/pandanote.info\/index.php?rest_route=\/wp\/v2\/posts\/7259\/revisions"}],"predecessor-version":[{"id":7279,"href":"https:\/\/pandanote.info\/index.php?rest_route=\/wp\/v2\/posts\/7259\/revisions\/7279"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/pandanote.info\/index.php?rest_route=\/wp\/v2\/media\/7252"}],"wp:attachment":[{"href":"https:\/\/pandanote.info\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=7259"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pandanote.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=7259"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pandanote.info\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=7259"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}