Install Config Wiki

All about installing, configuring and troubleshooting

User Tools

Site Tools


install_apache_mysql_php_linux_ubuntu_server

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
install_apache_mysql_php_linux_ubuntu_server [2020/06/08 04:22] – [Installing PHP] wikiadmininstall_apache_mysql_php_linux_ubuntu_server [2020/06/08 16:20] – [Creating Additional Virtual Hosts] wikiadmin
Line 54: Line 54:
 </code> </code>
  
-Also (OR INSTEAD) install libapache2-mod-php module to work PHP with Apache2. [Go research this]+Also install libapache2-mod-php module to work PHP with Apache2. 
  
-Enter the following to install it:+Enter the following command to install it:
  
 <code>sudo apt install apache2 libapache2-mod-php7.4</code> <code>sudo apt install apache2 libapache2-mod-php7.4</code>
 +
 +Some help sites also include "php-mysql" module appended to the end of the above command.  I think we can install that later after we install MySQL server.  So keep in mind for later, after MySQL server is installed, the step of entering a command like the following.
 +
 +<code>sudo apt install apache2 php-mysql</code>
 ==== Creating Apache VirtualHost ==== ==== Creating Apache VirtualHost ====
  
Line 145: Line 149:
  
 Repeat the above steps for site www1 by changing the site-name to whatever it will be, such as www2.exmample.com Repeat the above steps for site www1 by changing the site-name to whatever it will be, such as www2.exmample.com
 +
 +===== Install MySQL Database Server =====
 +
 +The apt repositories for Ubuntu 20.04 LTS contain MySQL server version 8.0. 
 +
 +Install mysql-server packages for the MySQL database. Also, install the php-mysql package to use MySQL support using PHP. Use the following command to install it.
 +
 +<code>sudo apt install mysql-server php7.4-mysql</code>
 +
 +The installer will prompt for the root password. This password will work for your MySQL root user. After installing MySQL execute the following command for initial settings of MySQL server. The script will ask more questions for settings than earlier MySQL versions, such as password validation policy etc.
 +
 +Enter this command:
  
  
install_apache_mysql_php_linux_ubuntu_server.txt · Last modified: 2020/06/08 23:20 by wikiadmin