edbb914b829419f454e036554cedfae57b3b0ee4
[platform/upstream/mtools.git] / mpartition.1
1 '\" t
2 .TH mpartition 1 "29Jun11" mtools-4.0.17
3 .SH Name
4 mpartition - partition an MSDOS hard disk
5 '\" t
6 .de TQ
7 .br
8 .ns
9 .TP \\$1
10 ..
11
12 .tr \(is'
13 .tr \(if`
14 .tr \(pd"
15
16 .SH Note\ of\ warning
17 This manpage has been automatically generated from mtools's texinfo
18 documentation, and may not be entirely accurate or complete.  See the
19 end of this man page for details.
20 .PP
21 .SH Description
22 .PP
23 The \fR\&\f(CWmpartition\fR command is used to create MS-DOS file systems as
24 partitions.  This is intended to be used on non-Linux systems,
25 i.e. systems where fdisk and easy access to SCSI devices are not
26 available.  This command only works on drives whose partition variable
27 is set.
28 .PP
29 .ft I
30 .nf
31 \&\fR\&\f(CWmpartition\fR \fR\&\f(CW-p\fR \fIdrive\fR
32 \&\fR\&\f(CWmpartition\fR \fR\&\f(CW-r\fR \fIdrive\fR
33 \&\fR\&\f(CWmpartition\fR \fR\&\f(CW-I\fR [\fR\&\f(CW-B\fR \fIbootSector\fR] \fIdrive\fR 
34 \&\fR\&\f(CWmpartition\fR \fR\&\f(CW-a\fR \fIdrive\fR
35 \&\fR\&\f(CWmpartition\fR \fR\&\f(CW-d\fR \fIdrive\fR
36 \&\fR\&\f(CWmpartition\fR \fR\&\f(CW-c\fR [\fR\&\f(CW-s\fR \fIsectors\fR] [\fR\&\f(CW-h\fR \fIheads\fR]
37 [\fR\&\f(CW-t\fR \fIcylinders\fR] [\fR\&\f(CW-v\fR [\fR\&\f(CW-T\fR \fItype\fR] [\fR\&\f(CW-b\fR
38 \&\fIbegin\fR] [\fR\&\f(CW-l\fR length] [\fR\&\f(CW-f\fR]
39 \&\&
40 .fi
41 .ft R
42  
43 .PP
44 Mpartition supports the following operations:
45 .TP
46 \&\fR\&\f(CWp\fR\ 
47 Prints a command line to recreate the partition for the drive.  Nothing
48 is printed if the partition for the drive is not defined, or an
49 inconsistency has been detected.  If verbose (\fR\&\f(CW-v\fR) is also set,
50 prints the current partition table.
51 .TP
52 \&\fR\&\f(CWr\fR\ 
53 Removes the partition described by \fIdrive\fR.
54 .TP
55 \&\fR\&\f(CWI\fR\ 
56 Initializes the partition table, and removes all partitions.
57 .TP
58 \&\fR\&\f(CWc\fR\ 
59 Creates the partition described by \fIdrive\fR.
60 .TP
61 \&\fR\&\f(CWa\fR\ 
62 "Activates" the partition, i.e. makes it bootable.  Only one partition
63 can be bootable at a time.
64 .TP
65 \&\fR\&\f(CWd\fR\ 
66 "Deactivates" the partition, i.e. makes it unbootable.
67 .PP
68 If no operation is given, the current settings are printed.
69 .PP
70 For partition creations, the following options are available:
71 .TP
72 \&\fR\&\f(CWs\ \fIsectors\fR\&\f(CW\fR\ 
73 The number of sectors per track of the partition (which is also the
74 number of sectors per track for the whole drive).
75 .TP
76 \&\fR\&\f(CWh\ \fIheads\fR\&\f(CW\fR\ 
77 The number of heads of the partition (which is also the number of heads
78 for the whole drive).  By default, the geometry information (number of
79 sectors and heads) is figured out from neighboring partition table
80 entries, or guessed from the size.
81 .TP
82 \&\fR\&\f(CWt\ \fIcylinders\fR\&\f(CW\fR\ 
83 The number of cylinders of the partition (not the number of cylinders of
84 the whole drive.
85 .TP
86 \&\fR\&\f(CWb\ \fIbegin\fR\&\f(CW\fR\ 
87 The starting offset of the partition, expressed in sectors. If begin is
88 not given, mpartition lets the partition begin at the start of the disk
89 (partition number 1), or immediately after the end of the previous
90 partition.
91 .TP
92 \&\fR\&\f(CWl\ \fIlength\fR\&\f(CW\fR\ 
93 The size (length) of the partition, expressed in sectors.  If end is not
94 given, mpartition figures out the size from the number of sectors, heads
95 and cylinders.  If these are not given either, it gives the partition
96 the biggest possible size, considering disk size and start of the next
97 partition.
98 .PP
99 The following option is available for all operation which modify the
100 partition table:
101 .TP
102 \&\fR\&\f(CWf\fR\ 
103 Usually, before writing back any changes to the partition, mpartition
104 performs certain consistency checks, such as checking for overlaps and
105 proper alignment of the partitions.  If any of these checks fails, the
106 partition table is not changes.  The \fR\&\f(CW-f\fR allows you to override
107 these safeguards.
108 .PP
109 The following options are available for all operations:
110 .TP
111 \&\fR\&\f(CWv\fR\ 
112 Together with \fR\&\f(CW-p\fR prints the partition table as it is now (no
113 change operation), or as it is after it is modified.
114 .TP
115 \&\fR\&\f(CWvv\fR\ 
116 If the verbosity flag is given twice, mpartition will print out a
117 hexdump of the partition table when reading it from and writing it to
118 the device.
119 .PP
120 The following option is available for partition table initialization:
121 .TP
122 \&\fR\&\f(CWB\ \fIbootSector\fR\&\f(CW\fR\ 
123 Reads the template master boot record from file \fIbootSector\fR.
124 .PP
125 .SH See\ Also
126 Mtools' texinfo doc
127 .SH Viewing\ the\ texi\ doc
128 This manpage has been automatically generated from mtools's texinfo
129 documentation. However, this process is only approximative, and some
130 items, such as crossreferences, footnotes and indices are lost in this
131 translation process.  Indeed, these items have no appropriate
132 representation in the manpage format.  Moreover, not all information has
133 been translated into the manpage version.  Thus I strongly advise you to
134 use the original texinfo doc.  See the end of this manpage for
135 instructions how to view the texinfo doc.
136 .TP
137 * \ \ 
138 To generate a printable copy from the texinfo doc, run the following
139 commands:
140  
141 .nf
142 .ft 3
143 .in +0.3i
144     ./configure; make dvi; dvips mtools.dvi
145 .fi
146 .in -0.3i
147 .ft R
148 .PP
149  
150 \&\fR
151 .TP
152 * \ \ 
153 To generate a html copy,  run:
154  
155 .nf
156 .ft 3
157 .in +0.3i
158     ./configure; make html
159 .fi
160 .in -0.3i
161 .ft R
162 .PP
163  
164 \&\fRA premade html can be found at
165 \&\fR\&\f(CW\(ifhttp://www.gnu.org/software/mtools/manual/mtools.html\(is\fR
166 .TP
167 * \ \ 
168 To generate an info copy (browsable using emacs' info mode), run:
169  
170 .nf
171 .ft 3
172 .in +0.3i
173     ./configure; make info
174 .fi
175 .in -0.3i
176 .ft R
177 .PP
178  
179 \&\fR
180 .PP
181 The texinfo doc looks most pretty when printed or as html.  Indeed, in
182 the info version certain examples are difficult to read due to the
183 quoting conventions used in info.
184 .PP