Author Topic: How to initiate scan for viruses from a .bat file?  (Read 6402 times)

0 Members and 1 Guest are viewing this topic.

fantasia

  • Guest
How to initiate scan for viruses from a .bat file?
« on: December 29, 2009, 12:55:45 AM »
Hello, everyone!

I've been using avast! 4.8 Home Edition for about a week or so, and let me tell you - it's a dream come true when it comes to anti-virus software. Have been troubling with various stuff for quite some time - I rarely welcome changes, so I get stuck to one program that serves the purpose more or less... Anyway, really like this one.

Here's the thing: I'm trying to make a .bat file which will do most of the maintenance for me - disk clean up and defragmenting and, of course, scan for viruses. The first par was easy... But is there a way to initiate virus scans in avast 4.8 home edition using a .bat file? If there is, what's the command to do it? I've already tried with "start ashSimpl.exe", but it just opened the file for me... I guess that that's where I come to part (in Windows) where I click that triangular thinguy, and the scan starts?

Mind that my knowledge about computers is quite limited (that explains the question... :D), so it is very possible that it's just the right DOS command that keeps slipping away from me. But I couldn't figure better place to ask this question...

Best regards,

Jelena

Offline DavidR

  • Avast Überevangelist
  • Certainly Bot
  • *****
  • Posts: 89064
  • No support PMs thanks
Re: How to initiate scan for viruses from a .bat file?
« Reply #1 on: December 29, 2009, 01:04:37 AM »
Short answer is NO, that is a limitation of the Home version, as you have found the ashSimpl.exe is just the Simple User Interface not a scan.

Personally I see little value in these type of scheduled scans on a resident anti-virus, you mind should now spark with the mention of scheduled as there is a work around using windows schedule function. avast 5.0 will have the ability to schedule scans when it is released, even in the free version, so this work around has limited worth.

Check this work around out - HOWTO: Scheduled Automatic Scans avast! Home Version!

The major disadvantage with the task scheduler trick of using ashquick.exe is, it will scan every file of the hdd, partition, folder or file that you set it to scan; even those files not considered a potential threat, this can take a long time.
 
It is possible to add certain folders to the exclusions list for say your media files, etc. Care should be taken with the paths you want to exclude as this could leave you vulnerable if that folder got infected as it wouldn't be scanned by the on-demand scanner as you have excluded it. However, should you access any infected file in a Folder in the Program Settings, Exclusions, the on-access scanner (Standard Shield) should detect it provided you haven't put the exclusions in there.

The Pro version gives a lot more flexibility and the scan would follow the settings and exclusions, etc. of the regular scan.

With the different levels of protection (Web Shield, Internet Mail, P2P and Instant Messaging) and the fall back of the Standard Shield, I find the need for daily scheduled scans lessened. I prefer to do a manual scan with my regular weekly maintenance tasks.
Windows 10 Home 64bit/ Acer Aspire F15/ Intel Core i5 7200U 2.5GHz, 8GB DDR4 memory, 256GB SSD, 1TB HDD/ avast! free 24.3.6108 (build 24.3.8975.762) UI 1.0.801/ Firefox, uBlock Origin, uMatrix/ MailWasher Pro/ Avast! Mobile Security

fantasia

  • Guest
Re: How to initiate scan for viruses from a .bat file?
« Reply #2 on: December 29, 2009, 01:10:14 AM »
Thank you, David. It does make sense. :)

Offline DavidR

  • Avast Überevangelist
  • Certainly Bot
  • *****
  • Posts: 89064
  • No support PMs thanks
Re: How to initiate scan for viruses from a .bat file?
« Reply #3 on: December 29, 2009, 02:18:34 AM »
No problem, glad I could help.

Welcome to the forums.
Windows 10 Home 64bit/ Acer Aspire F15/ Intel Core i5 7200U 2.5GHz, 8GB DDR4 memory, 256GB SSD, 1TB HDD/ avast! free 24.3.6108 (build 24.3.8975.762) UI 1.0.801/ Firefox, uBlock Origin, uMatrix/ MailWasher Pro/ Avast! Mobile Security

RegB

  • Guest
Re: How to initiate scan for viruses from a .bat file?
« Reply #4 on: December 29, 2009, 03:15:26 AM »
Hello, everyone!

I've been using avast! 4.8 Home Edition for about a week or so, and let me tell you - it's a dream come true when it comes to anti-virus software. Have been troubling with various stuff for quite some time - I rarely welcome changes, so I get stuck to one program that serves the purpose more or less... Anyway, really like this one.

Here's the thing: I'm trying to make a .bat file which will do most of the maintenance for me - disk clean up and defragmenting and, of course, scan for viruses. The first par was easy... But is there a way to initiate virus scans in avast 4.8 home edition using a .bat file? If there is, what's the command to do it? I've already tried with "start ashSimpl.exe", but it just opened the file for me... I guess that that's where I come to part (in Windows) where I click that triangular thinguy, and the scan starts?

Mind that my knowledge about computers is quite limited (that explains the question... :D), so it is very possible that it's just the right DOS command that keeps slipping away from me. But I couldn't figure better place to ask this question...

Best regards,

Jelena

You could try passing it a parameter (argument) or two ?
That might work (-:

JanAchik123

  • Guest
Re: How to initiate scan for viruses from a .bat file?
« Reply #5 on: December 29, 2009, 12:02:27 PM »
"C:\Program Files\Alwil Software\Avast4\ashquick" C:

Will scan your c drive.

Offline DavidR

  • Avast Überevangelist
  • Certainly Bot
  • *****
  • Posts: 89064
  • No support PMs thanks
Re: How to initiate scan for viruses from a .bat file?
« Reply #6 on: December 29, 2009, 03:39:53 PM »
You missed a bit "C:\Program Files\Alwil Software\Avast4\ashquick.exe"

Personally I wouldn't want to run this kind of scan on the c:\ drive, the ashquick.exe scan is the most thorough of all the scans.
Windows 10 Home 64bit/ Acer Aspire F15/ Intel Core i5 7200U 2.5GHz, 8GB DDR4 memory, 256GB SSD, 1TB HDD/ avast! free 24.3.6108 (build 24.3.8975.762) UI 1.0.801/ Firefox, uBlock Origin, uMatrix/ MailWasher Pro/ Avast! Mobile Security