{"id":512,"date":"2019-02-21T22:15:52","date_gmt":"2019-02-21T13:15:52","guid":{"rendered":"https:\/\/windabaft.co.jp\/blog_ceo\/?p=512"},"modified":"2019-02-21T22:26:40","modified_gmt":"2019-02-21T13:26:40","slug":"webarena-vps-centos-7-4-apache-%e3%82%a4%e3%83%b3%e3%82%b9%e3%83%88%e3%83%bc%e3%83%ab","status":"publish","type":"post","link":"https:\/\/windabaft.co.jp\/blog_ceo\/?p=512","title":{"rendered":"WebArena VPS CentOS 7.4 \u3078\u306e Apache2.4.6 \u30a4\u30f3\u30b9\u30c8\u30fc\u30eb"},"content":{"rendered":"\n<p>WebArena VPS CentOS 7.4 \u3078\u306eApache2.4.6\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u65b9\u6cd5\u3092\u4e01\u5be7\u306b\u89e3\u8aac<br \/>\u203bMac\u306e\u30bf\u30fc\u30df\u30ca\u30eb\u5229\u7528<br \/><br \/>WebArena\u306e\u30b3\u30f3\u30d1\u30cd\u3067\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u30fc\u30b0\u30eb\u30fc\u30d7\u306b<br \/>ssh\u30dd\u30fc\u30c8\u306e22\u3001\u30a6\u30a7\u30d6\u30dd\u30fc\u30c8\u306e80\u306e\u30a2\u30af\u30bb\u30b9\u3092\u53ef\u80fd\u306b\u3057\u3066\u304a\u304f<\/p>\n\n\n\n<p>tcp:22,22,ip4:0.0.0.0\/0 \uff08\u81ea\u5206\u306eIP\u30a2\u30c9\u30ec\u30b9\u3092\u5165\u308c\u308b\u307b\u3046\u304c\u30d9\u30bf\u30fc\uff09<br \/> tcp:80,80,ip4:0.0.0.0\/0\uff08\u81ea\u5206\u306eIP\u30a2\u30c9\u30ec\u30b9\u3092\u5165\u308c\u308b\u307b\u3046\u304c\u30d9\u30bf\u30fc\uff09<\/p>\n\n\n\n<p>WebArena\u306e\u30b3\u30f3\u30d1\u30cd\u3067\u30ad\u30fc\u30da\u30a2\uff08\uff0a\uff0a\uff0a.pem)\u3092\u4f5c\u6210\u3057\u3001\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9<br \/><br \/>\u304a\u305d\u3089\u304fssh\u30ad\u30fc\u3092\u307e\u3068\u3081\u3066\u3044\u308b\u3068\u601d\u3046\u306e\u3067\u3001Mac\u306essh\u30ad\u30fc\u3092\u4fdd\u5b58\u3057\u3066\u3044\u308b\u30d5\u30a9\u30eb\u30c0\u306b\u5165\u308c\u3066\u304a\u304f<br \/>\u3061\u306a\u307f\u306b\u5f8c\u3067\u9593\u9055\u3048\u306a\u3044\u3088\u3046\u306b\u3059\u308b\u305f\u3081\u306b\u30ea\u30cd\u30fc\u30e0\u3057\u3066\u304a\u304f\u3068\u3044\u3044\u304b\u3082<br \/><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>mv \u5143\u306e\u30d5\u30a1\u30a4\u30eb\u540d.pem \u5909\u66f4\u5f8c\u306e\u30d5\u30a1\u30a4\u30eb\u540d.pem<\/code><\/pre>\n\n\n\n<p>\u30bf\u30fc\u30df\u30ca\u30eb\u304b\u3089SSH\u3067VPS\u306b\u63a5\u7d9a\u3059\u308b<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo ssh root@VPS\u306eIP\u30a2\u30c9\u30ec\u30b9 -i \u30ad\u30fc\u30da\u30a2\u306e\u540d\u524d.pem<\/code><\/pre>\n\n\n\n<p>Apache\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u30d5\u30a1\u30a4\u30eb\u3092\u8abf\u3079\u3066\u304a\u304f\u3068<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code># yum list | grep httpd\nhttpd.x86_64                           2.4.6-88.el7.centos        base          \nhttpd-devel.x86_64                     2.4.6-88.el7.centos        base          \nhttpd-manual.noarch                    2.4.6-88.el7.centos        base          \nhttpd-tools.x86_64                     2.4.6-88.el7.centos        base          \nkeycloak-httpd-client-install.noarch   0.6-3.el7                  base          \nlibmicrohttpd.i686                     0.9.33-2.el7               base          \nlibmicrohttpd.x86_64                   0.9.33-2.el7               base          \nlibmicrohttpd-devel.i686               0.9.33-2.el7               base          \nlibmicrohttpd-devel.x86_64             0.9.33-2.el7               base          \nlibmicrohttpd-doc.noarch               0.9.33-2.el7               base          \npython2-keycloak-httpd-client-install.noarch\n<\/code><\/pre>\n\n\n\n<p>\u4e0b\u8a18\uff14\u3064\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308c\u3070OK<br \/>httpd.x86_64                           2.4.6-88.el7.centos        base          <br \/>httpd-devel.x86_64                     2.4.6-88.el7.centos        base          <br \/>httpd-manual.noarch                    2.4.6-88.el7.centos        base          <br \/>httpd-tools.x86_64  <br \/><\/p>\n\n\n\n<p>Apache\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>yum -y install httpd httpd-tools httpd-devel httpd-manual\n\u9762\u5012\u3067\u3042\u308c\u3070\u4e0b\u8a18\u3067\u3082\u3088\u3044\nyum -y install httpd<\/code><\/pre>\n\n\n\n<p>Apache\u304c\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u308c\u305f\u304b\u3092\u78ba\u8a8d\u3001\u30d0\u30fc\u30b8\u30e7\u30f3\u3082\u78ba\u8a8d<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code># yum list installed | grep httpd\nhttpd.x86_64                       2.4.6-88.el7.centos            @base         \nhttpd-devel.x86_64                 2.4.6-88.el7.centos            @base         \nhttpd-manual.noarch                2.4.6-88.el7.centos            @base         \nhttpd-tools.x86_64                 2.4.6-88.el7.centos            @base  \n\n# httpd -version\nServer version: Apache\/2.4.6 (CentOS)<\/code><\/pre>\n\n\n\n<p>Apache\u3092\u8d77\u52d5\u3057\u3066\u8d77\u52d5\u3057\u305f\u30b5\u30fc\u30d3\u30b9\u306e\u72b6\u614b\u3092\u78ba\u8a8d<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code># systemctl start httpd\n# systemctl status httpd\n\u25cf httpd.service - The Apache HTTP Server\n   Loaded: loaded (\/usr\/lib\/systemd\/system\/httpd.service; disabled; vendor preset: disabled)\n   Active: active (running) since \u6728 2019-02-21 20:16:27 JST; 26min ago\n     Docs: man:httpd(8)\n           man:apachectl(8)\n Main PID: 1182 (httpd)\n   Status: \"Total requests: 0; Current requests\/sec: 0; Current traffic:   0 B\/sec\"\n   CGroup: \/system.slice\/httpd.service\n           \u251c\u25001182 \/usr\/sbin\/httpd -DFOREGROUND\n           \u251c\u25001183 \/usr\/sbin\/httpd -DFOREGROUND\n           \u251c\u25001184 \/usr\/sbin\/httpd -DFOREGROUND\n           \u251c\u25001185 \/usr\/sbin\/httpd -DFOREGROUND\n           \u251c\u25001186 \/usr\/sbin\/httpd -DFOREGROUND\n           \u2514\u25001187 \/usr\/sbin\/httpd -DFOREGROUND\n.....<\/code><\/pre>\n\n\n\n<p>firewall-cmd\u30b3\u30de\u30f3\u30c9\u3067\u3001http\u30a2\u30af\u30bb\u30b9\u3059\u308b\u305f\u3081\u306e80\u756a\u30dd\u30fc\u30c8\u306b\u5916\u90e8\u304b\u3089\u306e\u63a5\u7d9a\u3092\u8a31\u53ef\u8a2d\u5b9a\u3092\u8ffd\u52a0\u3000(iptables\u30b3\u30de\u30f3\u30c9\u3067\u884c\u3063\u3066\u3082\u3088\u3044\uff09<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code># firewall-cmd --add-service=http --permanent\nsuccess\n\n\u8a2d\u5b9a\u3092\u53cd\u6620\u3059\u308b\u305f\u3081\u306b\u518d\u8aad\u307f\u8fbc\u307f\n# firewall-cmd --reload\nsuccess\n\n\u8a2d\u5b9a\u306e\u78ba\u8a8d\n# firewall-cmd --list-all\npublic (active)\n  target: default\n  icmp-block-inversion: no\n  interfaces: eth0\n  sources: \n  services: ssh dhcpv6-client http\n  ports: \n  protocols: \n  masquerade: no\n  forward-ports: \n  source-ports: \n  icmp-blocks: \n  rich rules: <\/code><\/pre>\n\n\n\n<p><strong>services: ssh dhcpv6-client http<\/strong><br \/>\u306e\u3088\u3046\u306bhttp\u304c\u8ffd\u52a0\u3055\u308c\u3066\u3044\u308c\u3070OK<br \/>Web\u30d6\u30e9\u30a6\u30b6\u304b\u3089\u4e0b\u8a18\u306b\u30a2\u30af\u30bb\u30b9\u3057\u3066\u30da\u30fc\u30b8\u304c\u8868\u793a\u3055\u308c\u308c\u3070OK<br \/>http:\/\/IP\u30a2\u30c9\u30ec\u30b9\/<\/p>\n","protected":false},"excerpt":{"rendered":"<p>WebArena VPS CentOS 7.4 \u3078\u306eApache2.4.6\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u65b9\u6cd5\u3092\u4e01\u5be7\u306b\u89e3\u8aac\u203bMac\u306e\u30bf\u30fc\u30df\u30ca\u30eb\u5229\u7528 WebArena\u306e\u30b3\u30f3\u30d1\u30cd\u3067\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u30fc\u30b0\u30eb\u30fc\u30d7\u306bssh\u30dd\u30fc\u30c8\u306e22\u3001\u30a6\u30a7\u30d6\u30dd\u30fc\u30c8\u306e80 &hellip; <a href=\"https:\/\/windabaft.co.jp\/blog_ceo\/?p=512\" class=\"more-link\">\u7d9a\u304d\u3092\u8aad\u3080 <span class=\"screen-reader-text\">WebArena VPS CentOS 7.4 \u3078\u306e Apache2.4.6 \u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":514,"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,"footnotes":""},"categories":[15],"tags":[],"class_list":["post-512","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-linux"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/windabaft.co.jp\/blog_ceo\/index.php?rest_route=\/wp\/v2\/posts\/512","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/windabaft.co.jp\/blog_ceo\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/windabaft.co.jp\/blog_ceo\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/windabaft.co.jp\/blog_ceo\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/windabaft.co.jp\/blog_ceo\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=512"}],"version-history":[{"count":2,"href":"https:\/\/windabaft.co.jp\/blog_ceo\/index.php?rest_route=\/wp\/v2\/posts\/512\/revisions"}],"predecessor-version":[{"id":516,"href":"https:\/\/windabaft.co.jp\/blog_ceo\/index.php?rest_route=\/wp\/v2\/posts\/512\/revisions\/516"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/windabaft.co.jp\/blog_ceo\/index.php?rest_route=\/wp\/v2\/media\/514"}],"wp:attachment":[{"href":"https:\/\/windabaft.co.jp\/blog_ceo\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=512"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/windabaft.co.jp\/blog_ceo\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=512"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/windabaft.co.jp\/blog_ceo\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=512"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}