RHEL6 server is used to build a Mail server that integrates anti-virus software ClamAV

Source: Internet
Author: User
Tags nslookup
This article combines the previous article RHEL6 server Mail service to deploy ingress #

This article combines the previous "RHEL6 server Mail service" to deploy the http://www.linuxidc.com/Linux/2013-10/91254.htm

1. View DNS domain names
# Nslookup mail.cluster.com
Server: 10.10.10.15
Address: 10.10.10.15 #53
Name: mail.cluster.com
Address: 10.10.10.15
# Nslookup -- verify the email exchange Record
> Set type = mx
> Cluster.com -- write the domain here, not the domain name
Server: 10.10.10.15
Address: 10.10.10.15 #53
Cluster.com mail exchanger = 0 10.10.10.15.

2. Configure main. cf
# Vim/etc/postfix/main. cf
Myhostname = mail.cluster.com
Mydomain = cluster.com
Myorigin = $ mydomain
Inet_interfaces = all --- comment out the original localhost
Mydestination = $ myhostname, localhost. $ mydomain, localhost, $ mydomain
Mynetworks = 127.0.0.0/8, 10.1.1.0/24,172.16 .0.0/16

3. install anti-virus software
(1) Establish an identity user
# Groupadd-g 108 clamav
# Useradd-g clamav-u 108 clamav

(2) Installation and compilation
# Tar xvf clamav-0.97.6.tar.gz-C/usr/src
# Clamav-0.97.6/cd/usr/src/
#./Configure
# Make-j2 & make install

 

4. Configuration
(1) configure the virus database and update the virus Database
# Vim/usr/local/etc/freshclam. conf
# Example --- delete or comment out
DatabaseDirectory/var/lib/clamav
DatabaseOwner clamav --- owner of files related to the virus Database
DatabaseMirror db.cn.clamav.net
DatabaseMirror database.clamav.net
Checks 24
NotifyClamd/usr/local/etc/clamd. conf
# Mkdir-p/var/lib/clamav
# Chown clamav: clamav/var/lib/clamav/

# Tar xvf clamav-db.tar-C/var/lib/clamav/
---- Decompress the virus library of the old version

Upgrade virus library
# Freshclam

(2) configure the main configuration file for anti-virus software
# Vim/usr/local/etc/clamd. conf
# Example
LogFile/tmp/clamd. log
PidFile/var/run/clamd. pid
DatabaseDirectory/var/lib/clamav
LocalSocket/tmp/clamd. socket
User clamav
Copy the startup script to the corresponding directory.
# Cp/usr/local/sbin/clamd/etc/rc. d/init. d/
# Chmod 755/etc/rc. d/init. d/clamd
Start anti-virus software
# Service clamd start
# Ls/tmp/clamd. socket
/Tmp/clamd. socket --- If yes, the startup is successful.

(3) scan viruses and delete virus files
# Clamscan/usr/src/clamav-0.97.6/test/scan only
# Clamscan -- remove = yes/usr/src/clamav-0.97.6/test/delete virus-infected files

Reading:

ClamAV http://www.linuxidc.com/Linux/2013-08/88981.htm, a completely open-source antivirus software

Install Comodo Antivirus software http://www.linuxidc.com/Linux/2012-05/60681.htm in Linux

Build ClamAV AntiVirus http://www.linuxidc.com/Linux/2013-09/90021.htm in Linux

ClamTk: Click here
ClamTk: Click here

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.