Cài đặt ClamAV Ubuntu


2

Tôi đang cố gắng cài đặt ClamAV trong ubfox theo hướng dẫn trong:

Trong khi cập nhật cơ sở dữ liệu virus bằng cách sử dụng

 sudo freshclam -v

Tôi đang nhận được

Thư mục làm việc hiện tại là / usr / local / share / clamav

Max retries == 3

ClamAV update process started at Mon Apr 11 13:10:34 2016

Using IPv6 aware code

Retrieving database.clamav.net/main.cvd

nonblock_connect: connect timing out (30 secs)

Can't connect to port 80 of host database.clamav.net (IP: 219.94.128.99)

Ignoring mirror 219.94.128.99 (due to previous errors)

Trying host database.clamav.net (27.96.54.66)...

nonblock_connect: connect timing out (30 secs)

Can't connect to port 80 of host database.clamav.net (IP: 27.96.54.66)

Trying host database.clamav.net (203.178.137.175)...

nonblock_connect: connect timing out (30 secs)

Can't connect to port 80 of host database.clamav.net (IP: 203.178.137.175)

Trying host database.clamav.net (211.239.150.206)...

nonblock_connect: connect timing out (30 secs)

Can't connect to port 80 of host database.clamav.net (IP: 211.239.150.206)

Trying host database.clamav.net (120.29.176.126)...

nonblock_connect: connect timing out (30 secs)

Can't connect to port 80 of host database.clamav.net (IP: 120.29.176.126)

WARNING: Can't download main.cvd from database.clamav.net

Trying again in 5 secs...

ClamAV update process started at Mon Apr 11 13:13:09 2016

Using IPv6 aware code

Retrieving database.clamav.net/main.cvd

Ignoring mirror 120.29.176.126 (due to previous errors)

Ignoring mirror 211.239.150.206 (due to previous errors)

Ignoring mirror 27.96.54.66 (due to previous errors)

Ignoring mirror 203.178.137.175 (due to previous errors)

Ignoring mirror 219.94.128.99 (due to previous errors)

WARNING: Can't download main.cvd from database.clamav.net

Trying again in 5 secs...

ClamAV update process started at Mon Apr 11 13:13:15 2016

Using IPv6 aware code

Retrieving database.clamav.net/main.cvd

Ignoring mirror 27.96.54.66 (due to previous errors)

Ignoring mirror 211.239.150.206 (due to previous errors)

Ignoring mirror 120.29.176.126 (due to previous errors)

Ignoring mirror 219.94.128.99 (due to previous errors)

Ignoring mirror 203.178.137.175 (due to previous errors)

ERROR: Can't download main.cvd from database.clamav.net

Giving up on database.clamav.net...

Update failed. Your network may be down or none of the mirrors listed in  /usr/local/etc/freshclam.conf is working. Check http://www.clamav.net/doc/mirrors-faq.html for possible reasons.

Tại sao nó như vậy?? Có cách nào khác để giải quyết nó không ??

Tôi không muốn ClamTK.

Kết quả của tập tin Mirror.dat là

Mirror #1
IP: 120.29.176.126
Successes: 0
Failures: 1
Last access: Mon Apr 11 12:37:04 2016
Ignore: Yes
-------------------------------------
>Mirror #2
IP: 203.178.137.175
Successes: 0
Failures: 1
Last access: Mon Apr 11 12:37:04 2016
Ignore: Yes
-------------------------------------
Mirror #3
IP: 27.96.54.66
Successes: 0
Failures: 1
Last access: Mon Apr 11 12:37:04 2016
Ignore: Yes
-------------------------------------
Mirror #4
IP: 211.239.150.206
Successes: 0
Failures: 1
Last access: Mon Apr 11 12:37:04 2016
Ignore: Yes
-------------------------------------
Mirror #5
IP: 219.94.128.99
Successes: 0
Failures: 1
Last access: Mon Apr 11 12:37:04 2016
Ignore: Yes

