Does your platform have GNU time or strace?  Try running clamscan with
'/usr/bin/time -v' and/or 'strace -c' and compare the output with that of
your Ubuntu host.

I wonder if loading the signature DB is causing excessive page faults on
the system without as much memory (time -v will tell you how many page
faults there were).  Here's an example run from an Ubuntu VM:

$ /usr/bin/time -v clamscan requirements.txt
requirements.txt: OK

----------- SCAN SUMMARY -----------
Known viruses: 8990282
Engine version: 0.100.0
Scanned directories: 0
Scanned files: 1
Infected files: 0
Data scanned: 0.00 MB
Data read: 0.00 MB (ratio 0.00:1)
Time: 62.459 sec (1 m 2 s)
Command being timed: "clamscan requirements.txt"
User time (seconds): 35.13
System time (seconds): 27.24
Percent of CPU this job got: 99%
Elapsed (wall clock) time (h:mm:ss or m:ss): 1:02.54
Average shared text size (kbytes): 0
Average unshared data size (kbytes): 0
Average stack size (kbytes): 0
Average total size (kbytes): 0
Maximum resident set size (kbytes): 1005616
Average resident set size (kbytes): 0
Major (requiring I/O) page faults: 0
Minor (reclaiming a frame) page faults: 251128
Voluntary context switches: 2
Involuntary context switches: 2220
Swaps: 0
File system inputs: 8
File system outputs: 8
Socket messages sent: 0
Socket messages received: 0
Signals delivered: 0
Page size (bytes): 4096
Exit status: 0

-Andrew

On Wed, May 29, 2019 at 3:50 AM Narashimman Srinivasan <
msriniva...@mvista.com> wrote:

> Hi
>
> In  custom target, testing of clamAV (0.101.2) scanning set of
> files/folders when RFS is from SD-MMC appears
> same time taken (~13 mins) with(~1.8GB)/without swap memory under 1 GB RAM.
> On comparison clamAV (0.101.2) with Ubuntu host (6 GB, 64 bits), time
> taken is always quicker (~42 secs).
>
> Following is log where time taken is almost same for scanning single file
> or set of files on custom target (1 GB RAM)
> running with Linux kernel 4.9, where root file system is from  SD-MMC card.
>
> Please let me know your valuable feedback.
> ----------------------------
> clamscan ./
> ./.viminfo: OK
>
> ----------- SCAN SUMMARY -----------
> Known viruses: 6123265
> Engine version: 0.101.2
> Scanned directories: 1
> Scanned files: 1
> Infected files: 0
> Data scanned: 0.00 MB
> Data read: 0.00 MB (ratio 0.00:1)
> Time: 774.923 sec (12 m 54 s)
> ---------------------------------------
>
>
>  clamscan ./*
> ./101/clamav-freshclam-0.101.2-r0.2.2.cortexa9hf_neon.rpm: OK
> ./101/clamav-0.101.2-r0.2.2.cortexa9hf_neon.rpm: OK
> ./101/clamav-libclamav-0.101.2-r0.2.2.cortexa9hf_neon.rpm: OK
> ./101-old/clamav-0.101-r0.2.cortexa9hf_neon.rpm: OK
> ./101-old/clamav-lic-0.101-r0.2.cortexa9hf_neon.rpm: OK
> ./101-old/clamav-libclamav-0.101-r0.2.cortexa9hf_neon.rpm: OK
> ./101-old/clamav-freshclam-0.101-r0.2.cortexa9hf_neon.rpm: OK
> ./101-old1/clamav-0.101-r0.2.cortexa9hf_neon.rpm: OK
> ./101-old1/clamav-libclamav-0.101-r0.2.cortexa9hf_neon.rpm: OK
> ./101-old1/clamav-freshclam-0.101-r0.2.cortexa9hf_neon.rpm: OK
> ./99/clamav-lic-0.99.2-r0.1.cortexa9hf_neon.rpm: OK
> ./99/clamav-libclamav-0.99.2-r0.1.cortexa9hf_neon.rpm: OK
> ./99/clamav-freshclam-0.99.2-r0.1.cortexa9hf_neon.rpm: OK
> ./99/clamav-0.99.2-r0.1.cortexa9hf_neon.rpm: OK
>
> ----------- SCAN SUMMARY -----------
> Known viruses: 6123265
> Engine version: 0.101.2
> Scanned directories: 4
> Scanned files: 14
> Infected files: 0
> Data scanned: 7.56 MB
> Data read: 3.74 MB (ratio 2.02:1)
> Time: 791.395 sec (13 m 11 s)
> -----------------------------------------
> Thank & Regards
> Manjunatha Srinivasan N
>
> _______________________________________________
>
> clamav-users mailing list
> clamav-users@lists.clamav.net
> https://lists.clamav.net/mailman/listinfo/clamav-users
>
>
> Help us build a comprehensive ClamAV guide:
> https://github.com/vrtadmin/clamav-faq
>
> http://www.clamav.net/contact.html#ml
>
_______________________________________________

clamav-users mailing list
clamav-users@lists.clamav.net
https://lists.clamav.net/mailman/listinfo/clamav-users


Help us build a comprehensive ClamAV guide:
https://github.com/vrtadmin/clamav-faq

http://www.clamav.net/contact.html#ml

Reply via email to