Antivirus Configuration
Antivirus Configuration
Antivirus Configuration
Contents
Antivirus architecture
The NetApp antivirus architecture consists of a Vscan server and a set of ONTAP configurables.
Vscan server components
You must install the following components on the Vscan server.
ONTAP Antivirus Connector
The ONTAP Antivirus Connector provided by NetApp handles communication between
ONTAP and the Vscan server.
Antivirus software
ONTAP-compliant third-party antivirus software scans files for viruses or other malicious
code. You specify the remedial actions to be taken on infected files when you configure the
software.
Antivirus Configuration Guide 7
Understanding NetApp virus scanning
ONTAP configurables
You must configure the following items on the NetApp storage system.
Scanner pool
A scanner pool defines the Vscan servers and privileged users that can connect to SVMs. It
also defines a scan request timeout period, after which the scan request is sent to an
alternative Vscan server if one is available.
Note: It is a best practice to set the timeout period in the antivirus software on the Vscan
server to five seconds less than the scanner-pool request timeout period, to avoid
situations in which file access is delayed or denied altogether because the timeout period
on the software is greater than the timeout period for the scan request.
Privileged user
A privileged user is a domain user account that a Vscan server uses to connect to the SVM.
The account must be included in the list of privileged users defined in the scanner pool.
Scanner policy
A scanner policy determines whether a scanner pool is active. A scanner policy can have
one of the following values:
• Primary specifies that the scanner pool is active.
• Secondary specifies that the scanner pool is active only if none of the Vscan servers
in the primary scanner pool is connected.
• Idle specifies that the scanner pool is inactive.
Scanner policies are system-defined. You cannot create a custom scanner policy.
On-access policy
An on-access policy defines the scope of an on-access scan. You can specify the maximum
size of the files to be scanned, the extensions of the files to be included in the scan, and the
extensions and paths of the files to be excluded from the scan.
By default, only read-write volumes are scanned. You can specify filters that enable
scanning of read-only volumes or that restrict scanning to files opened with execute access:
• scan-ro-volume enables scanning of read-only volumes.
• scan-execute-access restricts scanning to files opened with execute access.
Note: "Execute access" is not identical with "execute permission." A given client will
have "execute access" on an executable file only if the file was opened with "execute
intent."
You can set the scan-mandatory option to off to specify that file access is allowed when
no Vscan servers are available for virus scanning.
On-demand task
An on-demand task defines the scope of an on-demand scan. You can specify the maximum
size of the files to be scanned, the extensions and paths of the files to be included in the
scan, and the extensions and paths of the files to be excluded from the scan. Files in
subdirectories are scanned by default.
You use a cron schedule to specify when the task runs. You can use the vserver vscan
on-demand-task run command to run the task immediately.
Antivirus Configuration Guide 8
Understanding NetApp virus scanning
Choices
• Creating a scanner pool on a single cluster on page 10
• Creating scanner pools in MetroCluster configurations on page 11
• Applying a scanner policy on a single cluster on page 13
• Applying scanner policies in MetroCluster configurations on page 14
• Commands for managing scanner pools on page 15
• Specify a data SVM for a pool defined for an individual SVM, and specify a cluster admin
SVM for a pool defined for all of the SVMs in a cluster.
• Specify an IP address or FQDN for each Vscan server host name.
• Specify the domain and user name for each privileged user.
For a complete list of options, see the man page for the command.
The following command creates a scanner pool named SP on the vs1 SVM:
Vserver: vs1
Scanner Pool: SP
Applied Policy: idle
Current Status: off
Cluster on Which Policy Is Applied: -
Scanner Pool Config Owner: vserver
List of IPs of Allowed Vscan Servers: 1.1.1.1, 10.72.204.27
List of Host Names of Allowed Vscan Servers: 1.1.1.1, vmwin204-27.fsct.nb
List of Privileged Users: cifs\u1, cifs\u2
You can also use the vserver vscan scanner-pool show command to view all of the
scanner pools on an SVM. For complete command syntax, see the man page for the command.
Related tasks
Applying a scanner policy on a single cluster on page 13
A scanner policy determines whether a scanner pool is active. You must make a scanner pool
active before the Vscan servers that are defined in the scanner pool can connect to an SVM.
Commands for managing scanner pools on page 15
You can modify and delete scanner pools, and manage privileged users and Vscan servers for a
scanner pool. You can view summary and details for a scanner pool.
Note: The list of privileged users must include the domain user account the Vscan server uses to
connect to the SVM.
Steps
1. Create a scanner pool:
vserver vscan scanner-pool create -vserver data_SVM|cluster_admin_SVM -scanner-pool
scanner_pool -hostnames Vscan_server_hostnames -privileged-users privileged_users
• Specify a data SVM for a pool defined for an individual SVM, and specify a cluster admin
SVM for a pool defined for all the SVMs in a cluster.
• Specify an IP address or FQDN for each Vscan server host name.
• Specify the domain and user name for each privileged user.
Important: You must create all scanner pools from the cluster containing the primary SVM.
For a complete list of options, see the man page for the command.
The following commands create primary and secondary scanner pools on each cluster in a
MetroCluster configuration:
cluster1::> vserver vscan scanner-pool create -vserver cifssvm1 -
scanner-pool pool1_for_site1 -hostnames scan1 -privileged-users cifs
\u1,cifs\u2
Vserver: cifssvm1
Scanner Pool: pool1_for_site1
Antivirus Configuration Guide 13
Configuring scanner pools
You can also use the vserver vscan scanner-pool show command to view all of the
scanner pools on an SVM. For complete command syntax, see the man page for the command.
The following example shows that the scanner pool named SP on the vs1 SVM is active:
Vserver: vs1
Scanner Pool: SP
Applied Policy: primary
Current Status: on
Cluster on Which Policy Is Applied: cluster1
Scanner Pool Config Owner: vserver
List of IPs of Allowed Vscan Servers: 1.1.1.1, 10.72.204.27
List of Host Names of Allowed Vscan Servers: 1.1.1.1, vmwin204-27.fsct.nb
List of Privileged Users: cifs\u1, cifs\u2
Antivirus Configuration Guide 14
Configuring scanner pools
You can use the vserver vscan scanner-pool show-active command to view the
active scanner pools on an SVM. For the complete command syntax, see the man page for the
command.
Related tasks
Commands for managing scanner pools on page 15
You can modify and delete scanner pools, and manage privileged users and Vscan servers for a
scanner pool. You can view summary and details for a scanner pool.
Important: You must apply all scanner policies from the cluster containing the primary
SVM.
The following commands apply scanner policies to the primary and secondary scanner pools
on each cluster in a MetroCluster configuration:
cluster1::>vserver vscan scanner-pool apply-policy -vserver cifssvm1
-scanner-pool pool1_for_site1 -scanner-policy primary -cluster cluster1
Vserver: cifssvm1
Scanner Pool: pool1_for_site1
Applied Policy: primary
Current Status: on
Antivirus Configuration Guide 15
Configuring scanner pools
You can use the vserver vscan scanner-pool show-active command to view the
active scanner pools on an SVM. For complete command syntax, see the man page for the
command.
Delete privileged users from a scanner pool vserver vscan scanner-pool privileged-
users remove
Add Vscan servers to a scanner pool vserver vscan scanner-pool servers add
Delete Vscan servers from a scanner pool vserver vscan scanner-pool servers remove
View summary and details for a scanner pool vserver vscan scanner-pool show
View privileged users for a scanner pool vserver vscan scanner-pool privileged-
users show
View Vscan servers for all scanner pools vserver vscan scanner-pool servers show
For more information about these commands, see the man pages.
Antivirus Configuration Guide 16
Configuring on-access scanning
Choices
• Creating an on-access policy on page 16
• Enabling an on-access policy on page 17
• Modifying the Vscan file-operations profile for a CIFS share on page 18
• Commands for managing on-access policies on page 18
• Specify a data SVM for a policy defined for an individual SVM, a cluster admin SVM for a
policy defined for all the SVMs in a cluster.
• The -file-ext-to-exclude setting overrides the -file-ext-to-include setting.
• Set -scan-files-with-no-ext to true to scan files without extensions.
The following command creates an on-access policy named Policy1 on the vs1 SVM:
Vserver: vs1
Policy: Policy1
Policy Status: off
Policy Config Owner: vserver
File-Access Protocol: CIFS
Filters: scan-ro-volume
Mandatory Scan: on
Max File Size Allowed for Scanning: 3GB
File Paths Not to Scan: \vol\a b\, \vol\a,b\
File Extensions Not to Scan: mp3, txt
File Extensions to Scan: mp*, tx*
Scan Files with No Extension: false
Related tasks
Enabling an on-access policy on page 17
You must enable an on-access policy on an SVM before its files can be scanned. If you created an
on-access policy for all the SVMs in a cluster, you must enable the policy on each SVM
individually. You can enable only one on-access policy on an SVM at a time.
Commands for managing on-access policies on page 18
You can modify, disable, or delete an on-access policy. You can view a summary and details for
the policy.
The following command enables an on-access policy named Policy1 on the vs1 SVM:
Vserver: vs1
Policy: Policy1
Policy Status: on
Policy Config Owner: vserver
File-Access Protocol: CIFS
Filters: scan-ro-volume
Mandatory Scan: on
Max File Size Allowed for Scanning: 3GB
File Paths Not to Scan: \vol\a b\, \vol\a,b\
File Extensions Not to Scan: mp3, txt
File Extensions to Scan: mp*, tx*
Scan Files with No Extension: false
Antivirus Configuration Guide 18
Configuring on-access scanning
Related tasks
Creating an on-access policy on page 16
An on-access policy defines the scope of an on-access scan. You can specify the maximum size of
the files to be scanned, the extensions of the files to be included in the scan, and the extensions and
paths of the files to be excluded from the scan. You can create an on-access policy for an
individual SVM or for all the SVMs in a cluster.
Commands for managing on-access policies on page 18
You can modify, disable, or delete an on-access policy. You can view a summary and details for
the policy.
Step
Modify the value of the Vscan file-operations profile for a CIFS share:
vserver cifs share modify -vserver data_SVM -share-name share -path share_path -vscan-
fileop-profile no-scan|standard|strict|writes-only
For a complete list of options, see the man page for the command.
The following command changes the Vscan file operations profile for a CIFS share to strict:
cluster1::> vserver cifs share modify -vserver vs1 -share-name SALES_SHARE -path /sales -
vscan-fileop-profile strict
View summary and details for an on-access policy vserver vscan on-access-policy show
Delete from the list of file extensions to exclude vscan on-access-policy file-ext-to-exclude
remove
Delete from the list of file extensions to include vscan on-access-policy file-ext-to-include
remove
For more information about these commands, see the man pages.
Antivirus Configuration Guide 20
Configuring on-demand scanning
Choices
• Creating an on-demand task on page 20
• Scheduling an on-demand task on page 21
• Running an on-demand task immediately on page 22
• Commands for managing on-demand tasks on page 23
cluster1::> vserver vscan on-demand-task create -vserver vs1 -task-name Task1 -scan-
paths "/vol1/","/vol2/cifs/" -report-directory "/report" -schedule daily -max-file-
size 5GB -paths-to-exclude "/vol1/cold-files/" -file-ext-to-include "vmdk?","mp*" -
file-ext-to-exclude "mp3","mp4" -scan-files-with-no-ext false
[Job 126]: Vscan On-Demand job is queued. Use the "job show -id 126" command to view
the status.
Antivirus Configuration Guide 21
Configuring on-demand scanning
Note: You can use the job show command to view the status of the job. You can use the
job pause and job resume commands to pause and restart the job, or the job stop
command to end the job.
2. Verify that the on-demand task has been created:
vserver vscan on-demand-task show -instance data_SVM -task-name task_name
For a complete list of options, see the man page for the command.
The following command displays the details for the Task1 task:
Vserver: vs1
Task Name: Task1
List of Scan Paths: /vol1/, /vol2/cifs/
Report Directory Path: /report
Job Schedule: daily
Max File Size Allowed for Scanning: 5GB
File Paths Not to Scan: /vol1/cold-files/
File Extensions Not to Scan: mp3, mp4
File Extensions to Scan: vmdk?, mp*
Scan Files with No Extension: false
Request Service Timeout: 5m
Cross Junction: true
Directory Recursion: true
Scan Priority: low
Report Log Level: info
Expiration Time for Report: -
The following command schedules an on-access task named Task2 on the vs2 SVM:
Note: You can use the job show command to view the status of the job. You can use the
job pause and job resume commands to pause and restart the job, or the job stop
command to end the job.
2. Verify that the on-demand task has been scheduled:
vserver vscan on-demand-task show -instance data_SVM -task-name task_name
For a complete list of options, see the man page for the command.
The following command displays the details for the Task 2 task:
cluster1::> vserver vscan on-demand-task show -instance vs2 -task-name Task2
Vserver: vs2
Task Name: Task2
List of Scan Paths: /vol1/, /vol2/cifs/
Report Directory Path: /report
Job Schedule: daily
Max File Size Allowed for Scanning: 5GB
File Paths Not to Scan: /vol1/cold-files/
File Extensions Not to Scan: mp3, mp4
File Extensions to Scan: vmdk, mp*
Scan Files with No Extension: false
Request Service Timeout: 5m
Cross Junction: true
Directory Recursion: true
Scan Priority: low
Report Log Level: info
Step
Run an on-demand task immediately:
vserver vscan on-demand-task run -vserver data_SVM -task-name task_name
The following command runs an on-access task named Task1 on the vs1 SVM:
Note: You can use the job show command to view the status of the job. You can use the job
pause and job resume commands to pause and restart the job, or the job stop command to
end the job.
Related tasks
Creating an on-demand task on page 20
An on-demand task defines the scope of an on-demand scan. You can specify the maximum size of
the files to be scanned, the extensions and paths of the files to be included in the scan, and the
extensions and paths of the files to be excluded from the scan. Files in subdirectories are scanned
by default.
Commands for managing on-demand tasks on page 23
You can modify, delete, or unschedule an on-demand task. You can view a summary and details
for the task, and manage reports for the task.
View summary and details for an on-demand task vserver vscan on-demand-task show
For more information about these commands, see the man pages.
Antivirus Configuration Guide 24
Enabling virus scanning on an SVM
Note: You can use the vserver vscan disable command to disable virus scanning if
necessary.
Vserver: vs1
Vscan Status: on
Antivirus Configuration Guide 25
Resetting the status of scanned files
Step
Reset the status of scanned files:
vserver vscan reset -vserver data_SVM
The following command resets the status of scanned files on the vs1 SVM:
View details for Vscan server connections vserver vscan connection-status show-all
View details for connected Vscan servers vserver vscan connection-status show-
connected
View details for available Vscan servers that are not vserver vscan connection-status show-not-
connected connected
For more information about these commands, see the man pages.
Antivirus Configuration Guide 28
Copyright and trademark
Copyright
Copyright © 2020 NetApp, Inc. All rights reserved. Printed in the U.S.
No part of this document covered by copyright may be reproduced in any form or by any means—
graphic, electronic, or mechanical, including photocopying, recording, taping, or storage in an
electronic retrieval system—without prior written permission of the copyright owner.
Software derived from copyrighted NetApp material is subject to the following license and
disclaimer:
THIS SOFTWARE IS PROVIDED BY NETAPP "AS IS" AND WITHOUT ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE,
WHICH ARE HEREBY DISCLAIMED. IN NO EVENT SHALL NETAPP BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
NetApp reserves the right to change any products described herein at any time, and without notice.
NetApp assumes no responsibility or liability arising from the use of products described herein,
except as expressly agreed to in writing by NetApp. The use or purchase of this product does not
convey a license under any patent rights, trademark rights, or any other intellectual property rights
of NetApp.
The product described in this manual may be protected by one or more U.S. patents, foreign
patents, or pending applications.
Data contained herein pertains to a commercial item (as defined in FAR 2.101) and is proprietary
to NetApp, Inc. The U.S. Government has a non-exclusive, non-transferrable, non-sublicensable,
worldwide, limited irrevocable license to use the Data only in connection with and in support of
the U.S. Government contract under which the Data was delivered. Except as provided herein, the
Data may not be used, disclosed, reproduced, modified, performed, or displayed without the prior
written approval of NetApp, Inc. United States Government license rights for the Department of
Defense are limited to those rights identified in DFARS clause 252.227-7015(b).
Trademark
NETAPP, the NETAPP logo, and the marks listed on the NetApp Trademarks page are trademarks
of NetApp, Inc. Other company and product names may be trademarks of their respective owners.
http://www.netapp.com/us/legal/netapptmlist.aspx