Nội dung của tệp Freshclam.conf là,

##
## Example config file for freshclam
## Please read the freshclam.conf(5) manual before editing this file.
##


# Comment or remove the line below.
#Example

# Path to the database directory.
# WARNING: It must match clamd.conf's directive!
# Default: hardcoded (depends on installation options)
#DatabaseDirectory /var/lib/clamav

# Path to the log file (make sure it has proper permissions)
# Default: disabled
#UpdateLogFile /var/log/freshclam.log

# Maximum size of the log file.
# Value of 0 disables the limit.
# You may use 'M' or 'm' for megabytes (1M = 1m = 1048576 bytes)
# and 'K' or 'k' for kilobytes (1K = 1k = 1024 bytes).
# in bytes just don't use modifiers. If LogFileMaxSize is enabled,
# log rotation (the LogRotate option) will always be enabled.
# Default: 1M
#LogFileMaxSize 2M

# Log time with each message.
# Default: no
#LogTime yes

# Enable verbose logging.
# Default: no
#LogVerbose yes

# Use system logger (can work together with UpdateLogFile).
# Default: no
#LogSyslog yes

# Specify the type of syslog messages - please refer to 'man syslog'
# for facility names.
# Default: LOG_LOCAL6
#LogFacility LOG_MAIL

# Enable log rotation. Always enabled when LogFileMaxSize is enabled.
# Default: no
#LogRotate yes

# This option allows you to save the process identifier of the daemon
# Default: disabled
#PidFile /var/run/freshclam.pid

# By default when started freshclam drops privileges and switches to the
# "clamav" user. This directive allows you to change the database owner.
# Default: clamav (may depend on installation options)
#DatabaseOwner clamav

# Initialize supplementary group access (freshclam must be started by root).
# Default: no
#AllowSupplementaryGroups yes

# Use DNS to verify virus database version. Freshclam uses DNS TXT records
# to verify database and software versions. With this directive you can change
# the database verification domain.
# WARNING: Do not touch it unless you're configuring freshclam to use your
# own database verification domain.
# Default: current.cvd.clamav.net
#DNSDatabaseInfo current.cvd.clamav.net

# Uncomment the following line and replace XY with your country
# code. See www.iana.org/cctld/cctld-whois.htm for the full list.
# You can use db.XY.ipv6.clamav.net for IPv6 connections.
#DatabaseMirror db.XY.clamav.net

# database.clamav.net is a round-robin record which points to our most 
# reliable mirrors. It's used as a fall back in case db.XY.clamav.net is 
# not working. DO NOT TOUCH the following line unless you know what you
# are doing.
DatabaseMirror database.clamav.net

# How many attempts to make before giving up.
# Default: 3 (per mirror)
#MaxAttempts 5

# With this option you can control scripted updates. It's highly recommended
# to keep it enabled.
# Default: yes
#ScriptedUpdates yes

# By default freshclam will keep the local databases (.cld) uncompressed to
# make their handling faster. With this option you can enable the compression;
# the change will take effect with the next database update.
# Default: no
#CompressLocalDatabase no

# With this option you can provide custom sources for
# database files. This option can be used multiple times.
# Default: no custom URLs
#DatabaseCustomURL myserver.com/mysigs.ndb
#DatabaseCustomURL mnt/nfs/local.hdb

# This option allows you to easily point freshclam to private mirrors.
# If PrivateMirror is set, freshclam does not attempt to use DNS
# to determine whether its databases are out-of-date, instead it will
# use the If-Modified-Since request or directly check the headers of the
# remote database files. For each database, freshclam first attempts
# to download the CLD file. If that fails, it tries to download the
# CVD file. This option overrides DatabaseMirror, DNSDatabaseInfo
# and ScriptedUpdates. It can be used multiple times to provide
# fall-back mirrors.
# Default: disabled
#PrivateMirror mirror1.mynetwork.com
#PrivateMirror mirror2.mynetwork.com

