[HowTo] Install Apache, MariaDB (Mysql), PHP (LAMP)

It is not a requirement - you amend the guide to suit your use case.

Just a correction in the section of the MariaDB
The commands:

mariadb-install-db --user=mysql --basedir=/usr --datadir=/var/lib/mysql

mariadb-secure-installation

1 Like

not sure this is correct, but if we’re installing a LAMP stack on Manjaro/Arch, it’s probably for development purposes and not production, therefore in /etc/httpd/conf/httpd.conf it may be wise to change the Listen option…

Listen 127.0.0.1:80

in /etc/webapps/phpmyadmin/config.inc.php, i believe the line $cfg['TempDir'] = '/tmp'; is supposed to go in the ‘Directories for saving/loading files from server’ section

lastly, this was very helpful as already mentioned by @Krassimir

$ sudo chown YOURUSERNAME:http -R /srv/http/
$ sudo find /srv/http/ -type d -exec chmod 755 {} +
$ sudo find /srv/http/ -type f -exec chmod 644 {} +

Thank you so much! Excellent guide and very beginner friendly. Very new to both Manjaro and PHP and this relieved at least 2 days of brain ache!

1 Like

Stuck on Test Web Server:

I followed everything to a T until it says to enter into search engine:

http://ip.x.y.z

I get an error message instead of:

“It Works!”

prior to that, I did receive a message at the end of

systemctl status httpd

it says:

httpd[68586]: AH00558: httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message

I followed the ServerName direction properly and even went back to check. I tried with and without the hashtag. Same for the load direction.

This article is accurate, perfect and on point. thanksa lot.

1 Like

no nonsense, short and precise, thank you!