{"id":754,"date":"2019-08-21T11:01:22","date_gmt":"2019-08-21T08:01:22","guid":{"rendered":"https:\/\/blog.airmeno.ru\/?p=754"},"modified":"2019-08-21T11:04:27","modified_gmt":"2019-08-21T08:04:27","slug":"phpmyadmin-na-debian-10","status":"publish","type":"post","link":"https:\/\/blog.airmeno.ru\/?p=754","title":{"rendered":"PhpMyAdmin \u043d\u0430 Debian 10"},"content":{"rendered":"\n<p>\u0412\u043e\u0442 \u0438 \u0432\u044b\u0448\u043b\u0430 \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u0430\u044f \u0432\u0435\u0440\u0441\u0438\u044f Linux Debian 10 Buster (10.0.0). <\/p>\n\n\n\n<p>\u041f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u043b \u043f\u043e\u0434\u043d\u044f\u0442\u044c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 LAMP:<\/p>\n\n\n\n<ul><li>Apache\/2.4.38 (Debian)<\/li><li>PHP Version 7.3.4<\/li><li>MariaDB 10.3<\/li><\/ul>\n\n\n\n<p>\u041e\u0434\u043d\u0430\u043a\u043e \u043f\u0430\u043a\u0435\u0442\u0430 phpMyAdmin \u043d\u0435 \u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c \u0432 \u043a\u0430\u043d\u0434\u0438\u0434\u0430\u0442\u0430\u0445 \u043d\u0430 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443, \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u0441\u043e\u0431\u0438\u0440\u0430\u0442\u044c \u0432\u0440\u0443\u0447\u043d\u0443\u044e. \u041d\u0430\u0434\u0435\u044e\u0441\u044c \u0441\u043a\u043e\u0440\u043e \u043f\u043e\u044f\u0432\u0438\u0442\u0441\u044f \u0432 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f\u0445 Debian. <\/p>\n\n\n\n<!--more-->\n\n\n\n<p><strong>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 phpMyAdmin \u043d\u0430 Debian 10 (\u0438\u043b\u0438 \u0441\u0431\u043e\u0440\u043a\u0430 phpMyAdmin \u0432\u0440\u0443\u0447\u043d\u0443\u044e)<\/strong><\/p>\n\n\n\n<p>1. \u041f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u043d\u0430 \u0441\u0430\u0439\u0442 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 phpMyAdmin &#8212; <a href=\"https:\/\/www.phpmyadmin.net\/downloads\/\">https:\/\/www.phpmyadmin.net\/downloads\/<\/a> \u0438 \u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0441\u0441\u044b\u043b\u043a\u0443 \u043d\u0430 \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e.<\/p>\n\n\n\n<p>2. \u0421\u043a\u0430\u0447\u0438\u0432\u0430\u0435\u043c \u0438 \u0440\u0430\u0437\u0430\u0440\u0445\u0438\u0432\u0438\u0440\u0443\u0435\u043c: <\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>wget https:\/\/files.phpmyadmin.net\/phpMyAdmin\/4.9.0.1\/phpMyAdmin-4.9.0.1-all-languages.tar.gz\ntar xvf phpMyAdmin-4.9.0.1-all-languages.tar.gz\nrm phpMyAdmin*.gz<\/code><\/pre>\n\n\n\n<p>3. \u041f\u0435\u0440\u0435\u043d\u043e\u0441\u0438\u043c \u043f\u0430\u043f\u043a\u0443 phpmyadmin \u0432 \/usr\/share\/phpmyadmin:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>mv phpMyAdmin-* \/usr\/share\/phpmyadmin<\/code><\/pre>\n\n\n\n<p>4. \u0421\u043e\u0437\u0434\u0430\u0435\u043c \u043f\u0430\u043f\u043a\u0443 \u0434\u043b\u044f \u0432\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u0444\u0430\u0439\u043b\u043e\u0432 phpMyAdmin \u0438 \u0437\u0430\u0434\u0430\u0435\u043c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u043f\u0440\u0430\u0432\u0430:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>mkdir -p \/var\/lib\/phpmyadmin\/tmp\nchown -R www-data:www-data \/var\/lib\/phpmyadmin<\/code><\/pre>\n\n\n\n<p>5. \u0421\u043e\u0437\u0434\u0430\u0435\u043c \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0439 \u0444\u0430\u0439\u043b phpMyAdmin \u0438 \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u0443\u0435\u043c:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>cp \/usr\/share\/phpmyadmin\/config.sample.inc.php \n \/usr\/share\/phpmyadmin\/config.inc.php\n\nnano \/usr\/share\/phpmyadmin\/config.inc.php\n\n# \u041f\u0430\u0440\u043e\u043b\u044c\u043d\u0430\u044f \u0444\u0440\u0430\u0437\u0430 (\u043c\u043e\u0436\u043d\u043e \u0441\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0442\u0443\u0442 - https:\/\/phpsolved.com\/phpmyadmin-blowfish-secret-generator\/\n$cfg['blowfish_secret'] = 'H2OxcGXxflSd8JwrwVlh6KW6s2rER63i'; \n# \u043f\u0430\u043f\u043a\u0430 \u0432\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u0444\u0430\u0439\u043b\u043e\u0432\n$cfg['TempDir'] = '\/var\/lib\/phpmyadmin\/tmp';<\/code><\/pre>\n\n\n\n<p>6. \u0421\u043e\u0437\u0434\u0430\u0435\u043c \u0431\u0430\u0437\u0443 \u0432 MySQL \u0434\u043b\u044f phpMyAdmin:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>mysql &lt; \/usr\/share\/phpmyadmin\/sql\/create_tables.sql -u root<\/code><\/pre>\n\n\n\n<p>7. \u0421\u043e\u0437\u0434\u0430\u0439\u0442\u0435 \u043a\u0430\u0442\u0430\u043b\u043e\u0433 \u0434\u043b\u044f \u0444\u0430\u0439\u043b\u043e\u0432 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 phpMyAdmin, \u0442\u0430\u043a\u0438\u0445 \u043a\u0430\u043a \u0444\u0430\u0439\u043b htpass:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>mkdir \/etc\/phpmyadmin\/<\/code><\/pre>\n\n\n\n<p>8. \u0421\u043e\u0437\u0434\u0430\u0435\u043c \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0439 \u0444\u0430\u0439\u043b \u0434\u043b\u044f \u0430\u043b\u0438\u0430\u0441\u0430 phpMyAdmin \u0432 Apache:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>touch \/etc\/apache2\/conf-available\/phpmyadmin.conf\nln -s \/etc\/apache2\/conf-available\/phpmyadmin.conf \/etc\/apache2\/conf-enabled\/phpmyadmin.conf\n\nnano \/etc\/apache2\/conf-available\/phpmyadmin.conf\n\nAlias \/phpmyadmin \/usr\/share\/phpmyadmin\n\n&lt;Directory \/usr\/share\/phpmyadmin>\n    Options SymLinksIfOwnerMatch\n    DirectoryIndex index.php\n\n    &lt;IfModule mod_php5.c>\n        &lt;IfModule mod_mime.c>\n            AddType application\/x-httpd-php .php\n        &lt;\/IfModule>\n        &lt;FilesMatch \".+\\.php$\">\n            SetHandler application\/x-httpd-php\n        &lt;\/FilesMatch>\n\n        php_value include_path .\n        php_admin_value upload_tmp_dir \/var\/lib\/phpmyadmin\/tmp\n        php_admin_value open_basedir \/usr\/share\/phpmyadmin\/:\/etc\/phpmyadmin\/:\/var\/lib\/phpmyadmin\/:\/usr\/share\/php\/php-gettext\/:\/usr\/share\/php\/php-php-gettext\/:\/usr\/share\/javascript\/:\/usr\/share\/php\/tcpdf\/:\/usr\/share\/doc\/phpmyadmin\/:\/usr\/share\/php\/phpseclib\/\n        php_admin_value mbstring.func_overload 0\n    &lt;\/IfModule>\n    &lt;IfModule mod_php.c>\n        &lt;IfModule mod_mime.c>\n            AddType application\/x-httpd-php .php\n        &lt;\/IfModule>\n        &lt;FilesMatch \".+\\.php$\">\n            SetHandler application\/x-httpd-php\n        &lt;\/FilesMatch>\n\n        php_value include_path .\n        php_admin_value upload_tmp_dir \/var\/lib\/phpmyadmin\/tmp\n        php_admin_value open_basedir \/usr\/share\/phpmyadmin\/:\/etc\/phpmyadmin\/:\/var\/lib\/phpmyadmin\/:\/usr\/share\/php\/php-gettext\/:\/usr\/share\/php\/php-php-gettext\/:\/usr\/share\/javascript\/:\/usr\/share\/php\/tcpdf\/:\/usr\/share\/doc\/phpmyadmin\/:\/usr\/share\/php\/phpseclib\/\n        php_admin_value mbstring.func_overload 0\n    &lt;\/IfModule>\n\n&lt;\/Directory>\n\n# Authorize for setup\n&lt;Directory \/usr\/share\/phpmyadmin\/setup>\n    &lt;IfModule mod_authz_core.c>\n        &lt;IfModule mod_authn_file.c>\n            AuthType Basic\n            AuthName \"phpMyAdmin Setup\"\n            AuthUserFile \/etc\/phpmyadmin\/htpasswd.setup\n        &lt;\/IfModule>\n        Require valid-user\n    &lt;\/IfModule>\n&lt;\/Directory>\n\n# Disallow web access to directories that don't need it\n&lt;Directory \/usr\/share\/phpmyadmin\/templates>\n    Require all denied\n&lt;\/Directory>\n&lt;Directory \/usr\/share\/phpmyadmin\/libraries>\n    Require all denied\n&lt;\/Directory>\n&lt;Directory \/usr\/share\/phpmyadmin\/setup\/lib>\n    Require all denied\n&lt;\/Directory>\n\n# Disallow web access to directories that don't need it\n&lt;Directory \/usr\/share\/phpmyadmin\/templates>\n    Require all denied\n&lt;\/Directory>\n&lt;Directory \/usr\/share\/phpmyadmin\/libraries>\n    Require all denied\n&lt;\/Directory>\n&lt;Directory \/usr\/share\/phpmyadmin\/setup\/lib>\n    Require all denied\n&lt;\/Directory><\/code><\/pre>\n\n\n\n<p>9. \u0412\u043a\u043b\u044e\u0447\u0430\u0435\u043c \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044e:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>a2enconf phpmyadmin.conf<\/code><\/pre>\n\n\n\n<p>10. \u041f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u043d\u0430\u0448 Apache:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>systemctl reload apache2<\/code><\/pre>\n\n\n\n<p>11. \u0421\u043e\u0437\u0434\u0430\u0435\u043c \u043f\u0440\u0438\u0432\u0438\u043b\u0435\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0433\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0434\u043b\u044f phpMyAdmin \u0438 MySQL, \u043f\u043e\u0434 \u044d\u0442\u0438\u043c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u0438 \u0431\u0443\u0434\u0435\u043c \u043b\u043e\u0433\u0438\u043d\u0438\u0442\u044c\u0441\u044f \u0432 phpMyAdmin:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>mysql -u root\nGRANT ALL PRIVILEGES ON *.* TO 'admin_user'@'localhost' IDENTIFIED BY 'admin_password' WITH GRANT OPTION;\nFLUSH PRIVILEGES;\nEXIT;<\/code><\/pre>\n\n\n\n<p>\u0413\u043e\u0442\u043e\u0432\u043e. \u0422\u0435\u043f\u0435\u0440\u044c phpMyAdmin \u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u043f\u043e \u0430\u0434\u0440\u0435\u0441\u0443 http:\/\/IP_our_domain\/phpmyadmin.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u0412\u043e\u0442 \u0438 \u0432\u044b\u0448\u043b\u0430 \u0441\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u0430\u044f \u0432\u0435\u0440\u0441\u0438\u044f Linux Debian 10 Buster (10.0.0). \u041f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u043b \u043f\u043e\u0434\u043d\u044f\u0442\u044c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 LAMP: Apache\/2.4.38 (Debian) PHP Version 7.3.4 MariaDB 10.3 \u041e\u0434\u043d\u0430\u043a\u043e \u043f\u0430\u043a\u0435\u0442\u0430 phpMyAdmin \u043d\u0435 \u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c&#46;&#46;&#46;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[4,5],"tags":[12,82],"_links":{"self":[{"href":"https:\/\/blog.airmeno.ru\/index.php?rest_route=\/wp\/v2\/posts\/754"}],"collection":[{"href":"https:\/\/blog.airmeno.ru\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.airmeno.ru\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.airmeno.ru\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.airmeno.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=754"}],"version-history":[{"count":4,"href":"https:\/\/blog.airmeno.ru\/index.php?rest_route=\/wp\/v2\/posts\/754\/revisions"}],"predecessor-version":[{"id":758,"href":"https:\/\/blog.airmeno.ru\/index.php?rest_route=\/wp\/v2\/posts\/754\/revisions\/758"}],"wp:attachment":[{"href":"https:\/\/blog.airmeno.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=754"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.airmeno.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=754"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.airmeno.ru\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=754"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}