# Number of database checks per day.
# Default: 12 (every two hours)
#Checks 24

# Proxy settings
# Default: disabled
#HTTPProxyServer myproxy.com
#HTTPProxyPort 1234
#HTTPProxyUsername myusername
#HTTPProxyPassword mypass

# If your servers are behind a firewall/proxy which applies User-Agent
# filtering you can use this option to force the use of a different
# User-Agent header.
# Default: clamav/version_number
#HTTPUserAgent SomeUserAgentIdString

# Use aaa.bbb.ccc.ddd as client address for downloading databases. Useful for
# multi-homed systems.
# Default: Use OS'es default outgoing IP address.
#LocalIPAddress aaa.bbb.ccc.ddd

# Send the RELOAD command to clamd.
# Default: no
#NotifyClamd /path/to/clamd.conf

# Run command after successful database update.
# Default: disabled
#OnUpdateExecute command

# Run command when database update process fails.
# Default: disabled
#OnErrorExecute command

# Run command when freshclam reports outdated version.
# In the command string %v will be replaced by the new version number.
# Default: disabled
#OnOutdatedExecute command

# Don't fork into background.
# Default: no
#Foreground yes

# Enable debug messages in libclamav.
# Default: no
#Debug yes

# Timeout in seconds when connecting to database server.
# Default: 30
#ConnectTimeout 60

# Timeout in seconds when reading from database server.
# Default: 30
#ReceiveTimeout 60

# With this option enabled, freshclam will attempt to load new
# databases into memory to make sure they are properly handled
# by libclamav before replacing the old ones.
# Default: yes
#TestDatabases yes

# When enabled freshclam will submit statistics to the ClamAV Project about
# the latest virus detections in your environment. The ClamAV maintainers
# will then use this data to determine what types of malware are the most
# detected in the field and in what geographic area they are.
# Freshclam will connect to clamd in order to get recent statistics.
# Default: no
#SubmitDetectionStats /path/to/clamd.conf

# Country of origin of malware/detection statistics (for statistical
# purposes only). The statistics collector at ClamAV.net will look up
# your IP address to determine the geographical origin of the malware
# reported by your installation. If this installation is mainly used to
# scan data which comes from a different location, please enable this
# option and enter a two-letter code (see www.iana.org/domains/root/db/)
# of the country of origin.
# Default: disabled
#DetectionStatsCountry country-code

# This option enables support for our "Personal Statistics" service. 
# When this option is enabled, the information on malware detected by
# your clamd installation is made available to you through our website.
# To get your HostID, log on http://www.stats.clamav.net and add a new
# host to your host list. Once you have the HostID, uncomment this option
# and paste the HostID here. As soon as your freshclam starts submitting
# information to our stats collecting service, you will be able to view
# the statistics of this clamd installation by logging into
# www.stats.clamav.net with the same credentials you used to
# generate the HostID. For more information refer to:
# www.clamav.net/documentation.html#cctts 
# This feature requires SubmitDetectionStats to be enabled.
# Default: disabled
#DetectionStatsHostID unique-id

# This option enables support for Google Safe Browsing. When activated for
# the first time, freshclam will download a new database file (safebrowsing.cvd)
# which will be automatically loaded by clamd and clamscan during the next
# reload, provided that the heuristic phishing detection is turned on. This
# database includes information about websites that may be phishing sites or
# possible sources of malware. When using this option, it's mandatory to run
# freshclam at least every 30 minutes.
# Freshclam uses the ClamAV's mirror infrastructure to distribute the
# database and its updates but all the contents are provided under Google's
# terms of use. See www.google.com/transparencyreport/safebrowsing
# and www.clamav.net/documentation.html#safebrowsing 
# for more information.
# Default: disabled
#SafeBrowsing yes

# This option enables downloading of bytecode.cvd, which includes additional
# detection mechanisms and improvements to the ClamAV engine.
# Default: enabled
#Bytecode yes

