How To Install Adminer On Linux Mint 18.03
How to install Adminer on Linux mint 18.03
Adminer is a database management tool written in PHP similar to phpmyadmin which can support databases like MySQL, PostgreSQL, MS SQL and Oracle. In this tutorial, we will cover the installation of adminer on Linux mint-18.03.
Prerequisites
Install LAMP (Apache, MariaDB, php7.2) In MariaDB (create database and user and give privileges to that user)
Php installation with required following modules
add-apt-repository ppa:ondrej/php
apt-get update
apt-get install php7.2 php7.2-mysql php7.2-curl php7.2-json php7.2-cgi libapache2-mod-php7.2 php7.2-mcrypt php7.2-xmlrpc php7.2-gd php7.2-mbstring php7.2 php7.2-common php7.2-xmlrpc php7.2-soap php7.2-xml php7.2-intl php7.2-cli php7.2-ldap php7.2-zip php7.2-readline php7.2-imap php7.2-tidy php7.2-recode php7.2-sq php7.2-intl
Download a Adminer package by using wget command.
linuxhelp ~ # wget https://github.com/vrana/adminer/releases/download/v4.6.3/adminer-4.6.3.zip
--2018-09-15 17:01:48-- https://github.com/vrana/adminer/releases/download/v4.6.3/adminer-4.6.3.zip
Resolving github.com (github.com)... 192.30.253.113, 192.30.253.112
Connecting to github.com (github.com)|192.30.253.113|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://github-production-release-asset-2e65be.s3.amazonaws.com/627735/d5c2e3f0-7b1e-11e8-8c88-096e142a8d39?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20180915%2Fus-e
.
.
.
2e65be.s3.amazonaws.com)|52.216.105.51|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 709239 (693K) [application/octet-stream]
Saving to: ‘adminer-4.6.3.zip’
adminer-4.6.3.zip 100%[====================================>] 692.62K 316KB/s in 2.2s
2018-09-15 17:01:53 (316 KB/s) - ‘adminer-4.6.3.zip’ saved [709239/709239]
After Downloading extract the downloaded package
linuxhelp ~ # unzip adminer-4.6.3.zip -d adminer
Archive: adminer-4.6.3.zip
3d84dcf859e8fc6866febaa768c965dc5b11d3b8
creating: adminer/adminer-4.6.3/
inflating: adminer/adminer-4.6.3/.travis.yml
creating: adminer/adminer-4.6.3/adminer/
inflating: adminer/adminer-4.6.3/adminer/call.inc.php
inflating: adminer/adminer-4.6.3/adminer/create.inc.php
.
.
.
inflating: adminer/adminer-4.6.3/externals/jush/modules/jush-php.js
inflating: adminer/adminer-4.6.3/externals/jush/modules/jush-simpledb.js
inflating: adminer/adminer-4.6.3/externals/jush/modules/jush-sqlite.js
inflating: adminer/adminer-4.6.3/externals/jush/modules/jush-sql.js
inflating: adminer/adminer-4.6.3/externals/jush/modules/jush-textarea.js
inflating: adminer/adminer-4.6.3/externals/jush/modules/jush-txt.js
Change ownership and permission of the as adminer follows
linuxhelp ~ # ls
adminer adminer-4.6.3.zip
linuxhelp ~ # chown -R www-data:www-data adminer
linuxhelp ~ # chmod -R 775 adminer
Move the extracted file into the HTML directory
linuxhelp ~ # mv adminer /var/www/html/
Create a new virtual host configuration for accessing the adminer
linuxhelp ~ # cd /etc/apache2/sites-available/
linuxhelp sites-available # vim admin.conf
<VirtualHost *:80>
ServerName www.linuxhelp1.com
DocumentRoot /var/www/html/adminer/
<Directory /var/www/html/adminer/>
AllowOverride All
Allow from all
</Directory>
</VirtualHost>
Enable site access
linuxhelp sites-available # a2ensite admin.conf
Enabling site admin.
To activate the new configuration, you need to run:
service apache2 reload
Entry to the host file.
linuxhelp sites-available #vim /etc/hosts
<Give your ip> <Give your domain name>
Restart the apache service to make the changes effect
linuxhelp sites-available # systemctl restart apache2
Now you can proceed the further installation and configuration from the browser by navigating to the following URL: http://<ipaddress or domain name
You can log in using the database credentials
The newly created database appears in the Adminer. Now the user can view and work with the database and their associated tables.
With this, the method to install adminer on Linux mint 18.03 comes to an end.
MySQL,
PostgreSQL,
SQLite and Oracle databases
# echo " Alias /adminer.php /usr/share/adminer/adminer.php" | sudo tee /etc/apache2/conf-available/adminer.conf
~# echo " Alias /adminer.php /usr/share/adminer/adminer.php" | sudo tee /etc/apache2/conf-available/adminer.conf