Merge from vendor branch LESS:
[dragonfly.git] / usr.sbin / resident / resident.8
1 .\" $DragonFly: src/usr.sbin/resident/resident.8,v 1.2 2004/01/20 21:14:00 dillon Exp $
2 .\"
3 .Dd May 21, 2003
4 .Dt RESIDENT 8
5 .Os
6 .Sh NAME
7 .Nm resident
8 .Nd Make a dynamic binary resident.
9 .Sh SYNOPSIS
10 .Nm
11 .Op Fl f
12 .Op Fl x Ar id
13 .Op Fl d
14 .Op Fl R
15 .Ar [program ...]
16 .Sh DESCRIPTION
17 The
18 .Nm
19 utility may be used to make a dynamic binary memory-resident.  This works
20 by running the binary just past its DLL mmap's and relocation and then
21 making a copy of its vmspace.  The copy is registered in the kernel and later
22 exec's of the program will cause a copy of the copy to be used.  When
23 ld-elf.so detects that it is running resident, it skips all initial library
24 loads (because they are already loaded).
25 .Pp
26 Care must be taken when using this program.  It is recommended that you
27 delete all resident registrations when updating the system shared libraries
28 and binaries.
29 .Pp
30 The following options are available:
31 .Bl -tag -width indent
32 .It Fl f
33 Force mode, even if the binary does not appear to be a dynamic binary.  This
34 way you can run resident through statically compiled wrappers.  The first
35 dynamic binary encountered in the exec chain will be operated on.
36 .It Fl x Ar id
37 Delete a registration by id.
38 .It Fl d
39 Delete a registration by program name.  If neither of the above two options
40 are specified a new registration is created.
41 .It Fl R
42 Delete all registrations in the kernel.
43 .El
44 .Sh SEE ALSO
45 .Xr ld 1 ,
46 .Xr ldd 1 ,
47 .Xr nm 1 ,
48 .Xr rtld 1
49 .Sh HISTORY