OSDN Git Service

Import translated manuals from JM CVS Repository.
[linuxjm/jm.git] / manual / reiserfsprogs / original / man8 / resize_reiserfs.8
1 .\" -*- nroff -*-
2 .\" Copyright 1996-2004 Hans Reiser.
3 .\" 
4 .TH RESIZE_REISERFS 8 "January 2004" "Reiserfsprogs-3.6.19"
5 .SH NAME
6 resize_reiserfs \- resizer tool for the ReiserFS filesystem
7 .SH SYNOPSIS
8 .BR resize_reiserfs
9 [
10 .B \-s
11 .IR \fR[\fB+\fR|\fB\- ]\fIsize\fB[\fBK\fR|\fBM\fR|\fBG\fR]
12 ] [
13 .B \-j
14 .IR \fR\fIdev
15 ] [
16 .B \-fqv
17 ]
18 .I device
19 .SH DESCRIPTION
20 The
21 .B resize_reiserfs
22 tool resizes an unmounted reiserfs file system.  It enlarges or shrinks an
23 reiserfs file system located on a
24 .I device
25 so that it will have
26 .I size
27 bytes or size=old_size +(\-)
28 .I size
29 bytes if the + or \- prefix is used.
30 If the
31 .B \-s
32 option is not specified, the filesystem will be resized to fill the
33 given device.
34 The
35 .I size
36 parameter may have one of the optional modifiers
37 .BR K ", " M ", " G ,
38 which means the
39 .I size
40 parameter is given in kilo\-, mega\-, gigabytes respectively.
41 .PP
42 The
43 .B resize_reiserfs
44 program does not manipulate the size of the device. If you wish to
45 enlarge a filesystem, you must make sure you expand the underlying
46 device first. This can be done using
47 .BR cfdisk (8)
48 for partitions, by deleting the partition and recreating it with a
49 larger size (assuming there is free space
50 .I after
51 the partition in question).  Make sure you re\-create it with the
52 same starting disk cylinder as before!  Otherwise, the resize operation
53 will certainly not work, and you may lose your entire filesystem.
54 .PP
55 The
56 .B resize_reiserfs
57 program allows to grow a reiserfs on-line if there is a free
58 space on block
59 .I device.
60
61 .PP
62 If you wish to shrink a reiserfs partition, first use
63 .B resize_reiserfs
64 to shrink the file system. You may then use
65 .BR cfdisk (8)
66 to shrink the device. When shrinking the size of the device, make sure
67 you do not make it smaller than the reduced size of the reiserfs filesystem.
68
69 .SH OPTIONS
70 .TP
71 .BR \-s\ [+|\-]\fIsize
72 Set the new size in bytes.
73 .TP
74 .BR \-j\ \fIdev
75 Set the journal device name.
76 .TP 
77 .BR \-f
78 Force, do not perform checks.
79 .TP
80 .BR \-q
81 Do not print anything but error messages.
82 .TP
83 .BR \-v 
84 Turn on extra progress status messages (default).
85
86 .SH RETURN VALUES
87 0       Resizing successful.
88 .TP
89 \-1     Resizing not successful.
90
91 .SH EXAMPLES
92 The following example shows how to test
93 .B resize_reiserfs\fR.
94 Suppose 2Gb reiserfs filesystem is created on the device /dev/hda8
95 and is mounted on /mnt. 
96 For shrinking the device we need to unmount it first, then run
97 .B resize_reiserfs
98 with a
99 .I size \fR parameter (in this case -1Gb):
100 .PP
101 \       df
102 .br
103 \       umount /mnt
104 .br
105 \       resize_reiserfs -s -1G /dev/hda8
106 .br
107 \       mount /dev/hda8 /mnt
108 .br
109 \       df /mnt
110
111 .SH AUTHOR
112 This version of
113 .B resize_reiserfs
114 has been written by Alexander Zarochentcev <zam@namesys.com>.
115 .SH BUGS
116 Please report bugs to the ReiserFS developers <reiserfs-dev@namesys.com>, providing
117 as much information as possible--your hardware, kernel, patches, settings, all printed
118 messages; check the syslog file for any related information.
119 .SH SEE ALSO
120 .BR cfdisk (8),
121 .BR reiserfsck (8),
122 .BR debugreiserfs (8)