Ive had this in the past and manually downloading the latest .cvd from https://database.clamav.net/daily.cvd, importing and then running
Code: Select all
freshclam -u admin -v
Code: Select all
freshclam -u admin -v
I read that a tested model is the TS-220, but does it have enough RAM to properly run a scan at this point?MoRiSoVa wrote: ↑Wed Oct 06, 2021 4:46 pm The script is now available on github.
If you find any bugs, please let me know.
https://github.com/MoRiSoVaXZ/CVD_Update
Currently working on countermeasures.MatthewFIU wrote: ↑Sat Oct 09, 2021 7:45 amI read that a tested model is the TS-220, but does it have enough RAM to properly run a scan at this point?MoRiSoVa wrote: ↑Wed Oct 06, 2021 4:46 pm The script is now available on github.
If you find any bugs, please let me know.
https://github.com/MoRiSoVaXZ/CVD_Update
Code: Select all
[~/CVD_Update] # ./CVD_Update.sh
2021-10-10 21:30:35 cvdupdate-1.0.2 INFO Downloaded daily-26296.cdiff
2021-10-10 21:30:35 cvdupdate-1.0.2 INFO Downloaded daily-26297.cdiff
2021-10-10 21:30:35 cvdupdate-1.0.2 INFO Downloaded daily-26298.cdiff
2021-10-10 21:30:36 cvdupdate-1.0.2 INFO Downloaded daily-26299.cdiff
2021-10-10 21:30:36 cvdupdate-1.0.2 INFO Downloaded daily-26300.cdiff
2021-10-10 21:30:36 cvdupdate-1.0.2 INFO Downloaded daily-26301.cdiff
2021-10-10 21:30:36 cvdupdate-1.0.2 INFO Downloaded daily-26302.cdiff
2021-10-10 21:30:37 cvdupdate-1.0.2 INFO Downloaded daily-26303.cdiff
2021-10-10 21:30:37 cvdupdate-1.0.2 INFO Downloaded daily-26304.cdiff
2021-10-10 21:30:37 cvdupdate-1.0.2 INFO Downloaded daily-26305.cdiff
2021-10-10 21:30:38 cvdupdate-1.0.2 INFO Downloaded daily-26306.cdiff
2021-10-10 21:30:38 cvdupdate-1.0.2 INFO Downloaded daily-26307.cdiff
2021-10-10 21:30:38 cvdupdate-1.0.2 INFO Downloaded daily-26308.cdiff
2021-10-10 21:30:39 cvdupdate-1.0.2 INFO Downloaded daily-26309.cdiff
2021-10-10 21:30:39 cvdupdate-1.0.2 INFO Downloaded daily-26310.cdiff
2021-10-10 21:30:39 cvdupdate-1.0.2 INFO Downloaded daily-26311.cdiff
2021-10-10 21:30:39 cvdupdate-1.0.2 INFO Downloaded daily-26312.cdiff
2021-10-10 21:30:40 cvdupdate-1.0.2 INFO Downloaded daily-26313.cdiff
2021-10-10 21:30:40 cvdupdate-1.0.2 INFO Downloaded daily-26314.cdiff
2021-10-10 21:30:40 cvdupdate-1.0.2 INFO Downloaded daily-26315.cdiff
2021-10-10 21:30:40 cvdupdate-1.0.2 INFO Downloaded daily-26316.cdiff
2021-10-10 21:30:41 cvdupdate-1.0.2 INFO Downloaded daily-26317.cdiff
2021-10-10 21:30:41 cvdupdate-1.0.2 INFO Downloaded daily-26318.cdiff
2021-10-10 21:30:51 cvdupdate-1.0.2 INFO Downloaded daily.cvd. Version: 26318
rsync: writefd_unbuffered failed to write 4092 bytes to socket [sender]: Broken pipe (32)
rsync: write failed on "/share/ClamAV/cvd/daily.cld": No space left on device (28)
rsync error: error in file IO (code 11) at receiver.c(302) [receiver=3.0.7]
rsync: connection unexpectedly closed (506 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(601) [sender=3.0.7]
ls: /share/ClamAV/cvd/main-*.cdiff: No such file or directory
ls: /share/ClamAV/cvd/bytecode-*.cdiff: No such file or directory
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily.cld
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily.cvd
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: dns.txt
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: main.cld
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: main.cvd
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: mirrors.dat
Code: Select all
[/share/homes/CVD_Update] # ./CVD_Update.sh
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: bytecode.cld
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: bytecode.cvd
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26296.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26297.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26298.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26299.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26300.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26301.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26302.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26303.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26304.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26305.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26306.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26307.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26308.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26309.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26310.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26311.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26312.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26313.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26314.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26315.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26316.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26317.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily-26318.cdiff
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily.cld
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: daily.cvd
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: dns.txt
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: main.cld
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: main.cvd
Only in /share/MD0_DATA/.antivirus/usr/share/clamav: mirrors.dat
ls: /share/homes/ClamAV/cvd/main-*.cdiff: No such file or directory
ls: /share/homes/ClamAV/cvd/bytecode-*.cdiff: No such file or directory
Thanks for the report.MatthewFIU wrote: ↑Mon Oct 11, 2021 11:32 am Thanks. In the meantime, one helpful addition would be to have it automatically create the default directories if they aren't present. However, it doesn't look like it's practical to *directly* create the ClamAV directory under "/share" and download to it, because that uses the RAM disk, which doesn't leave it enough space. It was giving me the following rsync error:
I created the ClamAV and cvd folders under one of my QNAP's network share folders, which are already symbolically linked under /share, and that solved the problem.
The only remaining question is that I got the following two "No sure file" errors at the end of the script. Should if be looking for any main or bytecode cdiff files in the first place?
Virus scan of TS-220. (Interim report)MatthewFIU wrote: ↑Sat Oct 09, 2021 7:45 amI read that a tested model is the TS-220, but does it have enough RAM to properly run a scan at this point?MoRiSoVa wrote: ↑Wed Oct 06, 2021 4:46 pm The script is now available on github.
If you find any bugs, please let me know.
https://github.com/MoRiSoVaXZ/CVD_Update
Code: Select all
[~] # free
total used free shared buff/cache available
Mem: 515444 477116 16468 0 21860 0
-/+ buffers/cache: 477116 38328
Swap: 1554120 717156 836964
[~] # cat /proc/swaps
Filename Type Size Used Priority
/dev/md2 partition 530124 525116 -1
/share/MD0_DATA/.swap/qnap_swap file 1023996 202208 -2
Code: Select all
----------- SCAN SUMMARY -----------
Known viruses: 8518070
Engine version: 0.99.3
Scanned directories: 42
Scanned files: 184
Infected files: 0
Data scanned: 87.85 MB
Data read: 69.37 MB (ratio 1.27:1)
Time: 50105.785 sec (835 m 5 s)
You can run the scan job over SSH or via GUI.MatthewFIU wrote: ↑Wed Oct 13, 2021 10:08 am Is there a way to initiate the scan through the SSH command line, or are you just running a scan job from the Web GUI? I ask because I've been getting blank scan logs (even before I tried your update script). I think I read that it doesn't scan the system files, just the user files?
Code: Select all
Transcend TS128GJF910 (JetFlash 910)
Capacity : 128 GB
USB Type : USB Type-A / Connection Interface: USB 3.1 Gen 1
Transfer rate : Read (max.) 420 MB/s, Write (max.) 400 MB/s
Code: Select all
[~] # free
total used free shared buff/cache available
Mem: 515444 476624 16580 0 22240 0
-/+ buffers/cache: 476624 38820
Swap: 1535996 777808 758188
[~] # cat /proc/swaps
Filename Type Size Used Priority
/share/external/sdr1/qnap_swap file 1535996 774516 -1
Code: Select all
----------- SCAN SUMMARY -----------
Known viruses: 8516932
Engine version: 0.99.3
Scanned directories: 42
Scanned files: 184
Infected files: 0
Data scanned: 87.85 MB
Data read: 69.37 MB (ratio 1.27:1)
Time: 7513.714 sec (125 m 13 s)
Code: Select all
[~] # free
total used free shared buff/cache available
Mem: 515444 478292 16656 0 20496 0
-/+ buffers/cache: 478292 37152
Swap: 1534196 818336 715860
[~] # cat /proc/swaps
Filename Type Size Used Priority
/dev/sdr1 partition 1534196 819776 -1
Code: Select all
----------- SCAN SUMMARY -----------
Known viruses: 8516932
Engine version: 0.99.3
Scanned directories: 42
Scanned files: 184
Infected files: 0
Data scanned: 87.85 MB
Data read: 69.37 MB (ratio 1.27:1)
Time: 5780.592 sec (96 m 20 s)
The first swap to HDD expansion test is on an internal drive that is RAIDed (RAID1).MatthewFIU wrote: ↑Fri Oct 15, 2021 7:16 pm Please correct me if I overlooked this detail, but on your first swap expansion test onto the HDD, was this HDD space on the internal drives that are RAIDed, and the same ones that are being scanned? If not, I figure you could get a reasonable improvement from just using an *external* HDD for the swap, as it wouldn't be RAIDed, and would be separate from the internal drive being scanned. But maybe that's what you tested?