# Download an additional 3rd party signature database distributed through
# the ClamAV mirrors. 
# This option can be used multiple times.
#ExtraDatabase dbname1
#ExtraDatabase dbname2

Hơn nữa, nếu cố gắng chạy lệnh

/usr/local/bin/freshclam --quiet -l         /var/log/clamav/freshclam.log 

nó đang hiển thị

ERROR: Can't download main.cvd from database.clamav.net

Từ nhật ký của bạn, nó cho thấy clamav đang cố gắng nhận các bản cập nhật từ các máy chủ gần nhất khi một lỗi không thành công. Hãy thử vài lần sau một lúc và xem nó cập nhật.
bhordupur

tôi đang cố gắng hơn 2 ngày
Vanns

bạn đã kiểm tra freshclam.conftập tin chưa? Bạn có thể đặt đầu ra của tập tin?
bhordupur

cũng đặt đầu ra từ /usr/local/share/clamav/mirrors.dattệp
bhordupur

cập nhật các bài với freshclam.conf và mirrors.dat file
Vanns

Câu trả lời:


3
  1. Trong freshclam.conftập tin tìm dòng

    #DatabaseMirror db.XY.clamav.net
    

    và không chú ý đến nó.

    • cho IPv4:

      DatabaseMirror db.us.clamav.net
      
    • cho IPv6 thêm dòng này vào tập tin conf của bạn

      DatabaseMirror db.us.ipv6.clamav.net
      

    Thay thế XYbằng mã quốc gia của bạn, chẳng hạn nhưfi|in|us|jp

  2. Lưu tệp và chạy từ thiết bị đầu cuối

    sudo freshclam -v
    

Bây giờ bạn sẽ có thể thực hiện cập nhật lên cơ sở dữ liệu Freshclam.


bạn có thể giúp với daemon đó không?
Vanns

cho tôi biết thêm ở đây?
bhordupur

Tôi đang nhận được "LRI: Không thể tra cứu: Tên dịch vụ không được hỗ trợ cho ai_socktype" khi tôi sử dụng lệnh "sudo clamdscan -v" tôi đã đề cập đến " askubfox.com/questions/561842/error-starting-clamav-daemon " nhưng vẫn không hy vọng
Vanns

Bạn đã thử giải pháp được đề xuất từ ​​câu hỏi đó?
bhordupur

ya tôi đã thử cả ba giải pháp
Vanns

0

Hãy thử cài đặt bằng công cụ apt-get;

apt-get update # apt-get install clamav

liên kết: https://www.clamav.net/document/installing-clamav#debian


Nhưng tôi muốn cài đặt từ nguồn. Thậm chí nếu tôi cài đặt qua apt-get, khi tôi chạy freshclam lệnh sudo -vi đang nhận được cùng một vấn đề
Vanns

1
Đọc lỗi Mirror, bạn nhận được Câu hỏi thường gặp khuyên bạn nên dừng trình nền Freshclam sau đó xóa cả Mirror.dat và Daily.cvd. Sau đó khởi động lại daemon Freshclam và nó sẽ tải xuống lại hàng ngày. Câu hỏi thường gặp LINK
esefarm

Tôi đã dừng lại với Freshclam bằng cách sử dụng "sudo /etc/init.d/clamav-freshclam stop". Sau đó, chỉ có Mirror.dat ở dưới "/ usr / local / share / clamav /". Tôi đã loại bỏ điều đó. Sau đó bắt đầu Freshclam bằng cách sử dụng "sudo /etc/init.d/clamav-freshclam start". Sau này nếu tôi chạy "sudo Freshclam -v" thì nó cũng đang hiển thị cùng một vấn đề
Vanns
Khi sử dụng trang web của chúng tôi, bạn xác nhận rằng bạn đã đọc và hiểu Chính sách cookieChính sách bảo mật của chúng tôi.
Licensed under cc by-sa 3.0 with attribution required.