{"id":1032,"date":"2017-10-03T14:07:36","date_gmt":"2017-10-03T05:07:36","guid":{"rendered":"https:\/\/www.dogrow.net\/linux\/?p=1032"},"modified":"2018-04-14T00:44:47","modified_gmt":"2018-04-13T15:44:47","slug":"blog59","status":"publish","type":"post","link":"https:\/\/www.dogrow.net\/linux\/blog59\/","title":{"rendered":"(59)\u3010\u9023\u8f091-3\u3011VirtualBox\u4e0a\u306eUbuntu\u306bXdebug\u3092\u5165\u308c\u308b"},"content":{"rendered":"<p>\u9023\u8f09\uff13\u56de\u76ee\u3001\u524d\u56de\u306e <a href=\"https:\/\/www.dogrow.net\/linux\/blog58\/\">\u300c(58)\u3010\u9023\u8f092\u3011VirtualBox\u4e0a\u306eUbuntu\u3092WEB\u30b5\u30fc\u30d0\u30fc\u306b\u3059\u308b\u300d<\/a> \u306e\u7d9a\u304d\u3067\u3059\u3002<\/p>\n<h1 class=\"my_h\">\u3053\u306e\u9023\u8f09\u3067\u6700\u7d42\u7684\u306b\u3084\u308a\u305f\u3044\u3053\u3068<\/h1>\n<p>CentOS7\u3092\u5165\u308c\u305f\u7269\u7406\u30b5\u30fc\u30d0\u30fc\u306b VirtualBox\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3001<br \/>\n\u3000VirtualBox\u306e\u4eee\u60f3\u30de\u30b7\u30f3\u4e0a\u3067 Ubuntu\u306e\u4eee\u60f3\u30b5\u30fc\u30d0\u30fc\u3092\u52d5\u304b\u3057\u3001<br \/>\n\u3000\u3000Ubuntu\u306e\u4eee\u60f3\u30b5\u30fc\u30d0\u30fc\u4e0a\u3067 WEB\u30b5\u30fc\u30d0\u30fc\u3092\u52d5\u304b\u3057\u3001<br \/>\n\u3000\u3000\u3000eclipse \uff0b xdebug, PhpStorm + xdebug\u3067\u30ea\u30e2\u30fc\u30c8\u30c7\u30d0\u30c3\u30b0\u3057\u305f\u3044\u3002<\/p>\n<h1 class=\"my_h\">\u4eca\u56de\u3084\u308a\u305f\u3044\u3053\u3068<\/h1>\n<p><a href=\"https:\/\/www.dogrow.net\/linux\/blog57\/\">\u3010\u9023\u8f091\u3011\u524d\u3005\u56de\u306e\u6295\u7a3f\u3067\u306f\u3001<\/a><br \/>\nCentOS7\u3092\u5165\u308c\u305f\u7269\u7406\u30b5\u30fc\u30d0\u30fc\u306b VirtualBox\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3001Ubuntu\u306e\u4eee\u60f3\u30b5\u30fc\u30d0\u30fc\u3092\u52d5\u304b\u3057\u305f\u3002<\/p>\n<p><a href=\"https:\/\/www.dogrow.net\/linux\/blog58\/\">\u3010\u9023\u8f092\u3011\u524d\u56de\u306e\u6295\u7a3f\u3067\u306f\u3001<\/a><br \/>\n\u3053\u306eUbuntu\u3092 WEB\u30b5\u30fc\u30d0\u30fc\u3068\u3057\u3066\u4f7f\u3044\u3001PHP\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u52d5\u304b\u3057\u3066MySQL\u3092\u5236\u5fa1\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u305f\u3002<\/p>\n<p>\u4eca\u56de\u306f\u3001<br \/>\n\u3053\u306e Ubuntu\u306b Xdebug\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3001Windows\u30d1\u30bd\u30b3\u30f3\u304b\u3089PHP\u30ea\u30e2\u30fc\u30c8\u30c7\u30d0\u30c3\u30b0\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u305f\u3044\u3002<br \/>\n\u3068\u308a\u3042\u3048\u305a\u4eca\u56de\u306f xdebug\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306e\u307f\u3002<\/p>\n<h1 class=\"my_h\">(1) \u5fc5\u8981\u306a\u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/h1>\n<p>\u524d\u56de\u306e\u6295\u7a3f\u3067 PHP 7.0\u3092\u5165\u308c\u305f\u306e\u3067\u3001\u3053\u3053\u3067\u3082 7.0\u7528\u306e\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u5165\u308c\u308b\u3002<\/p>\n<pre class=\"my_pre\">\r\nsudo apt install php7.0-dev php-pear php7.0-xdebug\r\n<\/pre>\n<p>Xdebug\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u3002<\/p>\n<pre class=\"my_pre\">\r\nsudo pecl install xdebug\r\n<\/pre>\n<h1 class=\"my_h\" style=\"margin-top:2.5rem !important\">(2) PHP\u306e\u8a2d\u5b9a\u3092\u5909\u66f4<\/h1>\n<p>Xdebug\u3092\u6709\u52b9\u5316\u3059\u308b\u3002<br \/>\n<span class=\"my_fs_small1 my_fc_darkgray\">\u203b\u524d\u56de\u306e\u6295\u7a3f\u3067 PHP 7.0\u3092\u5165\u308c\u305f\u306e\u3067\u3001\u305d\u306e\u914d\u4e0b\u306e php.ini\u3092\u7de8\u96c6\u3059\u308b\u3002<\/span><\/p>\n<pre class=\"my_pre\">\r\nsudo vi \/etc\/php\/7.0\/apache2\/php.ini\r\n<\/pre>\n<p>Xdebug\u95a2\u9023\u306e\u8a18\u8ff0\u3092\u8ffd\u52a0\u3059\u308b\u3002<\/p>\n<pre class=\"my_pre\">\r\nzend_extension=\"\/usr\/lib\/php\/20151012\/xdebug.so\"\r\nxdebug.remote_enable=1\r\nxdebug.remote_autostart=1\r\nxdebug.profiler_enable=1\r\nxdebug.profiler_output_dir=\"\/tmp\"\r\nxdebug.max_nesting_level=1000\r\nxdebug.remote_handler=dbgp\r\nxdebug.remote_host=127.0.0.1\r\n; xdebug.remote_host=192.168.1.6\r\nxdebug.remote_port=9000\r\nxdebug.idekey=\"XXXXXXXX\"\r\n<\/pre>\n<p><span class=\"my_fs_small1 my_fc_red\">zend_extension \u306f\u5b9f\u969b\u306b xdebug.so\u304c\u7f6e\u304b\u308c\u3066\u3044\u308b\u5834\u6240\u3092\u8a2d\u5b9a\u3059\u308b\u3002<br \/>\nremote_host \u306f\u63a5\u7d9a\u76f8\u624b\u3067\u3042\u308b\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u5074\u306b\u5408\u308f\u305b\u3066\u8a2d\u5b9a\u3059\u308b\u3002<br \/>\nremote_port \u306f\u63a5\u7d9a\u76f8\u624b\u3067\u3042\u308b\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u5074\u306b\u5408\u308f\u305b\u3066\u8a2d\u5b9a\u3059\u308b\u3002<br \/>\nidekey \u306f\u63a5\u7d9a\u76f8\u624b\u3067\u3042\u308b\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u5074\u306b\u5408\u308f\u305b\u3066\u8a2d\u5b9a\u3059\u308b\u3002<\/span><\/p>\n<p>php.ini\u306e\u5909\u66f4\u3092\u53cd\u6620\u3055\u305b\u308b\u305f\u3081\u306b Apache2\u3092\u518d\u8d77\u52d5\u3059\u308b\u3002<\/p>\n<pre class=\"my_pre\">\r\nsudo systemctl restart apache2\r\nsudo systemctl status apache2\r\n<\/pre>\n<h1 class=\"my_h\" style=\"margin-top:2.5rem !important\">(3) \u8a2d\u5b9a\u3067\u304d\u305f\u304b\u306a\uff1f<\/h1>\n<p>\u524d\u56de\u306e <a href=\"https:\/\/www.dogrow.net\/linux\/blog58\/\">\u300c(58) VirtualBox\u4e0a\u306eUbuntu\u3092WEB\u30b5\u30fc\u30d0\u30fc\u306b\u3059\u308b\u300d<\/a> \u3067\u4f5c\u6210\u3057\u305f phpinfo\u95b2\u89a7\u30da\u30fc\u30b8\u3092\u898b\u3066\u307f\u308b\u3002<br \/>\n<img decoding=\"async\" src=\"https:\/\/www.dogrow.net\/linux\/wp-content\/uploads\/2017\/10\/Image3-1.png\" alt=\"\" \/><\/p>\n<p>Xdebug\u306e\u60c5\u5831\u304c\u5217\u6319\u3055\u308c\u3066\u3044\u308b\u3002\u7121\u4e8b\u306b\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3067\u304d\u305f\u3088\u3046\u3060\u3002<\/p>\n<hr class=\"my_hr_bottom\">\n","protected":false},"excerpt":{"rendered":"<p>\u9023\u8f09\uff13\u56de\u76ee\u3001\u524d\u56de\u306e \u300c(58)\u3010\u9023\u8f092\u3011VirtualBox\u4e0a\u306eUbuntu\u3092WEB\u30b5\u30fc\u30d0\u30fc\u306b\u3059\u308b\u300d \u306e\u7d9a\u304d\u3067\u3059\u3002 \u3053\u306e\u9023\u8f09\u3067\u6700\u7d42\u7684\u306b\u3084\u308a\u305f\u3044\u3053\u3068 CentOS7\u3092\u5165\u308c\u305f\u7269\u7406\u30b5\u30fc\u30d0\u30fc\u306b VirtualBox\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u2026 <span class=\"read-more\"><a href=\"https:\/\/www.dogrow.net\/linux\/blog59\/\">\u7d9a\u304d\u3092\u8aad\u3080 &raquo;<\/a><\/span><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[81],"tags":[],"class_list":["post-1032","post","type-post","status-publish","format-standard","hentry","category-xdebug"],"views":4735,"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.dogrow.net\/linux\/wp-json\/wp\/v2\/posts\/1032","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.dogrow.net\/linux\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.dogrow.net\/linux\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.dogrow.net\/linux\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.dogrow.net\/linux\/wp-json\/wp\/v2\/comments?post=1032"}],"version-history":[{"count":29,"href":"https:\/\/www.dogrow.net\/linux\/wp-json\/wp\/v2\/posts\/1032\/revisions"}],"predecessor-version":[{"id":1410,"href":"https:\/\/www.dogrow.net\/linux\/wp-json\/wp\/v2\/posts\/1032\/revisions\/1410"}],"wp:attachment":[{"href":"https:\/\/www.dogrow.net\/linux\/wp-json\/wp\/v2\/media?parent=1032"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.dogrow.net\/linux\/wp-json\/wp\/v2\/categories?post=1032"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.dogrow.net\/linux\/wp-json\/wp\/v2\/tags?post=1032"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}