/usr/share/doc/namazu2-common/en/nmz.html is in namazu2-common 2.0.21-21.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta name="ROBOTS" content="NOINDEX,NOFOLLOW">
<link rel="stylesheet" href="../namazu.css">
<link rev="made" href="mailto:developers@namazu.org">
<title>Specification of NMZ.* files</title>
</head>
<body>
<h1>Specification of NMZ.* files</h1>
<hr>
<h2>Table of Contents</h2>
<ul>
<li><a href="#i">NMZ.i</a>
<li><a href="#ii">NMZ.ii</a>
<li><a href="#w">NMZ.w</a>
<li><a href="#wi">NMZ.wi</a>
<li><a href="#r">NMZ.r</a>
<li><a href="#p">NMZ.p</a>
<li><a href="#pi">NMZ.pi</a>
<li><a href="#t">NMZ.t</a>
<li><a href="#field">NMZ.field.{subject,from,date,message-id,...}</a>
<li><a href="#field-i">NMZ.field.{subject,from,date,message-id,...}.i</a>
<li><a href="#access">NMZ.access</a>
<li><a href="#status">NMZ.status</a>
<li><a href="#result">NMZ.result</a>
<li><a href="#head">NMZ.head</a>
<li><a href="#foot">NMZ.foot</a>
<li><a href="#body">NMZ.body</a>
<li><a href="#tips">NMZ.tips</a>
<li><a href="#log">NMZ.log</a>
<li><a href="#lock">NMZ.lock</a>
<li><a href="#lock2">NMZ.lock2</a>
<li><a href="#slog">NMZ.slog</a>
</ul>
<h2><a name="i">NMZ.i</a></h2>
<p>Index file for word searching. (inverted file)</p>
<h3>Structure</h3>
For each word, the pair of [documentID containing that word][score]
is stored sequencially, making the record for the word.
The record is of variable length, the byte count of each data part
is placed in front of them.
<pre>
[data length for word1][documentID][score][documentID][score]...
[data length for word2][documentID][score][documentID][score]...
[data length for word3][documentID][score][documentID][score]...
:
</pre>
<h3>Note</h3>
<ul>
<li>DocumentID are sorted in ascending order --INPORTANT.
<li>DocumentID are stored by only gaps.<br>
e.g., 1, 5, 29, 34 -> 1, 4, 24, 5
<li>Data is stored in "pack 'w'" format. (BER compression)
</ul>
<h2><a name="ii">NMZ.ii</a></h2>
<p>Index for 'seek'ing NMZ.i.</p>
<h3>Structure</h3>
<pre>
[position of word 1 in NMZ.i][position of word 2 in NMZ.i]
[position of word 3 in NMZ.i]...
</pre>
<h3>Note</h3>
<ul>
<li>All data is in binary. (pack 'N')
</ul>
<h2><a name="w">NMZ.w</a></h2>
<p>
List of words.
</p>
<h3>Structure</h3>
<p>
A simple line-oriented text. Sorted in ascending order. You can seek
NMZ.ii by line number. (Note: line number = wordID)
</p>
<h3>Note</h3>
<ul>
<li>Words are sorted in ascending order. (list of words are recorded in "NMZ.w")
<li>Regular Expression/substring/suffix matching greps the entire file.
<li>Characters in JIS X 0208 are recored in EUC-JP.
</ul>
<h2><a name="wi">NMZ.wi</a></h2>
<p>Index for 'seek'ing NMZ.w </p>
<h3>Structure</h3>
<pre>
[position of word 1 in NMZ.w][position of word 2 in NMZ.w]
[position of word 3 in NMZ.w]...
</pre>
<h3>Note</h3>
<ul>
<li>All data is in binary. (pack 'N')
</ul>
<h2><a name="r">NMZ.r</a></h2>
<p>List of files registered in index.</p>
<h3>Structure</h3>
<p>
Each line records a document file which is registered in the index
file. However, a line beginning with '#' indicates a file deleted
from the index. A line beginning with '##' indicates comment.
Example:
</p>
<pre>
/home/foo/bar1.html
/home/foo/bar2.html
/home/foo/bar3.html
## indexed: Sun, 08 Jan 2006 02:28:00 +0900
(an empty line)
# /home/foo/bar1.html
## deleted: Sun, 08 Jan 1998 12:34:56 +0900
</pre>
<h2><a name="p">NMZ.p</a></h2>
<p>Index for phrase searching.</p>
<h3>Description</h3>
<p>
Two words are converted to a 16 bit hash value. For phrase
searching, all words in a phrase are 'AND'ed and searched,
then check the word order by referring NMZ.p. Note that the
word order are recorded for each two word pairs. So, to
search "foo bar baz", documents including "foo bar" or "bar
baz" are retrieved. By collision of hash values,
inappropriate documents may also be retrieved. Though phrase
search is inaccurate, it usually works fine.
</p>
<h3>Structure</h3>
<pre>
|<------ data byte count (1) ------->|
[data byte count(1)][documentID including hash value \x0000]...
|<------ data byte count (2) ------->|
[data byte count(2)][documentID including hash value \x0001]...
...
[data byte count(n)][documentID including hash value \xffff]...
</pre>
<h3>Note</h3>
<ul>
<li>DocumentID are sorted in ascending order. -- IMPORTANT
<li>DocumentID are stored by only gaps.<br>
e.g., 1, 5, 29, 34 -> 1, 4, 24, 5
<li>All data is stored in "pack 'w'". (BER compression)
</ul>
<h2><a name="pi">NMZ.pi</a></h2>
<p>Index of index for phrase searching.</p>
<h3>Structure</h3>
<pre>
[position of \x0000 in NMZ.p][position of \x0001 in NMZ.p] ...
[position of \xffff in NMZ.p]
</pre>
<h3>Note</h3>
<ul>
<li>All data is in binary. (pack 'N')
<li>Always 256 Kb
</ul>
<h2><a name="t">NMZ.t</a></h2>
<p>Record information about time stamps and deleted documents.</p>
<h3>Description</h3>
<p>
File time stamps are recorded in 32 bits. This is used for sorting
search results by date. Also, if value is -1, then the document is
regarded as deleted.
</p>
<h3>Structure</h3>
<pre>
[time stamp of documentID1][time stamp of documentID2]...
</pre>
<h3>Note</h3>
<ul>
<li>All data is in binary. (pack 'N')
<li>Has the year 2038 problem.
</ul>
<h2><a name="field">NMZ.field.{subject,from,date,message-id,...}</a></h2>
<p>File to record field information.</p>
<h3>Description</h3>
<p>
Used in field-specified searching. A simple line-oriented
text. grep'ed by the regular expression engine. A line
number can be used as a documentID. Also, used in displaying
the search results.
</p>
<h3>Structure</h3>
<p>
A simple line-oriented text. (line number = documentID)
</p>
<h3>Note</h3>
<p>
Since it is a line-oriented text, it can be edited by an
editor or other tools. In case you edit, you should rebuild
<a
href="#field-i">NMZ.field.{subject,from,date,message-id,...}.i</a>
files by <a href="manual.html#rfnmz">rfnmz</a>.
</p>
<h2><a name="field-i">NMZ.field.{subject,from,date,message-id,...}.i</a></h2>
<p>Index for 'seek'ing NMZ.field.{subject,from,date,message-id,...}</p>
<h3>Structure</h3>
<pre>
[field position in documentID1][field position in documentID2]...
</pre>
<h3>Note</h3>
<ul>
<li>All data is in binary.
<li>All data is in binary. (pack 'N')
</ul>
<h2><a name="access">NMZ.access</a></h2>
<p>Configuration file for user access control.</p>
<h3>Structure</h3>
<p>
Access control by IP address, host name and/or domain name.
<code>deny</code> defines hosts from which you deny user
access, and <code>allow</code> defines hosts from which you
allow user access. When host is specified by IP address,
prefix matching is used, and when host if specified by host
name or domain name, suffix matching is
used. <code>all</code> indicates all hosts. Configuration is
evaluated from the top. Example:
</p>
<pre>
deny all
allow localhost
allow 123.123.123.
allow .example.jp
</pre>
<p>
This configuration allows access from the localhost, hosts
with IP address 123.123.123.*, or hosts with domain name
*.example.jp. Access from other hosts are denied.
</p>
<p>
For Apache web sever, access control by host name and/or
domain name requires the following description in
"httpd.conf".
</p>
<pre>
HostnameLookups On
</pre>
<h2><a name="status">NMZ.status</a></h2>
<p>Data necessary to update index is stored.</p>
<h2><a name="result">NMZ.result</a></h2>
<p>File to specify the style of search results.</p>
<h3>Description</h3>
<p>
${field name} is replaced by the contents of the field. For example,
${title} is replaced by the contents of
NMZ.field.title. ${namazu::counter} and ${namazu::score} have special
meanings. They are replaced by the counter of search results and its
score respectively.
</p>
<p>
By default, NMZ.result.normal and NMZ.result.short are provided.
Users can freely create NMZ.result.*.
</p>
<h2><a name="head">NMZ.head</a></h2>
<p>
Header of search results.
</p>
<h2><a name="foot">NMZ.foot</a></h2>
<p>
Footer of search results.
</p>
<h2><a name="body">NMZ.body</a></h2>
<p>
Query description. Displayed when no keyword is given.
</p>
<h2><a name="tips">NMZ.tips</a></h2>
<p>
Tips for searching. Displayed when no document is retrieved.
</p>
<h2><a name="log">NMZ.log</a></h2>
<p>
Log file of index updating.
</p>
<h2><a name="lock">NMZ.lock</a></h2>
<p>
Lock file to prevent searching.
</p>
<h2><a name="lock2">NMZ.lock2</a></h2>
<p>
Lock file to prevent updating/making the same index
simultaneously.
</p>
<h2><a name="slog">NMZ.slog</a></h2>
<p>
Log file for searched keywords.
</p>
<h3>Note</h3>
<ul>
<li>Do not lock when writing.
</ul>
<hr>
<p>
<a href="http://www.namazu.org/">Namazu Homepage</a>
</p>
<div class="copyright">
Copyright (C) 2000-2008 Namazu Project. All rights reserved.
</div>
<div class="id">
$Id: nmz.html,v 1.10.8.8 2008-03-04 20:57:16 opengl2772 Exp $
</div>
<address>
developers@namazu.org
</address>
</body>
</html>
|