Vesta Control Panel - Forum

Community Forum

Skip to content

Advanced search
  • Quick links
    • Main site
    • Github repo
    • Google Search
  • FAQ
  • Login
  • Register
  • Board index Main Section Database Server
  • Search

[GUIDE] How to replace phpMyAdmin by Adminer in Ubuntu 16.04 NGINX php-fpm

Questions regarding the Database Server
MySQL, PostgreSQL, MariaDB, Percona Server, phpMyAdmin, phpPgAdmin
Post Reply
  • Print view
Advanced search
23 posts
  • Previous
  • 1
  • 2
  • 3
  • Next
rhyker2u
Posts: 86
Joined: Thu Jan 19, 2017 11:46 am
Contact:
Contact rhyker2u
Website

Os: Ubuntu 17x
Web: nginx + php-fpm
Re: [GUIDE] How to replace phpMyAdmin by Adminer in Ubuntu 16.04 NGINX php-fpm
  • Quote

Post by rhyker2u » Fri Jan 05, 2018 11:17 am

addendum ... as I love linking 'cross-posting' solutions together. Even adminer ain't perfect when migrating databases to a new VestaCP server. Hence I highly recommend to read this VestaCP forum post on cli commands to migrate databases.
Top

rhyker2u
Posts: 86
Joined: Thu Jan 19, 2017 11:46 am
Contact:
Contact rhyker2u
Website

Os: Ubuntu 17x
Web: nginx + php-fpm
Re: [GUIDE] How to replace phpMyAdmin by Adminer in Ubuntu 16.04 NGINX php-fpm
  • Quote

Post by rhyker2u » Sun Mar 18, 2018 12:06 pm

Tip: Instead of having to run:

Code: Select all

sudo wget "https://www.adminer.org/latest.php" -O /usr/share/adminer/latest.php
manually at each and every update -- of which there have been two after creating the 1st post -- it's easier to create a cronjob for it. ;-)
Top

jasland
Posts: 3
Joined: Sun Apr 08, 2018 6:42 pm

Os: Ubuntu 15x
Web: nginx + php-fpm
Re: [GUIDE] How to replace phpMyAdmin by Adminer in Ubuntu 16.04 NGINX php-fpm
  • Quote

Post by jasland » Sun Apr 08, 2018 6:44 pm

When I import with adminer after a minute or two, it gives 500 error

regards
Top

jasland
Posts: 3
Joined: Sun Apr 08, 2018 6:42 pm

Os: Ubuntu 15x
Web: nginx + php-fpm
Re: [GUIDE] How to replace phpMyAdmin by Adminer in Ubuntu 16.04 NGINX php-fpm
  • Quote

Post by jasland » Tue Apr 10, 2018 8:34 am

When I import with adminer after one or two minutes, an error of 500 occurs.
The same thing happens when I try to move tables from one base to another.
Anyone else get this, is there a solution?
regards
Top

rhyker2u
Posts: 86
Joined: Thu Jan 19, 2017 11:46 am
Contact:
Contact rhyker2u
Website

Os: Ubuntu 17x
Web: nginx + php-fpm
Re: [GUIDE] How to replace phpMyAdmin by Adminer in Ubuntu 16.04 NGINX php-fpm
  • Quote

Post by rhyker2u » Sat Sep 08, 2018 1:52 pm

skurudo wrote: ↑
Tue Apr 18, 2017 7:34 am
rhyker2u wrote:Life is bliss again!
Only for nginx+php-fpm, sadly ;-)
You know whats really sad? That the same phpmyadmin errors as in the 1st post are occuring still at the current / latest VestaCP (v0.9.8-22) on a default Vultr Ubuntu 18.04 installation. :-p but yes you're right; the adminer replacement cli syntax suggestion does only work on nginx+php-fpm. Quick-fix / hack for Apache2 (with or without nginx as caching) seems to be to edit:

Code: Select all

nano /etc/apache2/conf.d/phpmyadmin.conf
And make these changes:

Code: Select all

#Alias /phpmyadmin /usr/share/phpmyadmin
Alias /phpmyadmin /usr/share/adminer
Far from perfect -- as commenting out other stuff is probably smart -- but it works. ;-)

With regards to ...
jasland wrote: ↑
Tue Apr 10, 2018 8:34 am
When I import with adminer after one or two minutes, an error of 500 occurs.
The same thing happens when I try to move tables from one base to another.
Anyone else get this, is there a solution?
regards
What kind of error 500? Being a little more specific sure helps ;-) However I always edit php.ini to support importing large DBs. And just got an error too when importing. Applying this fix https://stackoverflow.com/a/104176 pertaining MySQL error 1153 did the trick ( or override it in /etc/mysql/mysql.conf at line nr 23).
Top

realjumy
Posts: 50
Joined: Sun Jul 06, 2014 12:51 pm

Re: [GUIDE] How to replace phpMyAdmin by Adminer in Ubuntu 16.04 NGINX php-fpm
  • Quote

