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 158155 2006-04-30 01:53:57Z 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 were cached by themsevles, and cannot poison the
48cache of other users.
49The
50.Nm
51utility supports two types of caching:
52.Bl -tag -width Pair
53.It Sy Type
54.Sy Description
55.It Common caching
56Each cached element is the the key+value pair.
57This type of caching supports policies which are applied when maximum
58number of cached elements is exceeded.
59Three policies are available:
60.Pa FIFO
61(first in - first out),
62.Pa LRU
63(least recently used) and
64.Pa LFU
65(least frequently used).
66This type of caching is used with the
67.Fn getXXXbyname
68family of functions.
69.It Multipart caching
70Each cached element is the part of the elements sequence.
71This type of caching is intended to be used with the
72.Fn getXXXent
73family of functions.
74.El
75.Pp
76The
77.Nm
78utility is able not only to cache elements, but to perform the actual nsswitch
79lookups by itself.
80To enable this feature use the
81.Pa perform-actual-lookups
82parameter in the
83.Xr cached.conf 5
84.Pp
85The
86.Nm
87utility recognizes the following runtime options:
88.Bl -tag -width indent
89.It Fl n
90Do not daemonize.
91.Nm
92will not fork or disconnect itself from the terminal.
93.It Fl s
94Single-threaded mode.
95Forces using only one thread for all processing purposes (it overrides
96the
97.Pa threads
98parameter in the
99.Xr cached.conf 5
100file).
101.It Fl t
102Trace mode.
103All trace messages will be written to stdout.
104This mode is usually used with
105.Fl n
106and
107.Fl s
108flags are used for debugging purposes.
109.It Fl i Ar cachename
110Invalidates personal cache.
111When specified,
112.Nm
113acts as the administration tool.
114It asks the already running
115.Nm
116to invalidate the specified part of the cache of the
117calling user.
118For example, sometimes you may want to invalidate your
119.Pa hosts
120cache.
121You can specify
122.Pa all
123as the
124.Pa cachename
125to invalidate your personal cache as a whole.
126You cannot use this option for the cachename, for which
127the
128.Pa perform-actual-lookups
129option is enabled.
130.It Fl I Ar cachename
131Invalidates the cache for every user.
132When specified,
133.Nm
134acts as the administration tool.
135It asks the already
136running
137.Nm
138to invalidate the specified part of the cache for
139every user.
140You can specify
141.Pa all
142as the
143.Pa cachename
144to invalidate the whole cache.
145Only the root can use this option.
146.El
147.Sh FILES
148.Xr cached.conf 5
149.Sh SEE ALSO
150.Xr cached.conf 5
151.Xr nsswitch.conf 5
152.Xr nsdispatch 3
153.Sh "AUTHORS"
154.An Michael Bushkov Aq bushman@rsu.ru
155.Sh "BUGS"
156To report bugs or suggestions please mail me:
157.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 158155 2006-04-30 01:53:57Z 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 were cached by themsevles, and cannot poison the
48cache of other users.
49The
50.Nm
51utility supports two types of caching:
52.Bl -tag -width Pair
53.It Sy Type
54.Sy Description
55.It Common caching
56Each cached element is the the key+value pair.
57This type of caching supports policies which are applied when maximum
58number of cached elements is exceeded.
59Three policies are available:
60.Pa FIFO
61(first in - first out),
62.Pa LRU
63(least recently used) and
64.Pa LFU
65(least frequently used).
66This type of caching is used with the
67.Fn getXXXbyname
68family of functions.
69.It Multipart caching
70Each cached element is the part of the elements sequence.
71This type of caching is intended to be used with the
72.Fn getXXXent
73family of functions.
74.El
75.Pp
76The
77.Nm
78utility is able not only to cache elements, but to perform the actual nsswitch
79lookups by itself.
80To enable this feature use the
81.Pa perform-actual-lookups
82parameter in the
83.Xr cached.conf 5
84.Pp
85The
86.Nm
87utility recognizes the following runtime options:
88.Bl -tag -width indent
89.It Fl n
90Do not daemonize.
91.Nm
92will not fork or disconnect itself from the terminal.
93.It Fl s
94Single-threaded mode.
95Forces using only one thread for all processing purposes (it overrides
96the
97.Pa threads
98parameter in the
99.Xr cached.conf 5
100file).
101.It Fl t
102Trace mode.
103All trace messages will be written to stdout.
104This mode is usually used with
105.Fl n
106and
107.Fl s
108flags are used for debugging purposes.
109.It Fl i Ar cachename
110Invalidates personal cache.
111When specified,
112.Nm
113acts as the administration tool.
114It asks the already running
115.Nm
116to invalidate the specified part of the cache of the
117calling user.
118For example, sometimes you may want to invalidate your
119.Pa hosts
120cache.
121You can specify
122.Pa all
123as the
124.Pa cachename
125to invalidate your personal cache as a whole.
126You cannot use this option for the cachename, for which
127the
128.Pa perform-actual-lookups
129option is enabled.
130.It Fl I Ar cachename
131Invalidates the cache for every user.
132When specified,
133.Nm
134acts as the administration tool.
135It asks the already
136running
137.Nm
138to invalidate the specified part of the cache for
139every user.
140You can specify
141.Pa all
142as the
143.Pa cachename
144to invalidate the whole cache.
145Only the root can use this option.
146.El
147.Sh FILES
148.Xr cached.conf 5
149.Sh SEE ALSO
150.Xr cached.conf 5
151.Xr nsswitch.conf 5
152.Xr nsdispatch 3
153.Sh "AUTHORS"
154.An Michael Bushkov Aq bushman@rsu.ru
155.Sh "BUGS"
156To report bugs or suggestions please mail me:
157.Aq bushman@rsu.ru