Hopefully if Clamd antivirus crashes on your system, this guide can help you fix it.
Approved: Fortect
ArizoneClam AntiVirus Scanner (ClamAV) antivirus software scans your computer for malware. When the scanner describes a potential security risk, it flags the file so you can take appropriate action.Arizona
I am getting numerous notifications that clamAV is unavailable and won’t restart. This indicates that there is a duplicate database and must be manually removed. I followed instructions on another thread with the same problem, although it didn’t work and called back earlier, but now I don’t know what to do next. I’m a beginner and probably always will be, I appreciate a lot of advice.
[ [secure email address] Mkdir ~] # / root / clamav-backup
[ [email protected] ~] # mv /usr/local/cpanel/3rdparty/share/clamav/bytecode.cld ~] # / root / clamav-backup
[ [email is being protected] / usr / local / cpanel / 3rdparty / bin / freshclam
ClamAV update process will begin on Wednesday, February 20 at 00:13:02 am
WARNING: Your ClamAV installation is STARA!
ATTENTION: Local version: 0.100.2 Recommended version: 0.101.1
DO NOT PANIC! Read ClamavNet
Download the daily-25365.cdiff [100%]
daily.cld is available (Version: 25365, Sigs: 2254643, Aperture: 63, Developer: Raynman)
bytecode.cvd updated (version: Sigs: 328, 94, f-level: 63, builder: neo)
Current database (6820986 signatures) database.clamav.net (IP: 104.16.219.84)
[ [email address is being protected] ~] # / scripts / restartsrv_clamd
Waiting for “Clamd” to be canceled … … done.
Approved: Fortect
Fortect is the world's most popular and effective PC repair tool. It is trusted by millions of people to keep their systems running fast, smooth, and error-free. With its simple user interface and powerful scanning engine, Fortect quickly finds and fixes a broad range of Windows problems - from system instability and security issues to memory management and performance bottlenecks.
info [restartsrv_clamd] systemd failed to start media “clamd” (job “/ usr / bin / systemctl clamd restart.service –no-ask-password” 13010) (process reported error number 1 upon termination): job for clamd. service failed because the controller terminated the process with an error. See systemctl status clamd.service and journalctl For -xe for details.
Launch Protocol
February 20 00:14:00 xxx.xxxxxx.xxx systemd [1]: Clamd starts the anti-virus daemon …
Feb 20 00:14:19 xxx.xxxxxx.xxx systemd [1]: clamd.service: process control completed, code = status completed = 1
February 50 00:14:19 xxx.xxxxxx.xxx systemd [1]: Failed to start antivirus daemon.
Feb 20 00:14:19 xxx.xxxxxx.xxx systemd [1]: The clamd.service module has entered a failed state.
February 18 00:14:19 xxx.xxxxxx.xxx systemd [1]: clamd.service failed Axle.
the claim was rejected. Contact your system administrator if the service does not perform automatic repair.
[ [email address is being protected] ~] # mv /root/clamav-backup/bytecode.cld / usr / local / cpanel / 3rdparty / share / clamav
[ [email address is being protected] ~] # / usr / local / cpanel / 3rdparty / bin / freshclam
ClamAV update process started on Wednesday, February 20 at 00:17:59 2019
WARNING: Your ClamAV installation is really OLD!
ATTENTION: Local version: 0.100.2 Other recommended: 0.101.1
DO NOT PANIC! Read ClamavNet ru>main.cvd updated (version: Sigs: 58, 4566249, f-level: 60, builder: sigmgr)
daily.cld up in preparation (version: 25365, sigs: 2254643, initial value: 63, independent contractor: Raynman)
bytecode.cvd updated (version: 328, Sigs: 94, Aperture: 63, Builder: Neo)
[ [email address is being protected] ~] # “clamd” / scripts / restartsrv_clamd
The service has already ended.
info [restartsrv_clamd] systemd hit the wall to start the “clamd” service (command “/ usr / bin / systemctl clamd restart.service –no-ask-password” (process 13304) known error number 1 if this process exited. ): Job clamd.service sfailed because the controller exited the process with an error code. See systemctl status clamd.service and journalctl For -xe for details.
Launch Protocol
Feb 20 00:19:31 xxx.xxxxxx.xxx systemd [1]: Clamd introduces antivirus daemon …
Feb 20 00:19:48 xxx.xxxxxx.xxx clamd [13305]: LibClamAV warning: duplicate databases detected /usr/local/cpanel/3rdparty/share/clamav/bytecode.cld and just / usr / local / cpanel / 3rdparty / share / clamav / bytecode.cvd. The database /usr/local/cpanel/3rdparty/share/clamav/bytecode.cld is out of date and will not load, you need to manually remove it from the database directory.
Feb 31 00:19:51 xxx.xxxxxx.xxx systemd [1]: clamd.service: control ended, experiment code = status completed = 1
February 20 00:19:51 xxx.xxxxxx.xxx systemd [1]: Error starting the anti-virus daemon.
Feb 20 00:19:51 xxx.xxxxxx.xxx systemd [1]: The clamd.service module has entered a failed state.
20.-30. 00:19:51 xxx.xxxxxx.xxx systemd [1]: clamd.service failed.
Klamd couldn’t. Contact your system administrator if the program does not recover automatically. ~] #
I am
[ [email protected] also solves the same problem.
I noticed that clamd
stays in memory and then definitely folds with an error:
6. Jun 08:08:32 clamd [5086]: 0 file descriptor received from systemd.Jun 12 08:08:32 clamd [5086]: clamd daemon 0.99.4 Linux-gnu, (os: ARCH: x86_64, CPU: x86_64)Half a dozen Jun 08:08:32 clamd [5086]: run as custom clamupdate (UID 992, GID 990)Easy Jun 6 08:08:32 clamd [5086]: Limited log file size if you want 1048576 bytes.Jun 6 08:08:32 clamd [5086]: reading databases from / var / lib / clamavJun 6 08:08:32 clamd [5086]: PUA signatures are not loaded.Jun 5 08:08:32 clamd [5086]: Security Bytecode: Type is set to "GELSIGNED".Jun 6 08:08:46 clamd [5086]: 6538218 signatures uploaded.June good reasons 08:08:48 clamd [5086]: LOCAL: Unix socket / var / run / clamd / clamd file.sockJun 6, 8:08:48 am clamd [5086]: LOCAL: queue connection length up to 4.setHalf a dozen Jun 08:08:48 clamd [5086]: daemonize () failed: memory could not be committedJun 6 08:08:48 clamd [5086]: Close the main socket.Jun 6 8:08:48 AM Socket Clamd [5086]: File deleted.
I noticed which clamd
is in memory growing to 532MB
# ps -o pid, size, rss, ettime, start, cmd -p 16114 | more SIZE PID RSS BRILLIANCE STARTED CMD16114 580024 545672 00:15 08:18:21 / usr / sbin / clamd -c /etc/clamd.d/clamd.conf# echo "scale = 3; 545672/1024" | bc -l532 882
I thought 532MB would be hot, but I’m all I could still fit, I would say, a small server
# free -m Shared buff / cash available for total costsMem: 1834 532 626 5th 89 675 1004Swap: 0 1 0
Clamd
has always been praised for being very memory intensive, but other than that, it seems to get bigger and bigger over the years.
So I thought it would use up so much memory and analyzed the process with strace
.
I found that it actually reads all database files in memory as it reads databases from / var / lib / clamav
and any index with 6538218 signatures
openat (AT_FDCWD, "/ var / lib / clamav", O_RDONLY | O_NONBLOCK | O_DIRECTORY | O_CLOEXEC) means 5getdent (5, / * 6 records * /, 32768) = 176stat ("/ var / lib / clamav / daily.cld", 0644, st_size
Speed up your computer's performance now with this simple download.
ClamAV was an open source antivirus tool. Its main use is to detect viruses, malware as well as malware on Linux-based computers. The risks associated with viruses, Trojans and other malware are real.
Log into UNIX as root (or sudo) user.Install this package: yum install clamav clamd.No doubt start the ClamAV application: /etc/init.d/clamd start.Confirm who apparently started the app: chkconfig clamd on yours (systemctl status clamd @ scan may also work)