]> git.ipfire.org Git - thirdparty/util-linux.git/blame - disk-utils/swaplabel.8
su: use lib/pty-session.c code for --pty
[thirdparty/util-linux.git] / disk-utils / swaplabel.8
CommitLineData
4dddc2d4
JB
1.\" Copyright 2010 Jason Borden <jborden@bluehost.com>
2.\"
3.\" This file may be copied under the terms of the GNU Public License.
4.\"
232dc924 5.TH SWAPLABEL 8 "April 2010" "util-linux" "System Administration"
4dddc2d4 6.SH NAME
232dc924 7swaplabel \- print or change the label or UUID of a swap area
4dddc2d4
JB
8.SH SYNOPSIS
9.B swaplabel
10.RB [ \-L
11.IR label ]
12.RB [ \-U
13.IR UUID ]
14.I device
15.SH DESCRIPTION
16.B swaplabel
232dc924 17will display or change the label or UUID of a swap partition located on
46b11619 18.I device
4dddc2d4
JB
19(or regular file).
20.PP
21If the optional arguments
46b11619 22.B \-L
4dddc2d4 23and
46b11619 24.B \-U
449a215f 25are not given,
4dddc2d4 26.B swaplabel
449a215f 27will simply display the current swap-area label and UUID of
4dddc2d4
JB
28.IR device .
29.PP
30If an optional argument is present, then
31.B swaplabel
449a215f 32will change the appropriate value on
4dddc2d4
JB
33.IR device .
34These values can also be set during swap creation using
35.BR mkswap (8).
36The
37.B swaplabel
449a215f 38utility allows to change the label or UUID on an actively used swap device.
4dddc2d4 39.SH OPTIONS
449a215f
BS
40.TP
41.BR \-h , " \-\-help"
42Display help text and exit.
43.TP
44.BR \-L , " \-\-label " \fIlabel\fR
45Specify a new \fIlabel\fR for the device.
4dddc2d4 46Swap partition labels can be at most 16 characters long. If
449a215f 47.I label
4dddc2d4 48is longer than 16 characters,
449a215f 49.B swaplabel
4dddc2d4 50will truncate it and print a warning message.
449a215f
BS
51.TP
52.BR \-U , " \-\-uuid " \fIUUID\fR
53Specify a new \fIUUID\fR for the device.
54The \fI UUID\fR
16493c3e 55must be in the standard 8-4-4-4-12 character format, such as is output by
b2cc2a7f 56.BR uuidgen (1).
4dddc2d4
JB
57.PP
58.SH AUTHOR
59.B swaplabel
60was written by Jason Borden <jborden@bluehost.com> and Karel Zak <kzak@redhat.com>.
ddfeda98 61.SH ENVIRONMENT
68e422ec
KZ
62.IP LIBBLKID_DEBUG=all
63enables libblkid debug output.
4dddc2d4 64.SH AVAILABILITY
449a215f 65The swaplabel command is part of the util-linux package and is available from
d673b74e 66https://www.kernel.org/pub/linux/utils/util-linux/.
4dddc2d4 67.SH SEE ALSO
f053ff1e 68.BR uuidgen (1),
4dddc2d4 69.BR mkswap (8),
f053ff1e 70.BR swapon (8)