1.\" Copyright (c) 1993
2.\"	The Regents of the University of California.  All rights reserved.
3.\"
4.\" %sccs.include.redist.roff%
5.\"
6.\"	@(#)lfs_cleanerd.8	8.1 (Berkeley) 06/05/93
7.\"
8.Dd ""
9.Dt LFS_CLEANERD 8
10.Os BSD 4.4
11.Sh NAME
12.Nm lfs_cleanerd
13.Nd garbage collect a log-structured file system
14.Sh SYNOPSIS
15.Nm lfs_cleanerd
16.Op Fl ds
17.Pa node
18.Sh DESCRIPTION
19The
20.Nm lfs_cleanerd
21command starts a daemon process which garbage-collects
22the log-structed file system residing at the point named by
23.Ar node
24in the global file system namespace.
25This command is normally executed by
26.Xr mount_lfs 8
27when the log-structured file system is mounted.
28The daemon will exit within a few minutes
29of when the file system it was cleaning is unmounted.
30.Pp
31Garbage collection on a log-structured file system is done by scanning
32the file system's segments for active, i.e. referenced, data and copying
33it to new segments.
34When all of the active data in a given segment has been copied to a new
35segment that segment can be marked as empty, thus reclaiming the space
36taken by the inactive data which was in it.
37.Pp
38The following options are available:
39.Bl -tag -width indent
40.It Fl d
41Run in debug mode.
42Do not become a daemon process, and print debugging information.
43.It Fl s
44When cleaning the file system, read data in small chunks.
45.El
46.Sh SEE ALSO
47.Xr mount_lfs 8
48.Sh HISTORY
49The
50.Nm lfs_cleanerd
51utility first appeared in 4.4BSD.
52