Skip to content

Instantly share code, notes, and snippets.

@devopslinuxadmin
Created September 30, 2019 16:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save devopslinuxadmin/20716e644a5679b0ee6f4664cb8f8e09 to your computer and use it in GitHub Desktop.
Save devopslinuxadmin/20716e644a5679b0ee6f4664cb8f8e09 to your computer and use it in GitHub Desktop.
install LAMP + PHPMyAdmin on Ubuntu
# Install apache
sudo apt install apache2
# Install PHP
sudo apt-get install php php-curl php-xml libapache2-mod-php php-mysql php-mbstring php-gettext
# Install MySql
sudo apt-get install mysql-server mysql-client
sudo mysql_secure_installation
sudo phpenmod mbstring
sudo systemctl restart apache2
sudo mysql -u root -p
# MySQL CLI
SELECT user,authentication_string,plugin,host FROM mysql.user;
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'yourpass';
FLUSH PRIVILEGES;
exit;
# Install PHPMyAdmin
sudo apt-get install phpmyadmin
sudo nano /etc/apache2/apache2.conf
Then add the following line to the end of the file:
Include /etc/phpmyadmin/apache.conf
/etc/init.d/apache2 restart
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment