?
Solved

ClamAV

Posted on 2013-06-07
5
Medium Priority
?
2,114 Views
Last Modified: 2013-11-22
Hello,

am not to start the ClamAV service from my Centos Mail server. am getting below error.
can any body help me on this

root@galaxy [/home/plokam]# /etc/init.d/clamd start
Starting Clam AntiVirus Daemon: ERROR: LOCAL: Socket file /var/clamd could not b                                                                                        e bound: Permission denied
ERROR: Can't unlink the socket file /var/clamd
                                                           [FAILED]
0
Comment
Question by:mummuluri
3 Comments
 
LVL 27

Accepted Solution

by:
skullnobrains earned 1000 total points
ID: 39231058
- make sure you start the service as root
- if yes, make sure the clamav user can write to /var but as far as i remember, clamav creates the socket before it drops privileges so this should not be nessessary

if you are performing a new install, you may also move the socket elsewhere : /tmp, /var/run or a dedicated subdirectory in /var
0
 
LVL 30

Assisted Solution

by:Kerem ERSOY
Kerem ERSOY earned 1000 total points
ID: 39231469
Hi,

as you see you get the error message:

root@galaxy [/home/plokam]# /etc/init.d/clamd start
Starting Clam AntiVirus Daemon: ERROR: LOCAL: Socket file /var/clamd could not b                                                                                        e bound: Permission denied
ERROR: Can't unlink the socket file /var/clamd
                                                           [FAILED]

This is because you can not directly write under /var.
- Please create a directory called  /var/clamav
- Change owner to the of the directory to clamav user (either clam or clamav check your clamav config file). I am assuming it to be the user clam:
  chown clam:clam /var/clamav

Open in new window

- Edit your /etc/init.d/clamd file and make sure that it creates the socket under /var/clamav instead of /var. To accomplish this edit your /etc/clamd.conf and find these lines:

# Path to a local socket file the daemon will listen on.
# Default: disabled (must be specified by a user)
# LocalSocket /var/run/clamav/clamd.sock

Open in new window


and modify it to read:

# Path to a local socket file the daemon will listen on.
# Default: disabled (must be specified by a user)
LocalSocket /var/run/clamav/clamd.sock

Open in new window


Save & Exit. This should do the trick. It seems that you've overridden the default config options during the compile using command line switches.

Also please post the output of your sestatus command here if it still does not work.

Cheers,
K.
0
 
LVL 13

Expert Comment

by:Sandy
ID: 39231669
or just check the configuration file, there must be socket/port related mistake in configuration.

Cheers
SA
0

Featured Post

What Security Threats Are We Predicting for 2018?

Cryptocurrency, IoT botnets, MFA, and more! Hackers are already planning their next big attacks for 2018. Learn what you might face, and how to defend against it with our 2018 security predictions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I. Introduction There's an interesting discussion going on now in an Experts Exchange Group — Attachments with no extension (http://www.experts-exchange.com/discussions/210281/Attachments-with-no-extension.html). This reminded me of questions tha…
Encryption for Business Encryption (https://en.wikipedia.org/wiki/Encryption) ensures the safety of our data when sending emails. In most cases, to read an encrypted email you must enter a secret key that will enable you to decrypt the email. T…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…
Suggested Courses

862 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question