<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Export-policy for CIFS/SMB not working according to the export-policy rules in ONTAP Discussions</title>
    <link>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/142152#M31504</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;We were testing the Ontap feature to restrict a CIFS share based on ComputerNames/IPAddresses using export policies.&lt;/P&gt;
&lt;P&gt;The idea was to deny access to a set of computers and grant access to the remaining systems.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For eg.,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Export-policy: Test1&lt;/P&gt;
&lt;P&gt;Rule1: Deny access to System A&lt;/P&gt;
&lt;P&gt;Rules2: Allow access to 0.0.0.0/0 (remaining systems)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Requirement: Only System A should be denied access but rest should be able to access the share. But with the above rules in place, System A was also able to access the share.&lt;/P&gt;
&lt;P&gt;If I get it right, rules are processed in order based on rule index and if a client matches 1&lt;SUP&gt;st&lt;/SUP&gt; rule, rest will be ignored.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is this the default behaviour?&lt;/P&gt;
&lt;P&gt;Is there anyway I could&amp;nbsp;adjust export-policy rules to meet my requirement?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please suggest.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks in advance!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 04 Jun 2025 13:24:49 GMT</pubDate>
    <dc:creator>imshenthil</dc:creator>
    <dc:date>2025-06-04T13:24:49Z</dc:date>
    <item>
      <title>Export-policy for CIFS/SMB not working according to the export-policy rules</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/142152#M31504</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;We were testing the Ontap feature to restrict a CIFS share based on ComputerNames/IPAddresses using export policies.&lt;/P&gt;
&lt;P&gt;The idea was to deny access to a set of computers and grant access to the remaining systems.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For eg.,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Export-policy: Test1&lt;/P&gt;
&lt;P&gt;Rule1: Deny access to System A&lt;/P&gt;
&lt;P&gt;Rules2: Allow access to 0.0.0.0/0 (remaining systems)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Requirement: Only System A should be denied access but rest should be able to access the share. But with the above rules in place, System A was also able to access the share.&lt;/P&gt;
&lt;P&gt;If I get it right, rules are processed in order based on rule index and if a client matches 1&lt;SUP&gt;st&lt;/SUP&gt; rule, rest will be ignored.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is this the default behaviour?&lt;/P&gt;
&lt;P&gt;Is there anyway I could&amp;nbsp;adjust export-policy rules to meet my requirement?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please suggest.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks in advance!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jun 2025 13:24:49 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/142152#M31504</guid>
      <dc:creator>imshenthil</dc:creator>
      <dc:date>2025-06-04T13:24:49Z</dc:date>
    </item>
    <item>
      <title>Re: Export-policy for CIFS/SMB not working according to the export-policy rules</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/142160#M31508</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp;Can you please change the client specification for the export policy rule 2 to '&amp;lt;domain_name&amp;gt;&lt;SPAN&gt;.com'&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please go through&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://library.netapp.com/ecmdocs/ECMP1141091/html/GUID-417C1E61-EEE5-4762-9799-DAF16557097A.html" target="_blank"&gt;https://library.netapp.com/ecmdocs/ECMP1141091/html/GUID-417C1E61-EEE5-4762-9799-DAF16557097A.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 17 Aug 2018 09:30:20 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/142160#M31508</guid>
      <dc:creator>mrahul</dc:creator>
      <dc:date>2018-08-17T09:30:20Z</dc:date>
    </item>
    <item>
      <title>Re: Export-policy for CIFS/SMB not working according to the export-policy rules</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/142169#M31512</link>
      <description>&lt;P&gt;What version of ONTAP do you have is it 7-Mode?&lt;/P&gt;
