1 | <samba:parameter name="level2 oplocks"
|
---|
2 | context="S"
|
---|
3 | type="boolean"
|
---|
4 | xmlns:samba="http://www.samba.org/samba/DTD/samba-doc">
|
---|
5 | <description>
|
---|
6 | <para>This parameter controls whether Samba supports
|
---|
7 | level2 (read-only) oplocks on a share.</para>
|
---|
8 |
|
---|
9 | <para>Level2, or read-only oplocks allow Windows NT clients
|
---|
10 | that have an oplock on a file to downgrade from a read-write oplock
|
---|
11 | to a read-only oplock once a second client opens the file (instead
|
---|
12 | of releasing all oplocks on a second open, as in traditional,
|
---|
13 | exclusive oplocks). This allows all openers of the file that
|
---|
14 | support level2 oplocks to cache the file for read-ahead only (ie.
|
---|
15 | they may not cache writes or lock requests) and increases performance
|
---|
16 | for many accesses of files that are not commonly written (such as
|
---|
17 | application .EXE files).</para>
|
---|
18 |
|
---|
19 | <para>Once one of the clients which have a read-only oplock
|
---|
20 | writes to the file all clients are notified (no reply is needed
|
---|
21 | or waited for) and told to break their oplocks to "none" and
|
---|
22 | delete any read-ahead caches.</para>
|
---|
23 |
|
---|
24 | <para>It is recommended that this parameter be turned on to
|
---|
25 | speed access to shared executables.</para>
|
---|
26 |
|
---|
27 | <para>For more discussions on level2 oplocks see the CIFS spec.</para>
|
---|
28 |
|
---|
29 | <para>
|
---|
30 | Currently, if <smbconfoption name="kernel oplocks"/> are supported then
|
---|
31 | level2 oplocks are not granted (even if this parameter is set to
|
---|
32 | <constant>yes</constant>). Note also, the <smbconfoption name="oplocks"/>
|
---|
33 | parameter must be set to <constant>yes</constant> on this share in order for
|
---|
34 | this parameter to have any effect.</para>
|
---|
35 | </description>
|
---|
36 |
|
---|
37 | <related>oplocks</related>
|
---|
38 | <related>kernel oplocks</related>
|
---|
39 | <value type="default">yes</value>
|
---|
40 | </samba:parameter>
|
---|