If you want to suspend all cPanel accounts at once just use this command: for username in `cat /etc/userdomains | awk {‘print $2’} | grep -v nobody | sort -n | uniq`;do /scripts/suspendacct $username;done Simple as that!
Category: Command Line
Command Line
How to prevent SSH from disconnecting sessions
Introduction If you work with SSH, you already know that, after few minutes of inactivity, a session would be closed automatically, for security reasons. In fact, you could have forgotten to shut it down, and someone could take control of your system. But, if you think it’s not your problem, you can change this behavior […]
Can I delete files in /var/log/journal?
In the directory /var/log/journal/ are kept the log files created by the journal service (systemd). Sometimes, this directory can have a large size. You can check with the du command or by using the journalctl –disk-usage command as: root@web [~]# journalctl –disk-usage Archived and active journals take up 934.1M on disk. root@web [~]# journalctl is a utility that […]
How to completely remove Dovecot from a Directadmin server
It is possible to use DirectAdmin without installing and using POP3/IMAP servers. It’s Dovecot which adds support of POP3/IMAP on a DirectAdmin server. And here you can learn how to completely remove Dovecot from a DirectAdmin powered server.
How to generate and check strong passwords in Linux
Introduction Different operations require different security layers. Accessing your email account, your social media, your bank account, and a remote server that you administer through SSH all need different security layers, and contain data which hold different “weight”. But, in order to accessing all these operations, you will always require the same thing: a password.
Let’s Encrypt: Secure Apache Web Server on Ubuntu 16.04
Why HTTPS? Starting with Chrome 56, the browser developed by Google marks non-secure pages containing password and credit card input fields as Not Secure in the URL bar. It was almost one year ago, when the Mountain View giant announced this choice.
How To Install OpenVPN On CentOS 7
Prerequisites CentOS 7 server. root access to the server. Domain or sub-domain that resolves to your server that you can use for the certificates OpenVpn isn’t available in the default CentOS repositories. So we need to install Enterprise Linux (EPEL) repository. Use the following command to install EPEL repository.
How To Use morgan in Your Express Project
Introduction morgan is a Node.js and Express middleware to log HTTP requests and errors, and simplifies the process. In Node.js and Express, middleware is a function that has access to the:
Script to fetch and show your GNU/Linux distro age in days
I’d like to share a quick and dirty script written in BASH which is supposed to fetch and show the age of your GNU/Linux distribution in days. I created it just for fun as I thought it would be nice to get this information from somewhere and place it for example in your conky, […]
How to install and setup OpenVPN in ArchLinux
In this tutorial we will show you how to install and setup OpenVPN in ArchLinux. While OpenVPN support user/pass, pre-shared key (PSK), SSL Certificates etc. to authenticate users/clients, I’m rolling with SSL Certificates as they are superior to other authentication methods.