1.\" Copyright (c) 2005 Michael Bushkov <bushman@rsu.ru>
2.\" All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\" notice, this list of conditions and the following disclaimer.
9.\" 2. Redistributions in binary form must reproduce the above copyright
10.\" notice, this list of conditions and the following disclaimer in the
11.\" documentation and/or other materials provided with the distribution.
12.\"
13.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23.\" SUCH DAMAGE.
24.\"
25.\" $FreeBSD: head/usr.sbin/nscd/nscd.8 158135 2006-04-29 01:34:03Z trhodes $
26.\"
27.Dd October 20, 2005
28.Dt CACHED 8
29.Os
30.Sh NAME
31.Nm cached
32.Nd "caching server daemon"
33.Sh SYNOPSIS
34.Nm
35.Op Fl nst
36.Op Fl i Ar cachename
37.Op Fl I Ar cachename
38.Sh DESCRIPTION
39.Nm
40is the system caching daemon.
41It can cache almost all types of data and is basically intended to be used
42with the
43.Pa nsswitch
44subsystem.
45The cache is actually per-user.
46This means that each user can work only with the
47cached data that was cached locally and cannot poison the cache of other users.
48The
49.Nm
50utility supports two types of caching:
51.Bl -tag -width Pair
52.It Sy Type
53.Sy Description
54.It Common caching
55Each cached element is the the key+value pair.
56This type of caching supports policies which are applied when maximum
57number of cached elements is exceeded.
58Three policies are available:
59.Pa FIFO
60(first in - first out),
61.Pa LRU
62(least recently used) and
63.Pa LFU
64(least frequently used).
65This type of caching is used with the
66.Fn getXXXbyname
67family of functions.
68.It Multipart caching
69Each cached element is the part of the elements sequence.
70This type of caching is intended to be used with the
71.Fn getXXXent
72family of functions.
73.El
74.Pp
75The
76.Nm
77utility is able not only to cache elements, but to perform the actual nsswitch
78lookups by itself.
79To enable this feature use the
80.Pa perform-actual-lookups
81parameter in the
82.Xr cached.conf 5
83.Pp
84The
85.Nm
86utility recognizes the following runtime options:
87.Bl -tag -width indent
88.It Fl n
89Do not daemonize.
90.Nm
91will not fork or disconnect itself from the terminal.
92.It Fl s
93Single-threaded mode.
94Forces using only one thread for all processing purposes (it overrides
95the
96.Pa threads
97parameter in the
98.Xr cached.conf 5
99file).
100.It Fl t
101Trace mode.
102All trace messages will be written to stdout.
103This mode is usually used with
104.Fl n
105and
106.Fl s
107flags are used for debugging purposes.
108.It Fl i Ar cachename
109Invalidates personal cache.
110When specified,
111.Nm
112acts as the administration tool.
113It asks the already running
114.Nm
115to invalidate the specified part of the cache of the
116calling user.
117For example, sometimes you may want to invalidate your
118.Pa hosts
119cache.
120You can specify
121.Pa all
122as the
123.Pa cachename
124to invalidate your personal cache as a whole.
125You cannot use this option for the cachename, for which
126the
127.Pa perform-actual-lookups
128option is enabled.
129.It Fl I Ar cachename
130Invalidates the cache for every user.
131When specified,
132.Nm
133acts as the administration tool.
134It asks the already
135running
136.Nm
137to invalidate the specified part of the cache for
138every user.
139You can specify
140.Pa all
141as the
142.Pa cachename
143to invalidate the whole cache.
144Only the root can use this option.
145.El
146.Sh FILES
147.Xr cached.conf 5
148.Sh SEE ALSO
149.Xr cached.conf 5
150.Xr nsswitch.conf 5
151.Xr nsdispatch 3
152.Sh "AUTHORS"
153.An Michael Bushkov Aq bushman@rsu.ru
154.Sh "BUGS"
155To report bugs or suggestions please mail me:
156.Aq bushman@rsu.ru
2.\" All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\" notice, this list of conditions and the following disclaimer.
9.\" 2. Redistributions in binary form must reproduce the above copyright
10.\" notice, this list of conditions and the following disclaimer in the
11.\" documentation and/or other materials provided with the distribution.
12.\"
13.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23.\" SUCH DAMAGE.
24.\"
25.\" $FreeBSD: head/usr.sbin/nscd/nscd.8 158135 2006-04-29 01:34:03Z trhodes $
26.\"
27.Dd October 20, 2005
28.Dt CACHED 8
29.Os
30.Sh NAME
31.Nm cached
32.Nd "caching server daemon"
33.Sh SYNOPSIS
34.Nm
35.Op Fl nst
36.Op Fl i Ar cachename
37.Op Fl I Ar cachename
38.Sh DESCRIPTION
39.Nm
40is the system caching daemon.
41It can cache almost all types of data and is basically intended to be used
42with the
43.Pa nsswitch
44subsystem.
45The cache is actually per-user.
46This means that each user can work only with the
47cached data that was cached locally and cannot poison the cache of other users.
48The
49.Nm
50utility supports two types of caching:
51.Bl -tag -width Pair
52.It Sy Type
53.Sy Description
54.It Common caching
55Each cached element is the the key+value pair.
56This type of caching supports policies which are applied when maximum
57number of cached elements is exceeded.
58Three policies are available:
59.Pa FIFO
60(first in - first out),
61.Pa LRU
62(least recently used) and
63.Pa LFU
64(least frequently used).
65This type of caching is used with the
66.Fn getXXXbyname
67family of functions.
68.It Multipart caching
69Each cached element is the part of the elements sequence.
70This type of caching is intended to be used with the
71.Fn getXXXent
72family of functions.
73.El
74.Pp
75The
76.Nm
77utility is able not only to cache elements, but to perform the actual nsswitch
78lookups by itself.
79To enable this feature use the
80.Pa perform-actual-lookups
81parameter in the
82.Xr cached.conf 5
83.Pp
84The
85.Nm
86utility recognizes the following runtime options:
87.Bl -tag -width indent
88.It Fl n
89Do not daemonize.
90.Nm
91will not fork or disconnect itself from the terminal.
92.It Fl s
93Single-threaded mode.
94Forces using only one thread for all processing purposes (it overrides
95the
96.Pa threads
97parameter in the
98.Xr cached.conf 5
99file).
100.It Fl t
101Trace mode.
102All trace messages will be written to stdout.
103This mode is usually used with
104.Fl n
105and
106.Fl s
107flags are used for debugging purposes.
108.It Fl i Ar cachename
109Invalidates personal cache.
110When specified,
111.Nm
112acts as the administration tool.
113It asks the already running
114.Nm
115to invalidate the specified part of the cache of the
116calling user.
117For example, sometimes you may want to invalidate your
118.Pa hosts
119cache.
120You can specify
121.Pa all
122as the
123.Pa cachename
124to invalidate your personal cache as a whole.
125You cannot use this option for the cachename, for which
126the
127.Pa perform-actual-lookups
128option is enabled.
129.It Fl I Ar cachename
130Invalidates the cache for every user.
131When specified,
132.Nm
133acts as the administration tool.
134It asks the already
135running
136.Nm
137to invalidate the specified part of the cache for
138every user.
139You can specify
140.Pa all
141as the
142.Pa cachename
143to invalidate the whole cache.
144Only the root can use this option.
145.El
146.Sh FILES
147.Xr cached.conf 5
148.Sh SEE ALSO
149.Xr cached.conf 5
150.Xr nsswitch.conf 5
151.Xr nsdispatch 3
152.Sh "AUTHORS"
153.An Michael Bushkov Aq bushman@rsu.ru
154.Sh "BUGS"
155To report bugs or suggestions please mail me:
156.Aq bushman@rsu.ru