How to enable port 465 (smtps) in postfix mailserver

More and more internet access providers are closing port 25 to reduce spam except for connections to their own mail servers. If you run your own email server and have problems connecting to it on port 25, you can enable port 465 (SMTPS) in postfix as a workaround. Edit the /etc/postfix/master.cf file: nano /etc/postfix/master.cf and ... Read more

How to Install Gradle Build Tool on Debian 11

Gradle is a build automation tool that is based on a concept called ‘incremental builds’. It speeds up the development process by, for example, building only those parts of the project that have been modified. Incremental build works by (conceptually) tracking which files were changed and then using this information to determine what needs to ... Read more

Get the disk health status with SMART monitor tools on Debian and Ubuntu Linux

Disk SMART status

Every current disk includes a built-in monitoring feature known as SMART that keeps track of faults. On Linux, there is a software package called smartmontools that may be used to query the SMART status of the disk to see if it will fail soon. Installation apt-get install smartmontools Usage First we need to know the ... Read more

[SOLVED] The following signatures were invalid: EXPKEYSIG B188E2B695BD4743 DEB.SURY.ORG Automatic Signing Key

Here is the solution if you've got the following error message when updating package lists on Debian (apt-get update): The following signatures were invalid: EXPKEYSIG B188E2B695BD4743 DEB.SURY.ORG Automatic Signing Key The sury.org Debian package repository has changed its package signing key. To fix the error, just download the new key: wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg Finally, ... Read more

How to prevent a Linux system user from logging into the system

The shell setting in /etc/passwd determines whether a Linux system user may log in via the shell or over SSH. If you don't want a certain user to be able to log in, set the shell to /bin/false or /sbin/nologin. For the user "otheruser" on Debian and Ubuntu Linux, here's an example: usermod -s /bin/false ... Read more

Get a list of all virtual hosts which are defined in all apache configuration files

Have you ever looked in the apache config files to see where a website's virtual host is defined? The apache2ctl script has a useful option that could come in good here. When you execute the command, it should look like this: apache2ctl -S You'll obtain a list of all virtual hosts and default servers in ... Read more

How to download and extract a .deb package on Ubuntu or Debian Linux

Download .deb package

Sometimes you require a certain file from a Debian .deb package. For example, because you accidentally deleted a file. Or because the package's installation is faulty and it can't be restored without first adding the missing file. This FAQ explains how to extract the contents of a.deb file downloaded from the Debian or Ubuntu repository. ... Read more