Block an IP address in firewall-cmd

Sometimes you need to block an IP address (or a range of IP addresses) from accessing your machine. In this case firewall-cmd can help you through these commands: And finally, if you decide to remove this rule, you can use these commands:

Setup High Availability for HAProxy


To prevent service failure during disasters like server crash or so on, we have to find Single Point of Failure components and setup High Availability solutions for them. In this article I am going to define how to setup High Availability for HAProxy service. The structure of service would be something like below: In this […]

sudo without password


Typing password for sudo commands is an awful experience. So here’s what we should do to stop linux asking for password: 1. Backup the sudoers file: 2. Open the sudoers file for edit: 3. Edit sudoers file:

How to make Apache HTTPD Web Server more secure


There are some known security issues that can make an Apache HTTPD Web Server insecure. If using Apache HTTPD as a web service is your approach, then you should scan your web server in first step. There are many tools to scan a web server. here we will use NIKTO. Nikto is a free tool […]

Connection Encryption in Oracle Database

To encrypt connections between client and database server you have to set some parameters in sqlnet.ora file ($ORACLE_HOME/network/admin/sqlnet.ora) of server and client (you have to install oracle client on the client): server side: client side: the ENCRYPTION_CLIENT parameter can have one of these values: ACCEPTED : The client or server will allow both encrypted and […]

Add New Disk to RedHat-based Linux without reboot

If you add a new disk to your OS, you won’t find this device in the device list (fdisk -l command). So you have two options to make it available: Reboot your machine Make the OS rescan all connected devices In operational environments, the first option is not considerable. So we have to choose the […]