LibreLAMP Installation
If you find this content useful, Please Consider A Donation.
Installing LibreLAMP on RHEL/CentOS 7 is rather easy, thanks to the yum package manager.
For installation help with the operating system itself, please refer to the RHEL/CentOS 7 documentation.
If you are looking for a good virtual hosting company, I would highly recommend Linode. I have been their customer since 2008 and they have always always been good to me. Select a CentOS 7 image and you are good to go. This website is hosted on a CentOS 7 Linode.
Enable the EPEL Package Repository
EPEL is a package repository containing quality RPM packages for RHEL/CentOS that do not ship in the base distribution. Some packages in LibreLAMP require packages in EPEL.
First check to see if it is already installed:
rpm -q epel-release
If that package is not installed on CentOS 7 systems, you can install it (as the root
user) with the following command:
yum -y install epel-release
For Red Hat Enterprise Linux, it is a little more complicated. See the EPEL documentation at http://fedoraproject.org/wiki/EPEL.
Optional: The haveged Daemon
Good cryptography depends upon quality random numbers.
Good random generation requires good sources of entropy. The haveged daemon, packaged in the EPEL package repository, increases the entropy of the sources used to generate random numbers in Linux.
To install and enable it:
yum -y install haveged systemctl enable haveged.service systemctl start haveged.service
Once that is done, for all practical purposes you can forget about it. It will start whenever the server boots and just do its thing.
Backup and Stop MariaDB
If you are already running the MariaDB database server, LibreLAMP has a major version update to what ships in CentOS. It is recommended that you back-up all your databases and stop the database server before installing LibreLAMP.
Things will probably be okay if you do not, but it is safer to do so.
Install LibreLAMP
Once the epel-release
package has been installed, you can install the awel-libre-release
package:
curl -O https://librelamp.com/awel-libre-release-7-3.noarch.rpm rpm -ih awel-libre-release-7-3.noarch.rpm yum clean all && yum update
YUM ISSUE NOTE: That use to be all that was required, and if I had the test hardware it probably would be all that is needed, but radical changes in the packaging style of MariaDB from CentOS 7 to what is used in current Fedora and LibreLAMP cause an issue. The issue is related to MariaDB separating out the C-connector into a separate package.
If the yum update
fails, what typically works:
- yum update postfix
- Update the Postfix package by itself. That will remove the dependency on the old
mariadb-libs
package that is causing the problem. - rpm --test -e mariadb-libs
- That will tell you what still remains that requires the
mysql-libs
package. Try to manually update anything it lists. There is a chance anything left that depends uponmariadb-libs
has been updated in LibreLAMP to depend upon the new MariaDB C-Connector package instead. - rpm -e mariadb-libs
- That removes the problematic
mariadb-libs
package. - yum update
- That should now work.
The problem, historically the the MariaDB package included a libs package that had a shared library. MariaDB 10.2 no longer includes that shared library, users are expected to use the MariaDB C Connector package for that API.
The old mariadb-libs
package contained a configuration file that is now part of mariadb-config
called mysql-clients.cnf
and some error message files that are now part of mariadb-common
. The yum
package manager has trouble figuring out that everything that use to be provided still is provided.
Generally speaking, updating Postfix to the LibreLAMP build allows the removal of the old mariadb-libs
package and from there, you can just update without issue.
Individual Component Installation
To install the Apache web server with TLS support:
yum install httpd mod_ssl
Some configuration advice can be found on the Apache TLS Configuration page.
To install the MariaDB database server and client:
yum install mariadb mariadb-server
To install a basic PHP environment with support for MariaDB:
yum install php php-pear php-mysqlnd php-pdo
For a full listing of available PHP packages in LibreLAMP, please see http://awel.domblogger.net/7/libre/x86_64/repoview/letter_p.group.html.
To install the Postfix SMTP server:
yum install postfix
Some configuration advice can be found on the Postfix page.
To install the Dovecot IMAP/POP3 server:
yum install dovecot
Enable Services
To configure your system to start the Apache web server when it boots:
systemctl enable httpd.service
To manually start the Apache web server when it is not running:
systemctl start httpd.service
To configure your system to start the MariaDB database server when it boots:
systemctl enable mariadb.service
To manually start the MariaDB database server when it is not running:
systemctl start mariadb.service
To configure your system to start the Postfix SMTP when it boots:
systemctl enable postfix.service
To manually start the Postfix SMTP when it is not running:
systemctl start postfix.service
To configure your system to start the Dovecot IMAP/POP3 server when it boots:
systemctl enable dovecot.service
To manually start the Dovecot IMAP/POP3 server when it is not running:
systemctl start dovecot.service
If you found this content useful, Please Consider A Donation.