The Windows operating system has a built-in anti-malware called the Microsoft Defender Antivirus which is always running to protect the user from potential attacks such as viruses, spyware, rootkits, and ransomware. This defender responds to the attacks by taking action immediately rather than responding to them after your computer has been infected.
As much as the Microsoft Defender is always running in the background to protect from attacks, one should run a full virus scan occasionally to ensure that nothing suspicious may have escaped the defender and infected your windows system. You can perform these scans when Windows is running slow, or you suspect the system is infected.
Let's see how to do it.
Update the Windows defender using the command prompt
Running a Virus Scan from the CMD
To perform a scan on your system, you need to run the CMD
with administrative privileges.
-
You can do so from the start menu by searching for
Command Prompt
.From the search results, right-click on
Command Prompt
and chooseRun as administrator
.If you are not signed in as admin, you will notice that the
User Account Control
window opens up.Click the
Yes
button, and thecommand prompt
should open. -
The are three types of scans that you can perform on your system with Microsoft defender: I.e., Quick Scan, Custom Scan, and Full scan. Let's start with the quick scan.
Quick Scan
The quick scan only scans for the critical areas of your system, such as running processes, system files, and registry keys. This scan is designed to be faster makeing it a good option for regular use.
To perform a quick scan, you have to change your current directory to the windows Defender installation directory. You can do this using the cd command. Use the command below to navigate to the windows defender installation directory.
cd C:\ProgramData\Microsoft\Windows Defender\Platform\4.18*
Once you are in the right folder, run the quick scan using the following command and hit
Enter
MpCmdRun -Scan -ScanType1
You will notice the
Start scanning
message after executing the command. Once the scan is complete, the message changes toscan finished
. And just like that, you have quickly scanned your system using the command prompt.Custom Scan
With the custom scan, you get to specify the files, folders, and drives the defender should scan. This option is useful if you suspect that a particular file or folder has been infected with malware. You can also use this option to examine an external drive.
To perform a custom scan, open the
command prompt
and run the command below to change directories to the windows defender installation folder.cd C:\ProgramData\Microsoft\Windows Defender\Platform\4.18*
Once you are in the right folder, perform the custom scan with the following command.
MpCmdRun -Scan -ScanType 3 -File <directory>
Note: Replace the
<directory>
with the drive you wish to scan.Full Scan
For the full scan, the defender examines the entire system thoroughly. It scans all the files and folders, email databases, external drives, and the critical areas of the system such as the programs loaded at startup, system memory, system backup, and even network drives. This option takes long (hours), depending on the size of the hard drive and the number of files. This scan is more comprehensive and can detect all types of malware and viruses. Ensure you run this scan periodically to keep your system safe from threats.
To perform a full scan, cd into the Windows defender installation directory as shown above and run the command below.
MpCmdRun -Scan -ScanType 2
With this command a full scan of your system will be initiated.
Running Full Virus Scan from the GUI.
If you are not comfortable using the command prompt
, you can use the graphical user interface to perform the same scans as above. Let us see how.
-
Start by opening the start menu.
-
Search for
windows Security
and open the top result from the search. -
From there, Open
Virus & threat protection
. -
A new window should open that has the different types of scan.
You can choose a
quick scan
from here, and the system will initiate it immediately. -
If you want to perform the full or custom scan, Choose the scan option to open more scan options.
Choose the scan type you want and click Scan now
. This will initiate the scan and if anything is detected, the Microsoft defender will remove/ quarantine the threats automatically.
Conclusion
Windows defender ensures that your computer is safe from malware. It runs periodically in the background and quarantines any threats found. However, some threats may escape the windows defender. Hence, one should run regular virus scans to maintain the security and integrity of the windows system. By following the steps outlined in this article, you can perform the different types of scans, such as the Quick, Custom, or the Full scans, to ensure that you are safe from malware, viruses, and ransomware.
If you found the article helpful, consider sharing it with those that might find it helpful.
Thank you for reading.