Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 16 Dec 1998 06:00:36 -0800
From:      "Jordan K. Hubbard" <jkh@zippy.cdrom.com>
To:        current@FreeBSD.ORG
Subject:   disklabel baggage.
Message-ID:  <48639.913816836@zippy.cdrom.com>

next in thread | raw e-mail | index | archive | help
I'm considering the following changes to disklabel(8), keeping in mind
that nothing will prevent the -b and -s flags from overriding these
new defaults.  Comments?

Index: disklabel.8
===================================================================
RCS file: /home/ncvs/src/sbin/disklabel/disklabel.8,v
retrieving revision 1.9
diff -u -u -r1.9 disklabel.8
--- disklabel.8	1998/11/28 09:43:31	1.9
+++ disklabel.8	1998/12/16 13:42:10
@@ -251,25 +251,19 @@
 the secondary boot program.
 If the names are not explicitly given, standard boot programs will be used.
 The boot programs are located in
-.Pa /usr/mdec .
+.Pa /boot .
 The names of the programs are taken from the ``b0'' and ``b1'' parameters
 of the
 .Xr disktab 5
 entry for the disk if
 .Ar disktype
 was given and its disktab entry exists and includes those parameters.
-Otherwise, boot program names are derived from the name of the disk.
-These names are of the form
-.Pa basename Ns boot
-for the primary (or only) bootstrap, and
-.Pf boot Pa basename
-for the secondary bootstrap;
-for example,
-.Pa /usr/mdec/daboot
+Otherwise, the default boot image names are used, these being:
+.Pa /boot/boot1
 and
-.Pa /usr/mdec/bootda
-if the disk device is
-.Em da0 .
+.Pa /boot/boot2
+for the standard stage1 and stage2 boot images (details may vary
+on architectures like the Alpha, where only a single-stage boot is used).
 .Pp
 The first of the three boot-installation forms is used to install
 bootstrap code without changing the existing label.
@@ -281,8 +275,8 @@
 .Sh FILES
 .Bl -tag -width Pa -compact
 .It Pa /etc/disktab
-.It Pa /usr/mdec/ Ns Em xx Ns boot
-.It Pa /usr/mdec/boot Ns Em xx
+.It Pa /boot/
+.It Pa /boot/boot<n>
 .El
 .Sh EXAMPLES
 .Dl disklabel da0
@@ -318,9 +312,9 @@
 .Pp
 Install a new bootstrap on da0.
 The boot code comes from
-.Pa /usr/mdec/daboot
+.Pa /boot/boot1
 and possibly
-.Pa /usr/mdec/bootda .
+.Pa /boot/boot2 .
 On-disk and in-core labels are unchanged.
 .Pp
 .Dl disklabel -w -B /dev/rda0c -b newboot da2212
@@ -329,7 +323,7 @@
 The label is derived from disktab information for ``da2212'' and
 installed both in-core and on-disk.
 The bootstrap code comes from the file
-.Pa /usr/mdec/newboot .
+.Pa /boot/newboot .
 .Sh SEE ALSO
 .Xr disklabel 5 ,
 .Xr disktab 5
Index: disklabel.c
===================================================================
RCS file: /home/ncvs/src/sbin/disklabel/disklabel.c,v
retrieving revision 1.23
diff -u -u -r1.23 disklabel.c
--- disklabel.c	1998/10/23 18:57:39	1.23
+++ disklabel.c	1998/12/16 13:53:20
@@ -595,25 +595,13 @@
 		*np++ = '\0';
 
 		if (!xxboot) {
-			(void)sprintf(np, "%s/%sboot",
-				      _PATH_BOOTDIR, dkbasename);
-			if (access(np, F_OK) < 0 && dkbasename[0] == 'r')
-				dkbasename++;
-			xxboot = np;
-			(void)sprintf(xxboot, "%s/%sboot",
-				      _PATH_BOOTDIR, dkbasename);
-			np += strlen(xxboot) + 1;
+			(void)sprintf(boot0, "%s/boot1", _PATH_BOOTDIR);
+			xxboot = boot0;
 		}
 #if NUMBOOT > 1
 		if (!bootxx) {
-			(void)sprintf(np, "%s/boot%s",
-				      _PATH_BOOTDIR, dkbasename);
-			if (access(np, F_OK) < 0 && dkbasename[0] == 'r')
-				dkbasename++;
-			bootxx = np;
-			(void)sprintf(bootxx, "%s/boot%s",
-				      _PATH_BOOTDIR, dkbasename);
-			np += strlen(bootxx) + 1;
+			(void)sprintf(boot1, "%s/boot2", _PATH_BOOTDIR);
+			bootxx = boot1;
 		}
 #endif
 	}
Index: pathnames.h
===================================================================
RCS file: /home/ncvs/src/sbin/disklabel/pathnames.h,v
retrieving revision 1.1.1.1
diff -u -u -r1.1.1.1 pathnames.h
--- pathnames.h	1994/05/26 06:34:01	1.1.1.1
+++ pathnames.h	1998/12/16 13:42:28
@@ -35,6 +35,6 @@
 
 #include <paths.h>
 
-#define	_PATH_BOOTDIR	"/usr/mdec"
+#define	_PATH_BOOTDIR	"/boot"
 #undef _PATH_TMP
 #define	_PATH_TMP	"/tmp/EdDk.aXXXXXX"


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?48639.913816836>