

Method 2: Install LAMP Stack In Single Command sudo apt install -y php php-mysql libapache2-mod-php Here, we will install PHP 7.4 on Ubuntu 20.04. To have a PHP support, you would need to install PHP and the PHP extension package for MariaDB/MySQL.
#AWSTATS UBUNTU 20.04 APACHE UPDATE#
Update user set plugin='mysql_native_password' where user='root' īy default Apache server supports serving of static HTML files only, not To disable Unix Socket authentication and enable native password, follow the below steps.

MariaDB uses the Unix Socket authentication mechanism for MariaDB root user, which allows MariaDB root user to log in only from the Unix socket (# prompt or sudo). Reload privilege tables now? Y << Reload tablesĪll done! If you've completed all of the above steps, your MariaDB Reloading the privilege tables will ensure that all changes made so far Remove test database and access to it? Y << Remove test database This is also intended only for testing, and should be removedīefore moving into a production environment. ThisĮnsures that someone cannot guess at the root password from the network.ĭisallow root login remotely? Y << Disable root login remotelyīy default, MariaDB comes with a database named 'test' that anyone canĪccess. Normally, root should only be allowed to connect from 'localhost'. Remove anonymous users? Y << Remove anonymous users You should remove them before moving into a This is intended only for testing, and to make the installation To log into MariaDB without having to have a user account created for Re-enter new password: xxx << Re-Enter MariaDB root passwordīy default, a MariaDB installation has an anonymous user, allowing anyone New password: xxx << Enter New MariaDB root password Set root password? Y << Set MariaDB root password Root user without the proper authorisation. Setting the root password ensures that nobody can log into the MariaDB OK, successfully used password, moving on. You haven't set the root password yet, the password will be blank,Įnter current password for root (enter for none): << Just Press Enter In order to log into MariaDB to secure it, we'll need the current SERVERS IN PRODUCTION USE! PLEASE READ EACH STEP CAREFULLY! NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB Run the mysql_secure_installation command to secure the MySQL installation.
