05 de maio de 20202 min
Instalando LAMP no Manjaro
Tutorial básico
Update
Check if your system has updates available before run the commands.
sudo pacman -SyyuInstall
Apache
sudo pacman -S apacheMysql
sudo pacman -S mysqlPHP
sudo pacman -S php php-apachephpmyadmin
sudo pacman -S phpmyadminAll
sudo pacman -S apache mysql php php-apache phpmyadminConfig
Apache
sudo nano /etc/httpd/conf/httpd.conf Comment this line
#LoadModule unique_id_module modules/mod_unique_id.soEnable and restart
sudo systemctl enable httpd
sudo systemctl restart httpd
sudo systemctl status httpdCheck if status is active (running)
● httpd.service - Apache Web Server
Loaded: loaded (/usr/lib/systemd/system/httpd.service; enabled; vendor preset: disabled)
Active: active (running) MySQL
initialize the MariaDB
sudo mariadb-install-db --user=mysql --basedir=/usr --datadir=/var/lib/mysqlAfter enable and start
sudo systemctl enable mysqld
sudo systemctl start mysqld
sudo systemctl status mysqld Check if status is active (running)
● mariadb.service - MariaDB 10.4.12 database server
Loaded: loaded (/usr/lib/systemd/system/mariadb.service; enabled; vendor preset: disabled)
Active: active (running)PHP
sudo nano /etc/httpd/conf/httpd.confComment this line
#LoadModule mpm_event_module modules/mod_mpm_event.soRemove the comment from this line
LoadModule mpm_prefork_module modules/mod_mpm_prefork.so Add this lines at the bottom
LoadModule php7_module modules/libphp7.so
AddHandler php7-script php
Include conf/extra/php7_module.confCreate the test file
sudo nano /srv/http/test.php<?php
phpinfo();
?>Restart httpd
sudo systemctl restart httpdphpmyadmin
...