This commit was manufactured by cvs2svn to create branch 'SAMBA_3_0'.
[sfrench/samba-autobuild/.git] / docs / htmldocs / vfs.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <HTML
3 ><HEAD
4 ><TITLE
5 >Stackable VFS modules</TITLE
6 ><META
7 NAME="GENERATOR"
8 CONTENT="Modular DocBook HTML Stylesheet Version 1.77"><LINK
9 REL="HOME"
10 TITLE="SAMBA Project Documentation"
11 HREF="samba-howto-collection.html"><LINK
12 REL="UP"
13 TITLE="Optional configuration"
14 HREF="optional.html"><LINK
15 REL="PREVIOUS"
16 TITLE="Passdb XML plugin"
17 HREF="pdb-xml.html"><LINK
18 REL="NEXT"
19 TITLE="Storing Samba's User/Machine Account information in an LDAP Directory"
20 HREF="samba-ldap-howto.html"></HEAD
21 ><BODY
22 CLASS="CHAPTER"
23 BGCOLOR="#FFFFFF"
24 TEXT="#000000"
25 LINK="#0000FF"
26 VLINK="#840084"
27 ALINK="#0000FF"
28 ><DIV
29 CLASS="NAVHEADER"
30 ><TABLE
31 SUMMARY="Header navigation table"
32 WIDTH="100%"
33 BORDER="0"
34 CELLPADDING="0"
35 CELLSPACING="0"
36 ><TR
37 ><TH
38 COLSPAN="3"
39 ALIGN="center"
40 >SAMBA Project Documentation</TH
41 ></TR
42 ><TR
43 ><TD
44 WIDTH="10%"
45 ALIGN="left"
46 VALIGN="bottom"
47 ><A
48 HREF="pdb-xml.html"
49 ACCESSKEY="P"
50 >Prev</A
51 ></TD
52 ><TD
53 WIDTH="80%"
54 ALIGN="center"
55 VALIGN="bottom"
56 ></TD
57 ><TD
58 WIDTH="10%"
59 ALIGN="right"
60 VALIGN="bottom"
61 ><A
62 HREF="samba-ldap-howto.html"
63 ACCESSKEY="N"
64 >Next</A
65 ></TD
66 ></TR
67 ></TABLE
68 ><HR
69 ALIGN="LEFT"
70 WIDTH="100%"></DIV
71 ><DIV
72 CLASS="CHAPTER"
73 ><H1
74 ><A
75 NAME="VFS"
76 ></A
77 >Chapter 19. Stackable VFS modules</H1
78 ><DIV
79 CLASS="SECT1"
80 ><H1
81 CLASS="SECT1"
82 ><A
83 NAME="AEN2651"
84 ></A
85 >19.1. Introduction and configuration</H1
86 ><P
87 >Since samba 3.0, samba supports stackable VFS(Virtual File System) modules. 
88 Samba passes each request to access the unix file system thru the loaded VFS modules. 
89 This chapter covers all the modules that come with the samba source and references to 
90 some external modules.</P
91 ><P
92 >You may have problems to compile these modules, as shared libraries are
93 compiled and linked in different ways on different systems.
94 I currently tested them against GNU/linux and IRIX.</P
95 ><P
96 >To use the VFS modules, create a share similar to the one below.  The
97 important parameter is the <B
98 CLASS="COMMAND"
99 >vfs object</B
100 > parameter which must point to
101 the exact pathname of the shared library object. For example, to use audit.so:
102
103 <PRE
104 CLASS="PROGRAMLISTING"
105 >       [audit]
106                 comment = Audited /data directory
107                 path = /data
108                 vfs object = /path/to/audit.so
109                 writeable = yes
110                 browseable = yes</PRE
111 ></P
112 ><P
113 >Further documentation on writing VFS modules for Samba can be found in
114 docs directory of the Samba source distribution.</P
115 ></DIV
116 ><DIV
117 CLASS="SECT1"
118 ><H1
119 CLASS="SECT1"
120 ><A
121 NAME="AEN2659"
122 ></A
123 >19.2. Included modules</H1
124 ><DIV
125 CLASS="SECT2"
126 ><H2
127 CLASS="SECT2"
128 ><A
129 NAME="AEN2661"
130 ></A
131 >19.2.1. audit</H2
132 ><P
133 >A simple module to audit file access to the syslog
134 facility.  The following operations are logged:
135 <P
136 ></P
137 ><TABLE
138 BORDER="0"
139 ><TBODY
140 ><TR
141 ><TD
142 >share</TD
143 ></TR
144 ><TR
145 ><TD
146 >connect/disconnect</TD
147 ></TR
148 ><TR
149 ><TD
150 >directory opens/create/remove</TD
151 ></TR
152 ><TR
153 ><TD
154 >file open/close/rename/unlink/chmod</TD
155 ></TR
156 ></TBODY
157 ></TABLE
158 ><P
159 ></P
160 ></P
161 ></DIV
162 ><DIV
163 CLASS="SECT2"
164 ><H2
165 CLASS="SECT2"
166 ><A
167 NAME="AEN2669"
168 ></A
169 >19.2.2. recycle</H2
170 ><P
171 >A recycle-bin like modules. When used any unlink call
172 will be intercepted and files moved to the recycle
173 directory instead of beeing deleted.</P
174 ><P
175 >Supported options:
176 <P
177 ></P
178 ><DIV
179 CLASS="VARIABLELIST"
180 ><DL
181 ><DT
182 >vfs_recycle_bin:repository</DT
183 ><DD
184 ><P
185 >FIXME</P
186 ></DD
187 ><DT
188 >vfs_recycle_bin:keeptree</DT
189 ><DD
190 ><P
191 >FIXME</P
192 ></DD
193 ><DT
194 >vfs_recycle_bin:versions</DT
195 ><DD
196 ><P
197 >FIXME</P
198 ></DD
199 ><DT
200 >vfs_recycle_bin:touch</DT
201 ><DD
202 ><P
203 >FIXME</P
204 ></DD
205 ><DT
206 >vfs_recycle_bin:maxsize</DT
207 ><DD
208 ><P
209 >FIXME</P
210 ></DD
211 ><DT
212 >vfs_recycle_bin:exclude</DT
213 ><DD
214 ><P
215 >FIXME</P
216 ></DD
217 ><DT
218 >vfs_recycle_bin:exclude_dir</DT
219 ><DD
220 ><P
221 >FIXME</P
222 ></DD
223 ><DT
224 >vfs_recycle_bin:noversions</DT
225 ><DD
226 ><P
227 >FIXME</P
228 ></DD
229 ></DL
230 ></DIV
231 ></P
232 ></DIV
233 ><DIV
234 CLASS="SECT2"
235 ><H2
236 CLASS="SECT2"
237 ><A
238 NAME="AEN2706"
239 ></A
240 >19.2.3. netatalk</H2
241 ><P
242 >A netatalk module, that will ease co-existence of samba and
243 netatalk file sharing services.</P
244 ><P
245 >Advantages compared to the old netatalk module:
246 <P
247 ></P
248 ><TABLE
249 BORDER="0"
250 ><TBODY
251 ><TR
252 ><TD
253 >it doesn't care about creating of .AppleDouble forks, just keeps ones in sync</TD
254 ></TR
255 ><TR
256 ><TD
257 >if share in smb.conf doesn't contain .AppleDouble item in hide or veto list, it will be added automatically</TD
258 ></TR
259 ></TBODY
260 ></TABLE
261 ><P
262 ></P
263 ></P
264 ></DIV
265 ></DIV
266 ><DIV
267 CLASS="SECT1"
268 ><H1
269 CLASS="SECT1"
270 ><A
271 NAME="AEN2713"
272 ></A
273 >19.3. VFS modules available elsewhere</H1
274 ><P
275 >This section contains a listing of various other VFS modules that 
276 have been posted but don't currently reside in the Samba CVS 
277 tree for one reason ot another (e.g. it is easy for the maintainer 
278 to have his or her own CVS tree).</P
279 ><P
280 >No statemets about the stability or functionality any module
281 should be implied due to its presence here.</P
282 ><DIV
283 CLASS="SECT2"
284 ><H2
285 CLASS="SECT2"
286 ><A
287 NAME="AEN2717"
288 ></A
289 >19.3.1. DatabaseFS</H2
290 ><P
291 >URL: <A
292 HREF="http://www.css.tayloru.edu/~elorimer/databasefs/index.php"
293 TARGET="_top"
294 >http://www.css.tayloru.edu/~elorimer/databasefs/index.php</A
295 ></P
296 ><P
297 >By <A
298 HREF="mailto:elorimer@css.tayloru.edu"
299 TARGET="_top"
300 >Eric Lorimer</A
301 >.</P
302 ><P
303 >I have created a VFS module which implements a fairly complete read-only
304 filesystem.  It presents information from a database as a filesystem in
305 a modular and generic way to allow different databases to be used
306 (originally designed for organizing MP3s under directories such as
307 "Artists," "Song Keywords," etc... I have since applied it to a student
308 roster database very easily).  The directory structure is stored in the
309 database itself and the module makes no assumptions about the database
310 structure beyond the table it requires to run.</P
311 ><P
312 >Any feedback would be appreciated: comments, suggestions, patches,
313 etc...  If nothing else, hopefully it might prove useful for someone
314 else who wishes to create a virtual filesystem.</P
315 ></DIV
316 ><DIV
317 CLASS="SECT2"
318 ><H2
319 CLASS="SECT2"
320 ><A
321 NAME="AEN2725"
322 ></A
323 >19.3.2. vscan</H2
324 ><P
325 >URL: <A
326 HREF="http://www.openantivirus.org/"
327 TARGET="_top"
328 >http://www.openantivirus.org/</A
329 ></P
330 ><P
331 >samba-vscan is a proof-of-concept module for Samba, which
332 uses the VFS (virtual file system) features of Samba 2.2.x/3.0
333 alphaX. Of couse, Samba has to be compiled with VFS support. 
334 samba-vscan supports various virus scanners and is maintained 
335 by Rainer Link.</P
336 ></DIV
337 ></DIV
338 ></DIV
339 ><DIV
340 CLASS="NAVFOOTER"
341 ><HR
342 ALIGN="LEFT"
343 WIDTH="100%"><TABLE
344 SUMMARY="Footer navigation table"
345 WIDTH="100%"
346 BORDER="0"
347 CELLPADDING="0"
348 CELLSPACING="0"
349 ><TR
350 ><TD
351 WIDTH="33%"
352 ALIGN="left"
353 VALIGN="top"
354 ><A
355 HREF="pdb-xml.html"
356 ACCESSKEY="P"
357 >Prev</A
358 ></TD
359 ><TD
360 WIDTH="34%"
361 ALIGN="center"
362 VALIGN="top"
363 ><A
364 HREF="samba-howto-collection.html"
365 ACCESSKEY="H"
366 >Home</A
367 ></TD
368 ><TD
369 WIDTH="33%"
370 ALIGN="right"
371 VALIGN="top"
372 ><A
373 HREF="samba-ldap-howto.html"
374 ACCESSKEY="N"
375 >Next</A
376 ></TD
377 ></TR
378 ><TR
379 ><TD
380 WIDTH="33%"
381 ALIGN="left"
382 VALIGN="top"
383 >Passdb XML plugin</TD
384 ><TD
385 WIDTH="34%"
386 ALIGN="center"
387 VALIGN="top"
388 ><A
389 HREF="optional.html"
390 ACCESSKEY="U"
391 >Up</A
392 ></TD
393 ><TD
394 WIDTH="33%"
395 ALIGN="right"
396 VALIGN="top"
397 >Storing Samba's User/Machine Account information in an LDAP Directory</TD
398 ></TR
399 ></TABLE
400 ></DIV
401 ></BODY
402 ></HTML
403 >