&lt;P&gt;If it is ONTAP 9 or ONTAP 8 cDOT, give us output of export policies for your data volume AND svm root volume:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Let's investigate first. Here are the steps you need to perform with my examples:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Step1.&lt;/STRONG&gt; First check access to you volume&lt;/P&gt;
&lt;PRE&gt;cluster1::&amp;gt; vserver export-policy check-access -vserver svm01 -volume nfs_vol1 -client-ip 192.168.0.1 -authentication-method none -protocol nfs3 -access-type read-write
Policy Policy Rule
Path Policy Owner Owner Type Index Access
----------------------------- ---------- --------- ---------- ------ ----------
/ default svm01_root
volume 1 read
/nfs_vol1_NFS_volume nfs_vol1 nfs_vol1 volume 1 read-write
2 entries were displayed.&lt;/PRE&gt;
&lt;P&gt;&lt;STRONG&gt;Note: There is SVM root volume in the data path from the client to your data volume. So we are going to take a look on svm01_root volume too, it is important!&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Step 2.&lt;/STRONG&gt; Show your volumes, their junction path and assigned policy, in this case, we are interested in volumes from Step1 (svm01_root &amp;amp; nfs_vol1 &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;
&lt;PRE&gt;cluster1::&amp;gt; volume show -fields vserver,volume,aggregate,state,type,size,available,used,junction-path,policy
vserver volume aggregate size state policy junction-path available used type
----------- ------ ----------------- ------- ------ ------ ------------- --------- ------ ----
svm01 nfs_vol1
cluster1_02_SSD_1 10GB online nfs_vol1
/nfs_vol1_NFS_volume
9.50GB 312KB RW
svm01 svm01_root
cluster1_01_SSD_1 20MB online default
/ 18.73MB 280KB RW

2 entries were displayed.&lt;/PRE&gt;
&lt;P&gt;&lt;STRONG&gt;Step 3.&lt;/STRONG&gt; Show export policies you have (just in case)&lt;/P&gt;
&lt;PRE&gt;cluster1::&amp;gt; vserver export-policy show
Vserver Policy Name
--------------- -------------------
svm01 default
svm01 nfs_vol1
2 entries were displayed.&lt;/PRE&gt;
&lt;P&gt;&lt;STRONG&gt;Step 4.&lt;/STRONG&gt; Show rules you have for each policy &amp;amp; index, we are interested in those export policies from Step 2 (nfs_vol1, default)&lt;/P&gt;
&lt;PRE&gt;cluster1::&amp;gt; vserver export-policy rule show
Policy Rule Access Client RO
Vserver Name Index Protocol Match Rule
------------ --------------- ------ -------- --------------------- ---------
svm01 default 1 any 0.0.0.0/0 none
svm01 nfs_vol1 1 any 0.0.0.0/0 none
2 entries were displayed.&lt;/PRE&gt;
&lt;P&gt;&lt;BR /&gt;&lt;STRONG&gt;Step 5.&lt;/STRONG&gt; Show details for *&lt;STRONG&gt;each rule&lt;/STRONG&gt;* for export policies from Step 2 (nfs_vol1, default)&lt;/P&gt;
&lt;PRE&gt;cluster1::&amp;gt; vserver export-policy rule show -policyname &lt;STRONG&gt;nfs_vol1&lt;/STRONG&gt; -ruleindex &lt;STRONG&gt;1&lt;/STRONG&gt; -vserver svm01

Vserver: svm01
Policy Name: default
Rule Index: 1
Access Protocol: any
List of Client Match Hostnames, IP Addresses, Netgroups, or Domains: 0.0.0.0/0
RO Access Rule: none
RW Access Rule: any
User ID To Which Anonymous Users Are Mapped: 65534
Superuser Security Types: none
Honor SetUID Bits in SETATTR: true
Allow Creation of Devices: true&lt;/PRE&gt;
&lt;PRE&gt;cluster1::&amp;gt; vserver export-policy rule show -policyname &lt;STRONG&gt;default&lt;/STRONG&gt; -ruleindex &lt;STRONG&gt;1&lt;/STRONG&gt; -vserver svm01

Vserver: svm01
Policy Name: default
Rule Index: 1
Access Protocol: any
List of Client Match Hostnames, IP Addresses, Netgroups, or Domains: 0.0.0.0/0
RO Access Rule: none
RW Access Rule: any
User ID To Which Anonymous Users Are Mapped: 65534
Superuser Security Types: none
Honor SetUID Bits in SETATTR: true
Allow Creation of Devices: true&amp;nbsp;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 17 Aug 2018 15:13:15 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/142169#M31512</guid>
      <dc:creator>Damien_Queen</dc:creator>
      <dc:date>2018-08-17T15:13:15Z</dc:date>
    </item>
    <item>
      <title>Re: Export-policy for CIFS/SMB not working according to the export-policy rules</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/142175#M31515</link>
      <description>&lt;P&gt;Export policy enforment for SMB access has been disabled by default since about ONTAP 8.2.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;To enable it:&lt;/P&gt;
&lt;PRE&gt;set -privilege advanced
vserver cifs options modify -vserver &amp;lt;vserver_name&amp;gt; -is-exportpolicy-enabled true
set -privilege admin&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then close you client's SMB sessions and try again.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 17 Aug 2018 18:11:28 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/142175#M31515</guid>
      <dc:creator>SeanHatfield</dc:creator>
      <dc:date>2018-08-17T18:11:28Z</dc:date>
    </item>
    <item>
      <title>Re: Export-policy for CIFS/SMB not working according to the export-policy rules</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/142190#M31516</link>
      <description>&lt;P&gt;Thanks for your response!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This actually works if I deny the access to a host in a domain and allow access to other hosts in another domain.&lt;/P&gt;
&lt;P&gt;For eg., with following rules in place, it works between 2 separate domains.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Rule1: Deny - host1.abc.example.com&lt;/P&gt;
&lt;P&gt;Rule2: Allow - .xyz.example.com&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;However, if I want to deny access for a specific host in a domain&amp;nbsp;and allow access to remaining hosts in same domain, it doesn't work.&lt;/P&gt;
&lt;P&gt;Export rules used for testing is below.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Rule1: Deny - host1.abc.example.com&lt;/P&gt;
&lt;P&gt;Rule2: Allow - .abc.example.com&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is there any way to restrict specific host in a domain&amp;nbsp;and allow access to remaining hosts in same domain?&lt;/P&gt;
&lt;P&gt;Thanks for your help!&lt;/P&gt;</description>
      <pubDate>Mon, 20 Aug 2018 11:46:59 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/142190#M31516</guid>
      <dc:creator>imshenthil</dc:creator>
      <dc:date>2018-08-20T11:46:59Z</dc:date>
    </item>
    <item>
      <title>Re: Export-policy for CIFS/SMB not working according to the export-policy rules</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/143289#M31790</link>
      <description>&lt;P&gt;Never mind. This behaviour was due to the&amp;nbsp;DNS resolution issue&amp;nbsp;on the clients that&amp;nbsp;were able to access.&lt;/P&gt;
&lt;P&gt;After DNS issue is fixed, it works as it should.&lt;/P&gt;</description>
      <pubDate>Fri, 05 Oct 2018 13:44:01 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Export-policy-for-CIFS-SMB-not-working-according-to-the-export-policy-rules/m-p/143289#M31790</guid>
      <dc:creator>imshenthil</dc:creator>
      <dc:date>2018-10-05T13:44:01Z</dc:date>
    </item>
  </channel>
</rss>

