There is value in ensuring that manual page sections use consistently named sections, as far as possible, and also that sections have a consistent order within manual pages. This is one of a series of patches to place manual page sections in a consistent order. In this patch, we ensure that the AUTHORS, COPYRIGHT, SEE ALSO, and AVAILABILITY sections are always placed at the end of the page. Testing that no gross editing mistake (causing accidental loss or addition of text) was performed as follows: $ cat $(grep '\.SH' -l $(find . -name '*.[1-9]') |sort) | sort > a [Apply patch] $ cat $(grep '\.SH' -l $(find . -name '*.[1-9]') |sort) | sort > b $ diff a b $ echo $? 0 Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
61 lines
1.4 KiB
Groff
61 lines
1.4 KiB
Groff
.\" Karel Zak <kzak@redhat.com>
|
|
.TH SWITCH_ROOT 8 "June 2009" "util-linux" "System Administration"
|
|
.SH NAME
|
|
switch_root \- switch to another filesystem as the root of the mount tree
|
|
.SH SYNOPSIS
|
|
.B switch_root
|
|
.RB [ \-hV ]
|
|
.LP
|
|
.B switch_root
|
|
.I newroot
|
|
.I init
|
|
.RI [ arg ...]
|
|
.SH DESCRIPTION
|
|
.B switch_root
|
|
moves already mounted /proc, /dev, /sys and /run to
|
|
.I newroot
|
|
and makes
|
|
.I newroot
|
|
the new root filesystem and starts
|
|
.I init
|
|
process.
|
|
|
|
.B WARNING: switch_root removes recursively all files and directories on the current root filesystem.
|
|
|
|
.SH OPTIONS
|
|
.IP "\fB\-h, \-\-help\fP"
|
|
Display help text and exit.
|
|
.IP "\fB\-V, \-\-version\fP"
|
|
Display version information and exit.
|
|
|
|
.SH EXIT STATUS
|
|
.B switch_root
|
|
returns 0 on success and 1 on failure.
|
|
|
|
.SH NOTES
|
|
switch_root will fail to function if
|
|
.B newroot
|
|
is not the root of a mount. If you want to switch root into a directory that
|
|
does not meet this requirement then you can first use a bind-mounting trick to
|
|
turn any directory into a mount point:
|
|
.sp
|
|
.nf
|
|
.RS
|
|
mount --bind $DIR $DIR
|
|
.RE
|
|
.fi
|
|
|
|
.SH AUTHORS
|
|
.nf
|
|
Peter Jones <pjones@redhat.com>
|
|
Jeremy Katz <katzj@redhat.com>
|
|
Karel Zak <kzak@redhat.com>
|
|
.fi
|
|
.SH SEE ALSO
|
|
.BR chroot (2),
|
|
.BR init (8),
|
|
.BR mkinitrd (8),
|
|
.BR mount (8)
|
|
.SH AVAILABILITY
|
|
The switch_root command is part of the util-linux package and is available from
|
|
https://www.kernel.org/pub/linux/utils/util-linux/.
|