Installing phpMyAdmin Manually

From Sympl Wiki
Revision as of 18:52, 2 January 2020 by Kelduum (talk | contribs)
Jump to navigation Jump to search
This article is Beta Documentation. It may have missing elements, or be unclear in places.
Please feel free to make corrections or amendments, or ask for help on the Sympl Forum

This guide covers installing phpMyAdmin on a server running Sympl 10.x, on Debian Buster. phpMyAdmin is included in Sympl 9.x, as the package is included in Debian Stretch.

This guide is aimed at moderate-to-experienced users, and as such care should be taken when following it.

Installing phpMyAdmin

cd to your destination htdocs dir, such as a subdirectory of an existing site (, or a separate subdomain (

wget -O - | tar -zxv --strip 1

sympl create database phpmyadmin

cat sql/create_tables.sql | mysql -u phpmyadmin -p$( cat /home/sympl/mysql_phpmyadmin_password ) phpmyadmin

rm -rf setup/ test/

mkdir tmp ; sudo chown www-data:www-data tmp ; sudo chmod 770 tmp


echo "\$cfg['blowfish_secret'] = '$( openssl rand -base64 32 | cut -c 1-32 )';" >>

echo "\$cfg['UploadDir'] = '$(pwd | cut -d'/' -f 1-4)';" >>
echo "\$cfg['SaveDir'] = '$(pwd | cut -d'/' -f 1-4)';" >>

echo -e "AuthType Basic\nAuthName \"Restricted Access\"\nAuthUserFile /home/sympl/phpmyadmin.passwd\nRequire valid-user\n" > .htaccess

Now, set the access up:

touch $(pwd | cut -d'/' -f 1-3)/config/ssl-only # enforce ssl-only mode for the site.
htpasswd -c /home/sympl/phpmyadmin.passwd phpmyadmin # set a password

You should then be able to browse to the site, log in with the username phpmyadmin and the password specified, and then log into individual databases or as the sympl user which has the equivalent of root access.

Things to know

  • The password for the sympl database user can be found in /home/sympl/mysql_password.
  • If databases were created with sympl create database, their passwords can be found in /home/sympl/mysql_databasename_password
  • Initial authentication (and users) can be updated in /home/sympl/phpmyadmin.passwd in normal htpasswd format. phpMyAdmin has no automatic updating, so ensure you use a strong password.
  • The safest way to update phpMyAdmin at present would be to follow these instructions again.