LAMP is an acronym for Web server software suite. Stands for Linux, Apache, MySQL, PHP. Recently, MariaDB has been used instead of MySQL as a database server.
Consider installing a LAMP server on a VDS running Ubuntu. Usually, when installing the OS from a storage medium, the installation program offers to include the software package in the general installation. Even if this moment was missed, there is always the opportunity to correct it.
We sequentially execute commands to update data on repositories and package indexes, update packages and system components to the latest ones and reboot the server if necessary:
sudo apt-get update
sudo apt-get upgrade
Install server components – Apache2, MariaDB, PHP7.0:
sudo apt-get install apache2
sudo apt-get install mariadb-server mariadb-client
sudo apt-get install php7.0-mysql php7.0-curl php7.0-json php7.0-cgi php7.0 libapache2-mod-php7.0 php7.0-xml
How to install the latest stable version of MariaDB is covered in a separate article.
During the installation of MariaDB, the program will ask you to enter a password for the root user and confirm it. After installation, you should run the command to configure the DBMS security settings:
Before use, the program will require you to enter a password for the root user.
The php7.0 modules installed in the example may not be sufficient and various CMS require extensions to be installed. A complete list of extensions can be obtained with the command:
apt-cache search php7.0-
Their installation is performed according to the template:
sudo apt-get install
In standard settings, the root of the site is located along the path /var/www/html. With any text editor, for example nano, create a php file:
sudo touch info.php
Let’s write one line to the file:
Let’s save the changes and check the work by opening the site in the browser at the ip-address:
The result should look like this.
Important! If the site is not available, check if iptables is enabled and if there is an allow rule for TCP port 80. If the rule does not exist, then add it:
iptables -A INPUT -p tcp --dport 80 -j ACCEPT
Welcome to the world of DomainRooster, where roosters (and hens) rule the roost! We're a one-stop shop for all your entrepreneurial needs, bringing together domain names and website hosting, and all the tools you need to bring your ideas to life. With our help, you'll soar to new heights and hatch great success. Think of us as your trusty sidekick, always there to lend a wing and help you navigate the sometimes-complex world of domain names and web hosting. Our team of roosters are experts in their fields and are always on hand to answer any questions and provide guidance. So why wait? Sign up today and join the ranks of the world's greatest entrepreneurs. With DomainRooster, the sky's the limit! And remember, as the saying goes, "Successful people do what unsuccessful people are not willing to do." So don't be afraid to take that leap of faith - DomainRooster is here to help you reach for the stars. Caw on!