Author: AKN

Postfix Queue Management

Postfix Queue Management

Retry delivery of mail in queue : postqueue -f Flush mail for a domain to primary mail server from Relay server: postqueue -s domain.com Delete all email in queue for a domain: postqueue -p...

Build 32 bit application or libraries on 64 bit machine

Build 32 bit application or libraries on 64 bit machine

In order to configure script to build 32bit library on a 64 bit machine, you would have to pass the following arguments : ./configure –build=i686-pc-linux-gnu "CFLAGS=-m32" "CXXFLAGS=-m32" "LDFLAGS=-m32" Also, If you get an error...

Nagios Bash script to monitor Domain Expiration

Nagios Bash script to monitor Domain Expiration

This little script here, lets you use nagios to monitor domain name expiration and warn you ahead of time. You can also use it to just run some cron jobs, our extract the portion...

Resize Partition with parted

Resize Partition with parted

If you ever wanted to resize a partition to grow unfilled space, you can use parted to grow the partition size. parted /dev/sdx or parted /dev/mmcblk0print Now note the size of the disk and...

Centos / Redhat 7 Switching back to iptables

Centos / Redhat 7 Switching back to iptables

It may be frustrating to learn yet another firewall (firewalld) in Centos or RHEL 7 . Here is how  you can switch back to the favorite IPTABLES. Stop firewalld and disable it to start...

SELinux Tutorial

SELinux Tutorial

Selinux is Security Enhanced Linux. I see that many administrators disable Selinux to ease administration, however it is a good idea to enable SELINUX. View Selinux Status: getenforce Disable SELinux : setenforce 0 Disable...

New Apache : Authz_core:error Client Denied by Server Configuration

New Apache : Authz_core:error Client Denied by Server Configuration

The newer version of apache 2.4.6 that comes with Centos 7, seems to require some additional statement. If you are using htaccess , then you have to add the following keyword in order to...

Postfix – Sender address rejected: User unknown in virtual mailbox table

Postfix – Sender address rejected: User unknown in virtual mailbox table

Sometimes you may want to be able to send  email from non existent email addresses on your own networks for notification purposes, you may get error “Sender address rejected: User unknown in virtual mailbox...

Filtering capture files with wire shark

Filtering capture files with wire shark

Filter by IP address, source and or destination IP Address ip.addr==192.168.1.1 ip.src==192.168.1.1 ip.dst==192.168.1.1 (ip.src==192.168.1.1)||(ip.dst==192.168.1.1) (ip.src==192.168.1.1)&&(ip.dst==192.168.1.1) To Exclude an IP Address : !(ip.addr==192.168.1.1)

Postfix Spam Control

Postfix Spam Control

Reject / Discard / Redirect emails based on header checks : vi /etc/postfix/main.cf header_checks = regexp:/etc/postfix/header_checks vi /etc/postfix/header_checks /^From: "Mechanic/ REJECT /^To: someone@example.com/ REDIRECT someone@example2.com /^To: bademail@example.com/ REJECT /^Subject: .*badWord/ DISCARD Reject By Subnet...