Post by realjumy » Tue Mar 05, 2019 1:50 pm

Is anyone brave enough to create this as a plugin/addon for VestaCP?
Top

dreiggy
Posts: 154
Joined: Thu May 17, 2018 8:05 pm
Contact:
Contact dreiggy
Skype

Os: CentOS 6x
Web: apache + nginx
Re: [GUIDE] How to replace phpMyAdmin by Adminer in Ubuntu 16.04 NGINX php-fpm
  • Quote

Post by dreiggy » Thu Mar 28, 2019 11:17 pm

skurudo wrote: ↑
Tue Apr 18, 2017 9:02 am
Adminer pretty nice.
Well, we thought about this. And some time ago made idea, but not so many votes for adminer - https://bugs.vestacp.com/issues/145
;-(
I have added Adminer pull request to installer as additional option: https://github.com/serghey-rodin/vesta/pull/1847
Now vesta developers should decide if merge it.

Manual installation of Adminer (CentOS)

All these steps should be done as root user. Adminer will be installed beside phpMyAdmin. So you would be able to use both. If you want, you may remove phpMyAdmin manually.

Adminer installation:

Code: Select all

mkdir -p /usr/share/adminer
wget "https://www.adminer.org/latest.php" -O /usr/share/adminer/index.php
NGINX:

Code: Select all

echo "location /adminer {
    alias /usr/share/adminer/;

    location ~ ^/adminer/(.*\.php)$ {
        alias /usr/share/adminer/$1;
        fastcgi_pass 127.0.0.1:9000;
        fastcgi_index index.php;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $request_filename;
    }
}
" > /etc/nginx/conf.d/adminer.inc
APACHE:

Code: Select all

echo "Alias /Adminer /usr/share/adminer
Alias /adminer /usr/share/adminer

<Directory /usr/share/adminer/>
   Order Deny,Allow
   Deny from All
   Allow from All
</Directory>
" > /etc/httpd/conf.d/adminer.conf
Reload or restar nginx and apache:

Code: Select all

service nginx restart && service httpd restart
Top

Spheerys
Posts: 225
Joined: Tue Dec 29, 2015 12:36 pm

Os: Debian 7x
Web: apache + nginx
Re: [GUIDE] How to replace phpMyAdmin by Adminer in Ubuntu 16.04 NGINX php-fpm
  • Quote

Post by Spheerys » Wed Apr 17, 2019 12:16 pm

I'm runing with apache2 and I switch to Adminer to several servers with success.
I follow my own small guide :
mkdir /usr/share/adminer
wget https://www.adminer.org/latest-mysql.php -O /usr/share/adminer/index.php
wget https://raw.githubusercontent.com/vrana ... dminer.css -O /usr/share/adminer/adminer.css
sed -i -e "s/\/usr\/share\/phpmyadmin/\/usr\/share\/adminer/" /etc/nginx/conf.d/phpmyadmin.inc
sed -i -e "s/\/usr\/share\/phpmyadmin/\/usr\/share\/adminer/" /etc/apache2/conf.d/phpmyadmin.conf
sed -i -e "s/php_admin_value/#php_admin_value/" /etc/apache2/conf.d/phpmyadmin.conf
systemctl restart nginx.service apache2.service
apt remove phpmyadmin
But I have a problem with the last server !
Maybe due to the removing of phpmyadmin : the system ask me about removing some phpmyadmin stuff and maybe I have answered the wrong anwser !!!

Now, when I'm trying to log in Adminer with correct user/pass I get this error :

Code: Select all

Access denied for user 'User_test'@'localhost' (using password: NO)
The mysql server running well by the way and I can connect from cli with

Code: Select all

mysql User_test -u User_test -p
How to solve the problem ?
Top

Nadayan
Posts: 3
Joined: Fri May 17, 2019 8:19 am

Os: Ubuntu 13x
Web: apache
Re: [GUIDE] How to replace phpMyAdmin by Adminer in Ubuntu 16.04 NGINX php-fpm
  • Quote

Post by Nadayan » Fri May 17, 2019 8:46 am

So that it works correctly phpmyadmin cannot be deleted? Or is this not the case?
Top

shally87
Posts: 2
Joined: Mon Mar 16, 2020 1:58 am

Os: CentOS 6x
Web: nginx + php-fpm
Re: [GUIDE] How to replace phpMyAdmin by Adminer in Ubuntu 16.04 NGINX php-fpm
  • Quote

Post by shally87 » Mon Mar 16, 2020 2:06 am

Thanks!
Works for CentOS too.
Top


Post Reply
  • Print view

23 posts
  • Previous
  • 1
  • 2
  • 3
  • Next

Return to “Database Server”



  • Board index
  • All times are UTC
  • Delete all board cookies
  • The team
Powered by phpBB® Forum Software © phpBB Limited
*Original Author: Brad Veryard
*Updated to 3.2 by MannixMD
 

 

Login  •  Register

I forgot my password