How to install WordPress, Linux, Nginx, MariaDB 10.3, PHP 7.3 (LEMP stack) on CentOS 7

LEMP (also known as LNMP) is a group of open-source software which enable a server to host dynamic websites and web applications. It consists of the Linux operating system, the (E)Nginx web server (which replaces the Apache component of a LAMP stack), the MySQL relational database management system, and the PHP programming language.

Continue reading “How to install WordPress, Linux, Nginx, MariaDB 10.3, PHP 7.3 (LEMP stack) on CentOS 7”

How to set up master slave replication in MySQL

MySQL replication is a process that enables data from one MySQL database server (the master) to be copied automatically to one or more MySQL database servers (the slaves). Replication is asynchronous by default. Slaves do not need to be connected permanently to receive updates from the master. Depending on the configuration, you can replicate all databases, selected databases, or even selected tables within a database.

Continue reading “How to set up master slave replication in MySQL”

How to disable Let’s Encrypt for the hostname

If you want to replace the certificate for your hostname with a custom certificate but you had enabled Let’s Encrypt, you will need to disable Let’s Encrypt for the hostname first. The following command let’s DirectAdmin know that it does not need to renew the Let’s Encrypt certificate. This is required as DirectAdmin will renew the certificate +/- 60 days after the last renewal, even when the Let’s Encrypt certificate is not installed.

rm -rf /usr/local/directadmin/data/users/user_name/domains/domain_name.lt.san_config
rm -rf /usr/local/directadmin/data/users/user_name/domains/domain_name.lt.cert.creation_time

Proxmox: Shrinking disk of an LVM backed container

LVM, or Logical Volume Management, is a storage device management technology that gives users the power to pool and abstract the physical layout of component storage devices for easier and flexible administration. Utilizing the device mapper Linux kernel framework, the current iteration, LVM2, can be used to gather existing storage devices into groups and allocate logical units from the combined space as needed.
Continue reading “Proxmox: Shrinking disk of an LVM backed container”

Proxmox VE 5.4 software RAID using MDADM

Proxmox Virtual Environment is an open source server virtualization management solution based on QEMU/KVM and LXC. You can manage virtual machines, containers, highly available clusters, storage and networks with an integrated, easy-to-use web interface or via CLI. Proxmox VE code is licensed under the GNU Affero General Public License, version 3. The project is developed and maintained by Proxmox Server Solutions GmbH.

Continue reading “Proxmox VE 5.4 software RAID using MDADM”

Proxmox VE 5.4 fix updates / upgrades

Proxmox VE 5.4 has been released, this version is based on Debian 9. (Linux Kernel 4.15) It includes allot of new features, but sadly updates are still pointing to the enterprise repository for updates. This results in ugly error message when trying

apt-get update

such as:

root@server2:~# apt-get update
Hit:1 http://security.debian.org stretch/updates InRelease
Ign:2 http://ftp.debian.org/debian stretch InRelease     
Hit:3 http://ftp.debian.org/debian stretch-updates InRelease
Hit:4 http://ftp.debian.org/debian stretch Release 
Ign:5 https://enterprise.proxmox.com/debian/pve stretch InRelease
Ign:6 https://enterprise.proxmox.com/debian/pve stretch Release
Ign:7 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise amd64 Packages
Ign:8 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise all Packages
Ign:10 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise Translation-en
Ign:7 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise amd64 Packages
Ign:8 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise all Packages
Ign:10 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise Translation-en
Ign:7 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise amd64 Packages
Ign:8 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise all Packages
Ign:10 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise Translation-en
Ign:7 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise amd64 Packages
Ign:8 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise all Packages
Ign:10 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise Translation-en
Ign:7 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise amd64 Packages
Ign:8 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise all Packages
Ign:10 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise Translation-en
Err:7 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise amd64 Packages
  401  Unauthorized
Ign:8 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise all Packages
Ign:10 https://enterprise.proxmox.com/debian/pve stretch/pve-enterprise Translation-en
Reading package lists... Done
W: The repository 'https://enterprise.proxmox.com/debian/pve stretch Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Failed to fetch https://enterprise.proxmox.com/debian/pve/dists/stretch/pve-enterprise/binary-amd64/Packages  401  Unauthorized
E: Some index files failed to download. They have been ignored, or old ones used instead.

To fix this, its similar to V3.X and V4.X. We need to add one repository:

nano /etc/apt/sources.list

add:

deb http://download.proxmox.com/debian stretch pve-no-subscription

Then disable or remove

rm -f /etc/apt/sources.list.d/pve-enterprise.list

(for disable add a # in front of the first line starting with deb)

Now you can run those updates take note only

apt-get update

and

apt-get dist-upgrade

are supported by Proxmox!

How to set up software RAID1 on a running LVM system (incl. GRUB2 configuration) (Ubuntu 19.04)

This guide explains how to set up software RAID1 on an already running LVM system (Ubuntu 19.04). The GRUB2 bootloader will be configured in such a way that the system will still be able to boot if one of the hard drives fails (no matter which one).

I do not issue any guarantee that this will work for you!

Continue reading “How to set up software RAID1 on a running LVM system (incl. GRUB2 configuration) (Ubuntu 19.04)”