Date: Wed, 7 May 2003 22:32:10 +0200 From: "Simon L. Nielsen" <simon@nitro.dk> To: Marc Fonvieille <blackend@FreeBSD.org> Cc: freebsd-doc@FreeBSD.org Subject: Re: docs/51897: Add example for disklable for md devices Message-ID: <20030507203210.GA4230@nitro.dk> In-Reply-To: <20030507183649.GA532@nosferatu.blackend.org> References: <200305070010.h470A6gY099125@freefall.freebsd.org> <20030507093401.A97412@abigail.blackend.org> <20030507085847.GA394@nitro.dk> <20030507183649.GA532@nosferatu.blackend.org>
next in thread | previous in thread | raw e-mail | index | archive | help
--VrqPEDrXMn8OVzN4 Content-Type: multipart/mixed; boundary="AqsLC8rIMeq19msA" Content-Disposition: inline --AqsLC8rIMeq19msA Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2003.05.07 20:36:49 +0200, Marc Fonvieille wrote: > On Wed, May 07, 2003 at 10:58:48AM +0200, Simon L. Nielsen wrote: > > case 'r': > > /* > > * We accept and ignode -r for compatibility with > > * historically disklabel usage. > > */ > > break; > >=20 > > I would rather say that the rest of the docs should be change not to use > > '-r' and 'auto' and perhaps add a compatibility note for FreeBSD < 5.0. > >=20 >=20 > You meant 5.1 I think. > In the Handbook I would write that -r and auto options can be safely > omitted on FreeBSD 5.1 and later. I actually meant 5.0 but after searching the archives and it looks like phk has said -r should it be used to write the first label (before disklabel(8) -> bsdlabel(8)). So I think your suggestion about a note for >=3D 5.1 is right but I think the mdconfig man page should only note the new form, right ? Anyway just did a quick grep for disklabel in the handbook and added a note about the options to the main places I found disklabel to be referenced. Patch should be attached. What do you think of this approch? Btw. I don't know the policy about repeating a note like this so I just added it all the places I found since it is simpler for you to remove it if it shouldn't be there than the over way around. Btww. I noticed that in another example the arguments were given in a different way so the patch also brings them in line to be more consistent. --=20 Simon L. Nielsen --AqsLC8rIMeq19msA Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="doc-handbook-disklabel51.patch" Content-Transfer-Encoding: quoted-printable Index: disks/chapter.sgml =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /home/ncvs/doc/en_US.ISO8859-1/books/handbook/disks/chapter.sgml,v retrieving revision 1.157 diff -u -d -r1.157 chapter.sgml --- disks/chapter.sgml 5 May 2003 19:36:10 -0000 1.157 +++ disks/chapter.sgml 7 May 2003 20:28:01 -0000 @@ -297,6 +297,15 @@ &prompt.root; <userinput>mount /dev/da1s1e /1</userinput> # Mount the part= ition(s) &prompt.root; <userinput>vi /etc/fstab</userinput> # Add the appropriate e= ntry/entries to your <filename>/etc/fstab</filename>.</screen> =20 + <note> + <para>If you are using &os; 5.1 or newer the + &man.disklabel.8; arguments <option>-r</option> and + <option>auto</option> can be ommited so the command can + simply be : + </para> + <screen>&prompt.root; <userinput>disklabel -B -w da1s1</userinput></scr= een> + </note> + <para>If you have an IDE disk, substitute <filename>ad</filename> for <filename>da</filename>. On pre-4.X systems use <filename>wd</filename>.</para> @@ -314,7 +323,7 @@ understand.</para> =09 <screen>&prompt.root; <userinput>dd if=3D/dev/zero of=3D/dev/da1 bs=3D1k = count=3D1</userinput> -&prompt.root; <userinput>disklabel -Brw da1 auto</userinput> +&prompt.root; <userinput>disklabel -B -r -w da1 auto</userinput> &prompt.root; <userinput>disklabel -e da1</userinput> # create the `e' = partition &prompt.root; <userinput>newfs -d0 /dev/da1e</userinput> &prompt.root; <userinput>mkdir -p /1</userinput> @@ -324,7 +333,7 @@ <para>An alternate method is:</para> =20 <screen>&prompt.root; <userinput>dd if=3D/dev/zero of=3D/dev/da1 count=3D= 2</userinput> -&prompt.root; <userinput>disklabel /dev/da1 | disklabel -BrR da1 /dev/stdi= n</userinput> +&prompt.root; <userinput>disklabel /dev/da1 | disklabel -B -r -R da1 /dev/= stdin</userinput> &prompt.root; <userinput>newfs /dev/da1e</userinput> &prompt.root; <userinput>mkdir -p /1</userinput> &prompt.root; <userinput>vi /etc/fstab</userinput> # add an entry for = /dev/da1e @@ -446,6 +455,13 @@ disklabel -r -w ad2 auto disklabel -r -w ad3 auto</programlisting> =20 + <note> + <para>If you are using &os; 5.1 or newer the + <command>disklabel</command> arguments + <option>-r</option> and <option>auto</option> can be + ommited.</para> + </note> + <para>This creates a disklabel for ad1c, ad2c and ad3c that spans the entire disk.</para> =20 @@ -2284,6 +2300,14 @@ Filesystem 1K-blocks Used Avail Capacity Mounted on /dev/md0c 4846 2 4458 0% /mnt</screen> </example> + + <note> + <para>If you are using &os; 5.1 or newer the &man.disklabel.8; + arguments <option>-r</option> and <option>auto</option> can + be ommited so the command can simply be : + </para> + <screen>&prompt.root; <userinput>disklabel -w md<replaceable>0</replaceab= le></userinput></screen> + </note> =20 <para>If you do not specify the unit number with the <option>-u</option> option, &man.mdconfig.8; will use the --AqsLC8rIMeq19msA-- --VrqPEDrXMn8OVzN4 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (FreeBSD) iD8DBQE+uW1K8kocFXgPTRwRAiFyAJ46Y2C9mMDqONvSRsJmtdX6MQlIhwCeNVNE clnrB9h+eafrTIDCI496gbw= =WZFZ -----END PGP SIGNATURE----- --VrqPEDrXMn8OVzN4--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030507203210.GA4230>