![]() The last step to have a complete LEMP stack installed on our AlmaLinux 9 system is to install PHP Scripting Language. Finally, to exit the MariaDB shell and return to the system terminal, use the “ quit” command. In response to your query, the MariaDB server should return its version. Run the post-installation security script. Next, we’ll use a script ( mysql_secure_installation) provided by the mariadb-server package to restrict access to the server and remove unused accounts because the default setup makes your MariaDB installation unsafe. Sudo systemctl start mariadb 3.1 Securing MariaDB Server Then let’s enable and start the MariaDB service with the following commands. To install the MariaDB database, run the commands below, and when prompted, confirm installation by typing “Y” and hitting “Enter.” sudo dnf install mariadb-server MariaDB provides improved performance with faster replication speeds, tighter security measures, and additional storage engines compared to MySQL. It is an open-source RDBMS (Relational Database Management System), backward compatible, binary drop-in replacement of MySQL. Instead of MySQL, we’ll be installing MariaDB in this tutorial. Now that you have a working web server, you need to install the database server to store and manage data for your website. It should display the default AlmaLinux 9 Nginx’s welcome page. sudo systemctl status nginxįinally, open a web browser and type the server’s IP address in the address bar. Let’s check now that the Nginx server has been successfully launched. Once the Nginx web server is installed on your AlmaLinux 9 system, please enable it to run at boot time and start the Nginx service. When prompted, enter “Y” to confirm that you want to install it. Use the following commands to install the latest Nginx version on your AlmaLinux 9 server. This step takes care of the second requirement in the LEMP stack, the Nginx web server. The web server enables you to serve content such as web pages to website visitors. If packages are waiting to be updated, I advise applying them before moving on. ![]() In addition, make sure the system is fully updated. This ensures that only the most recent versions of the packages are used throughout the installation of the LEMP stack on our AlmaLinux 9 system and prevent difficulties. Update Software Repositoriesįirst, we will use the DNF command to update the list of available packages. sudo firewall-cmd -permanent -add-service= The result will be the same in both cases.įurthermore, ensure that your firewall does not block port 80 to the server and port 443 if you plan to use SSL. Of course, you can skip the sudo portion of the commands and run them directly as a root user. In addition, all commands shown are run by a regular user with sudo execution permissions. You’ll need access to an AlmaLinux 9 server to complete this guide. So without further ado, let’s get to work. This tutorial shows you how to install the LEMP Stack (Nginx, MariaDB, and PHP) on AlmaLinux 9, transforming it into an ultimate server for developing and hosting your web applications. Because of these qualities, it is a reasonable and often favored choice of system administrators for Linux-based servers. It is an acronym representing four separate components: (L) Linux OS, (E) Nginx Web Server, (M) MySQL/MariaDB Database, and (P) PHP Scripting Language.ĪlmaLinux, one of the most popular Red Hat Enterprise Linux replacements, is a reliable, secure, and stable Linux distribution, ensuring your server’s seamless operations. ![]() The LEMP software stack consists of a group of server-side software that serves dynamic web pages and web applications. ![]() This step-by-step guide walks you through installing and configuring Nginx, MariaDB, and PHP (LEMP Stack) on AlmaLinux 9. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |