Postfix: “queue file write error”

If you get an error like: Aug 21 12:41:03 webb4 postfix/sendmail[11234]: fatal: web1_user(12967): queue file write error in your mail log, then the vale for message_size_limit in postfix main.cf is too low. Edit postfix main.cf: vi /etc/postfix/main.cf and set the message size limit to a higher value. E.g. message_size_limit = 900000000 and restart postfix: /etc/init.d/postfix ... Read more

Set stricter PHP settings to secure joomla and wordpress installations

If you run a joomla or wordpress installation with mod_php, the following settings in the vhost configuration file or the "Apache directives" field in ISPConfig can be used to set stricter securitypolicys. This helps limit the impact of a possible hack to this websiteand protect the other sites on the server. php_admin_value disable_functions "show_source system ... Read more

Configure fail2ban to use route instead of iptables to block connections

Fail2ban uses iptables by default to block incoming connections when they exceed the max.  login retries. The iptables rules used by fail2ban might conflict with the firewall rules, so it might be necessary to reconfigure fail2ban to use the route command for blocking incoming connections. To reconfigure fail2ban for using the route command instead of ... Read more

Linux: Get detailed information about server hardware and partitions on the shell

To get detailed information on the CPU, use this command: cat /proc/cpuinfo The output will look similar to this: cat /proc/cpuinfo processor       : 0 vendor_id       : AuthenticAMD cpu family      : 15 model           : 107 model name      : AMD Athlon(tm) 64 X2 Dual Core Processor 5600+ stepping        : 2 cpu MHz         : 2900.171 cache size      : ... Read more

Linux: How to view log files on the shell?

Many Linux servers are administered on the commandline e.g. with an SSH connection. In the following article, I will explain several shell commands that make it easy to view logfiles. These commands will work on all major Linux distributions inc. CentOS, Debian, Fedora and Ubuntu. Get the last N lines of a log file The ... Read more

How to renew SSL certificates for courier pop3 and imap server on Debian or Ubuntu?

This articles describes the renewal of SSL certificates for courier pop3 and imap server. This is nescessary e.g. when the certificates are expired or contain the wrong hostname. First delete the exsiting certificates: rm -f /etc/courier/imapd.pem rm -f /etc/courier/pop3d.pem Then edit the template that contains the details for the ecrtificates so that the hostname in ... Read more

How to enable verbose logging in pure-ftpd on Debian Linux

To turn on verbose logging (e.g. to debug FTP connection or authentication problems) in  pure-ftpd FTP server on Debian and Ubuntu Linux, execute the following command as root user in the shell: echo 'yes' > /etc/pure-ftpd/conf/VerboseLog and then restart pure-ftpd, for init based systems: /etc/init.d/pure-ftpd-mysql restart For Servers that use systemd: service pure-ftpd-mysql restart The ... Read more