diff options
-rw-r--r-- | distrib/alpha/common/install.md | 15 | ||||
-rw-r--r-- | distrib/amiga/install.md | 18 | ||||
-rw-r--r-- | distrib/hp300/ramdisk/install.md | 37 | ||||
-rw-r--r-- | distrib/i386/floppies/common/install.md | 32 | ||||
-rw-r--r-- | distrib/mac68k/ramdisk/install.md | 7 | ||||
-rw-r--r-- | distrib/macppc/ramdisk/install.md | 76 | ||||
-rw-r--r-- | distrib/mvme68k/ramdisk/install.md | 32 | ||||
-rw-r--r-- | distrib/mvme88k/ramdisk/install.md | 22 | ||||
-rw-r--r-- | distrib/mvmeppc/ramdisk/install.md | 86 | ||||
-rw-r--r-- | distrib/sparc/install.md | 34 | ||||
-rw-r--r-- | distrib/sparc64/common/install.md | 39 | ||||
-rw-r--r-- | distrib/sun3/install.md | 34 | ||||
-rw-r--r-- | distrib/vax/install.md | 16 |
13 files changed, 175 insertions, 273 deletions
diff --git a/distrib/alpha/common/install.md b/distrib/alpha/common/install.md index 3ccf7d8b1ce..674195921e0 100644 --- a/distrib/alpha/common/install.md +++ b/distrib/alpha/common/install.md @@ -1,4 +1,4 @@ -# $OpenBSD: install.md,v 1.3 2001/12/23 01:51:52 krw Exp $ +# $OpenBSD: install.md,v 1.4 2002/03/31 17:30:30 deraadt Exp $ # # Copyright (c) 1996 The NetBSD Foundation, Inc. # All rights reserved. @@ -34,15 +34,13 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script. # -ARCH=ARCH - # Machine-dependent install sets MDSETS=kernel +ARCH=ARCH md_set_term() { test -n "$TERM" && return @@ -126,14 +124,11 @@ md_prep_disklabel() md_checkfordisklabel $_disk case $? in - 0) - ;; - 1) - echo WARNING: Disk $_disk has no label. You will be creating a new one. + 0) ;; + 1) echo WARNING: Disk $_disk has no label. You will be creating a new one. echo ;; - 2) - echo WARNING: Label on disk $_disk is corrupted. You will be repairing. + 2) echo WARNING: Label on disk $_disk is corrupted. You will be repairing. echo ;; esac diff --git a/distrib/amiga/install.md b/distrib/amiga/install.md index 70f47b16812..e2ffc9895ec 100644 --- a/distrib/amiga/install.md +++ b/distrib/amiga/install.md @@ -1,4 +1,4 @@ -# $OpenBSD: install.md,v 1.11 2002/02/14 03:34:14 deraadt Exp $ +# $OpenBSD: install.md,v 1.12 2002/03/31 17:30:30 deraadt Exp $ # $NetBSD: install.md,v 1.3.2.5 1996/08/26 15:45:28 gwr Exp $ # # @@ -36,13 +36,12 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script. # # Machine-dependent install sets -MDSETS="kernel" +MDSETS=kernel ARCH=ARCH md_set_term() { @@ -66,8 +65,8 @@ md_get_cddevs() { } md_get_partition_range() { - # return range of valid partition letters - echo "[a-p]" + # return range of valid partition letters + echo "[a-p]" } md_questions() { @@ -110,14 +109,11 @@ md_prep_disklabel() _disk=$1 md_checkfordisklabel $_disk case $? in - 0) - ;; - 1) - echo "ERROR: Disk $_disk is not partitioned, read the" + 0) ;; + 1) echo "ERROR: Disk $_disk is not partitioned, read the" echo "preparation document on how to go about doing this." ;; - 2) - echo "WARNING: Label on disk $_disk is corrupted. Maybe" + 2) echo "WARNING: Label on disk $_disk is corrupted. Maybe" echo "you should interrupt the install process and recheck" echo "your disk partitioning in AmigaOS?" ;; diff --git a/distrib/hp300/ramdisk/install.md b/distrib/hp300/ramdisk/install.md index 75c7e6f3725..b98b3ca070d 100644 --- a/distrib/hp300/ramdisk/install.md +++ b/distrib/hp300/ramdisk/install.md @@ -1,6 +1,6 @@ #!/bin/sh # -# $OpenBSD: install.md,v 1.23 2001/12/23 01:51:52 krw Exp $ +# $OpenBSD: install.md,v 1.24 2002/03/31 17:30:30 deraadt Exp $ # $NetBSD: install.md,v 1.1.2.4 1996/08/26 15:45:14 gwr Exp $ # # Copyright (c) 1996 The NetBSD Foundation, Inc. @@ -37,13 +37,12 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script # # Machine-dependent install sets -MDSETS="kernel" +MDSETS=kernel ARCH=ARCH md_set_term() { @@ -151,12 +150,8 @@ __scsi_label_1 echo -n "Review boot messages now? [y] " getresp "y" case "$resp" in - y*|Y*) - dmesg | less -rsS - ;; - - *) - ;; + y*|Y*) dmesg | less -rsS + ;; esac echo "" @@ -306,15 +301,12 @@ hp300_init_label_hpib_disk() { echo -n "Try a different method? [y] " getresp "y" case "$resp" in - y*|Y*) - hp300_init_label_scsi_disk $1 - return - ;; - - *) - rval="1" - return - ;; + y*|Y*) hp300_init_label_scsi_disk $1 + return + ;; + *) rval="1" + return + ;; esac fi @@ -329,14 +321,11 @@ md_prep_disklabel() _disk=$1 md_checkfordisklabel $_disk case $? in - 0) - ;; - 1) - echo "WARNING: Disk $_disk has no label. You will be creating a new one." + 0) ;; + 1) echo "WARNING: Disk $_disk has no label. You will be creating a new one." echo ;; - 2) - echo "WARNING: Label on disk $_disk is corrupted. You will be repairing." + 2) echo "WARNING: Label on disk $_disk is corrupted. You will be repairing." echo ;; esac diff --git a/distrib/i386/floppies/common/install.md b/distrib/i386/floppies/common/install.md index 15cbb4a6df6..dbaeaf05eb1 100644 --- a/distrib/i386/floppies/common/install.md +++ b/distrib/i386/floppies/common/install.md @@ -1,4 +1,4 @@ -# $OpenBSD: install.md,v 1.15 2002/02/14 03:26:05 deraadt Exp $ +# $OpenBSD: install.md,v 1.16 2002/03/31 17:30:30 deraadt Exp $ # # # Copyright (c) 1996 The NetBSD Foundation, Inc. @@ -35,7 +35,6 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script. # @@ -63,8 +62,8 @@ md_get_cddevs() { } md_get_partition_range() { - # return range of valid partition letters - echo [a-p] + # return range of valid partition letters + echo [a-p] } md_questions() { @@ -72,11 +71,9 @@ md_questions() { echo -n "Do you expect to run the X Window System? [y] " getresp y case "$resp" in - y*|Y*) - xfree86=y - ;; - *) - ;; + y*|Y*) + xfree86=y + ;; esac echo } @@ -97,11 +94,11 @@ q' | ed /mnt/etc/sysctl.conf 2> /dev/null } md_native_fstype() { - echo msdos + echo msdos } md_native_fsopts() { - echo "ro,-l" + echo "ro,-l" } md_checkfordisklabel() { @@ -167,8 +164,8 @@ md_prep_disklabel() echo -n 'Do you want to use the *entire* disk for OpenBSD? [no] ' getresp "no" case $resp in - y*|Y*) md_prep_fdisk ${_disk} Y ;; - *) md_prep_fdisk ${_disk} ;; + y*|Y*) md_prep_fdisk ${_disk} Y ;; + *) md_prep_fdisk ${_disk} ;; esac cat << __EOT @@ -184,14 +181,11 @@ __EOT md_checkfordisklabel $_disk case $? in - 0) - ;; - 1) - echo WARNING: Disk $_disk has no label. You will be creating a new one. + 0) ;; + 1) echo WARNING: Disk $_disk has no label. You will be creating a new one. echo ;; - 2) - echo WARNING: Label on disk $_disk is corrupted. You will be repairing. + 2) echo WARNING: Label on disk $_disk is corrupted. You will be repairing. echo ;; esac diff --git a/distrib/mac68k/ramdisk/install.md b/distrib/mac68k/ramdisk/install.md index 737fcc4aa1a..5b88481ada7 100644 --- a/distrib/mac68k/ramdisk/install.md +++ b/distrib/mac68k/ramdisk/install.md @@ -1,6 +1,6 @@ #!/bin/sh # -# $OpenBSD: install.md,v 1.6 2001/12/23 01:51:52 krw Exp $ +# $OpenBSD: install.md,v 1.7 2002/03/31 17:30:30 deraadt Exp $ # $NetBSD: install.md,v 1.1.2.4 1996/08/26 15:45:14 gwr Exp $ # # Copyright (c) 1996 The NetBSD Foundation, Inc. @@ -37,14 +37,13 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script # # Machine-dependent install sets -MDSETS="kernel" -ARCH= +MDSETS=kernel +ARCH=ARCH md_set_term() { echo -n "Specify terminal type [vt220]: " diff --git a/distrib/macppc/ramdisk/install.md b/distrib/macppc/ramdisk/install.md index 34a0e70e8a3..3ab5237ca97 100644 --- a/distrib/macppc/ramdisk/install.md +++ b/distrib/macppc/ramdisk/install.md @@ -1,4 +1,4 @@ -# $OpenBSD: install.md,v 1.6 2002/02/23 18:29:51 deraadt Exp $ +# $OpenBSD: install.md,v 1.7 2002/03/31 17:30:30 deraadt Exp $ # # # Copyright (c) 1996 The NetBSD Foundation, Inc. @@ -35,13 +35,12 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script. # # Machine-dependent install sets -MDSETS="kernel" +MDSETS=kernel ARCH=ARCH md_set_term() { @@ -63,8 +62,8 @@ md_get_cddevs() { } md_get_partition_range() { - # return range of valid partition letters - echo [a-p] + # return range of valid partition letters + echo [a-p] } md_questions() { @@ -72,21 +71,19 @@ md_questions() { echo -n "Do you expect to run the X Window System? [y] " getresp y case "$resp" in - y*|Y*) - xfree86=y - ;; - *) - ;; + y*|Y*) + xfree86=y + ;; esac echo } md_installboot() { - if [[ $disklabeltype = "HFS" ]] + if [[ $disklabeltype = "HFS" ]] then echo "the 'ofwboot' program needs to be copied to the first HFS partition" echo "of the disk to allow booting of OpenBSD" - elif [[ $disklabeltype = "MBR" ]] + elif [[ $disklabeltype = "MBR" ]] then echo "Installing boot in the msdos partition /dev/${1}i" if mount -t msdos /dev/${1}i /mnt2 ; then @@ -107,11 +104,11 @@ q' | ed /mnt/etc/sysctl.conf 2> /dev/null } md_native_fstype() { - echo "msdos" + echo "msdos" } md_native_fsopts() { - echo "ro" + echo "ro" } md_init_mbr() { @@ -131,10 +128,8 @@ md_init_mbr() { echo -n "Do you want to init the MBR and the MSDOS partition? [y] " getresp "y" case "$resp" in - n*|N*) - exit 0;; - *) - echo + n*|N*) exit 0;; + *) echo echo "An MBR record with an OpenBSD usable partition table will now be copied" echo "to your disk. Unless you have special requirements you will not need" echo "to edit this MBR. After the MBR is copied an empty 1MB MSDOS partition" @@ -147,7 +142,7 @@ md_init_mbr() { echo "This will take a minute or two..." sleep 2 echo -n "Creating Master Boot Record (MBR)..." - fdisk -i -f /usr/mdec/mbr $1 + fdisk -i -f /usr/mdec/mbr $1 echo "..done." echo -n "Copying 1MB MSDOS partition to disk..." gunzip < /usr/mdec/msdos1mb.gz | dd of=/dev/r$1c bs=512 seek=1 >/dev/null 2>&1 @@ -180,13 +175,11 @@ md_checkfordisklabel() { echo -n "Do you want to choose (H)FS labeling or (M)BR labeling [H] " getresp "h" case "$resp" in - m*|M*) - export disklabeltype=MBR + m*|M*) export disklabeltype=MBR md_checkforMBRdisklabel $1 rval=$? ;; - *) - export disklabeltype=HFS + *) export disklabeltype=HFS md_init_hfs $1 rval=$? ;; @@ -199,20 +192,15 @@ md_checkforMBRdisklabel() { echo -n "Is this correct? [n] " getresp "n" case "$resp" in - n*|N*) - echo "aborting install" + n*|N*) echo "aborting install" exit 0;; - *) - ;; esac echo -n "Have you initialized an MSDOS partition using OpenFirmware? [n] " getresp "n" case "$resp" in - n*|N*) - md_init_mbr $1;; - *) - echo + n*|N*) md_init_mbr $1;; + *) echo echo "You may keep your current setup if you want to be able to use any" echo "already loaded OS. However you will be asked to prepare an empty" echo "partition for OpenBSD later. There must also be at least ~0.5MB free space" @@ -224,10 +212,7 @@ md_checkforMBRdisklabel() { echo -n "Do you want to keep the current MSDOS partition setup? [y]" getresp "y" case "$resp" in - n*|N*) - md_init_mbr $1;; - *) - ;; + n*|N*) md_init_mbr $1;; esac ;; esac @@ -305,8 +290,8 @@ __md_prep_fdisk_1 getresp "n" case "$resp" in - n*|N*) ;; - *) _done=1 ;; + n*|N*) ;; + *) _done=1 ;; esac done @@ -327,16 +312,13 @@ md_prep_disklabel() _disk=$1 md_checkfordisklabel $_disk case $? in - 0) - echo -n "Do you wish to edit the disklabel on $_disk? [y] " + 0) echo -n "Do you wish to edit the disklabel on $_disk? [y] " ;; - 1) - md_prep_fdisk ${_disk} + 1) md_prep_fdisk ${_disk} echo "WARNING: Disk $_disk has no label" echo -n "Do you want to create one with the disklabel editor? [y] " ;; - 2) - echo "WARNING: Label on disk $_disk is corrupted" + 2) echo "WARNING: Label on disk $_disk is corrupted" echo -n "Do you want to try and repair the damage using the disklabel editor? [y] " ;; @@ -344,7 +326,7 @@ md_prep_disklabel() getresp "y" case "$resp" in - y*|Y*) ;; + y*|Y*) ;; *) return ;; esac @@ -352,7 +334,7 @@ md_prep_disklabel() cat << \__md_prep_disklabel_1 Disk partition sizes and offsets are in sector (most likely 512 bytes) units. -You may set these size/offset pairs on cylinder boundaries +You may set these size/offset pairs on cylinder boundaries (the number of sector per cylinder is given in ) (the `sectors/cylinder' entry, which is not shown here) Also, you *must* make sure that the 'i' partition points at the MSDOS @@ -377,10 +359,10 @@ Do not change any parameters except the partition layout and the label name. __md_prep_disklabel_1 echo -n "Press [Enter] to continue " getresp "" - if [[ $disklabeltype = "HFS" ]] + if [[ $disklabeltype = "HFS" ]] then disklabel -c -f /tmp/fstab.${_disk} -E ${_disk} - elif [[ $disklabeltype = "MBR" ]] + elif [[ $disklabeltype = "MBR" ]] then disklabel -W ${_disk} disklabel ${_disk} >/tmp/label.$$ diff --git a/distrib/mvme68k/ramdisk/install.md b/distrib/mvme68k/ramdisk/install.md index 4750424dd7f..53ce09126f0 100644 --- a/distrib/mvme68k/ramdisk/install.md +++ b/distrib/mvme68k/ramdisk/install.md @@ -1,4 +1,4 @@ -# $OpenBSD: install.md,v 1.12 2001/06/23 19:44:47 deraadt Exp $ +# $OpenBSD: install.md,v 1.13 2002/03/31 17:30:31 deraadt Exp $ # Copyright (c) 1996 The NetBSD Foundation, Inc. # All rights reserved. # @@ -33,7 +33,6 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script. # @@ -53,12 +52,10 @@ md_copy_kernel() { echo -n "Escape to shell add /mnt/bsd by hand? [y] " getresp "y" case "$resp" in - y*|Y*) - echo "Type 'exit' to return to install." - sh - ;; - *) - ;; + y*|Y*) + echo "Type 'exit' to return to install." + sh + ;; esac fi } @@ -83,8 +80,8 @@ md_get_cddevs() { dmesg | egrep -a "^cd[0-9] " | sed -e "s/[ :(].*//" | sort -u } -md_get_ifdevs() { - # return available network devices +md_get_ifdevs() { + # return available network devices dmesg | egrep "(^ie[0-9] )|(^le[0-9] )" | cut -d" " -f1 | sort -u } @@ -99,7 +96,7 @@ md_questions() { md_installboot() { local _rawdev - + echo "" echo "Installing boot blocks." @@ -122,7 +119,7 @@ md_installboot() { } md_labeldisk() { - echo "huh" + : } md_checkfordisklabel() { @@ -149,22 +146,19 @@ md_prep_disklabel() _disk=$1 md_checkfordisklabel $_disk case $? in - 0) - echo -n "Do you wish to edit the disklabel on $_disk? [y] " + 0) echo -n "Do you wish to edit the disklabel on $_disk? [y] " ;; - 1) - echo "WARNING: Disk $_disk has no label" + 1) echo "WARNING: Disk $_disk has no label" echo -n "Do you want to create one with the disklabel editor? [y] " ;; - 2) - echo "WARNING: Label on disk $_disk is corrupted" + 2) echo "WARNING: Label on disk $_disk is corrupted" echo -n "Do you want to try and repair the damage using the disklabel editor? [y] " ;; esac getresp "y" case "$resp" in - y*|Y*) ;; + y*|Y*) ;; *) return ;; esac diff --git a/distrib/mvme88k/ramdisk/install.md b/distrib/mvme88k/ramdisk/install.md index 718fac5e506..ef5e1eac35b 100644 --- a/distrib/mvme88k/ramdisk/install.md +++ b/distrib/mvme88k/ramdisk/install.md @@ -1,4 +1,4 @@ -# $OpenBSD: install.md,v 1.8 2002/02/14 03:34:15 deraadt Exp $ +# $OpenBSD: install.md,v 1.9 2002/03/31 17:30:31 deraadt Exp $ # Copyright (c) 1996 The NetBSD Foundation, Inc. # All rights reserved. # @@ -33,12 +33,15 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script. # # +# Machine-dependent install sets +MDSETS=kernel +ARCH=ARCH + md_set_term() { if [ ! -z "$TERM" ]; then return @@ -57,8 +60,8 @@ md_get_cddevs() { dmesg | egrep -a "^cd[0-9] " } -md_get_ifdevs() { - # return available network devices +md_get_ifdevs() { + # return available network devices dmesg | egrep "(^ie[0-9] )|(^le[0-9] )" | cut -d" " -f1 | sort -u } @@ -120,22 +123,19 @@ md_prep_disklabel() _disk=$1 md_checkfordisklabel $_disk case $? in - 0) - echo -n "Do you wish to edit the disklabel on $_disk? [y] " + 0) echo -n "Do you wish to edit the disklabel on $_disk? [y] " ;; - 1) - echo "WARNING: Disk $_disk has no label" + 1) echo "WARNING: Disk $_disk has no label" echo -n "Do you want to create one with the disklabel editor? [y] " ;; - 2) - echo "WARNING: Label on disk $_disk is corrupted" + 2) echo "WARNING: Label on disk $_disk is corrupted" echo -n "Do you want to try and repair the damage using the disklabel editor? [y] " ;; esac getresp "y" case "$resp" in - y*|Y*) ;; + y*|Y*) ;; *) return ;; esac diff --git a/distrib/mvmeppc/ramdisk/install.md b/distrib/mvmeppc/ramdisk/install.md index 38f835e1a2e..8c4ac04f873 100644 --- a/distrib/mvmeppc/ramdisk/install.md +++ b/distrib/mvmeppc/ramdisk/install.md @@ -1,4 +1,4 @@ -# $OpenBSD: install.md,v 1.4 2002/02/14 03:26:05 deraadt Exp $ +# $OpenBSD: install.md,v 1.5 2002/03/31 17:30:31 deraadt Exp $ # # # Copyright (c) 1996 The NetBSD Foundation, Inc. @@ -35,13 +35,13 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script. # # Machine-dependent install sets -MDSETS="kernel" +MDSETS=kernel +ARCH=ARCH md_set_term() { test -n "$TERM" && return @@ -55,10 +55,6 @@ md_makerootwritable() { : } -md_machine_arch() { - cat /kern/machine -} - md_get_diskdevs() { # return available disk devices bsort `cat /kern/msgbuf | egrep -a "^[sw]d[0-9]+ " | cutword 1` @@ -70,8 +66,8 @@ md_get_cddevs() { } md_get_partition_range() { - # return range of valid partition letters - echo [a-p] + # return range of valid partition letters + echo [a-p] } md_questions() { @@ -79,11 +75,11 @@ md_questions() { } md_installboot() { - if [[ $disklabeltype = "HFS" ]] + if [[ $disklabeltype = "HFS" ]] then echo "the 'ofwboot' program needs to be copied to the first HFS partition" echo "of the disk to allow booting of OpenBSD" - elif [[ $disklabeltype = "MBR" ]] + elif [[ $disklabeltype = "MBR" ]] then echo "Installing boot in the msdos partition /dev/${1}i" if mount -t msdos /dev/${1}i /mnt2 ; then @@ -96,11 +92,11 @@ md_installboot() { } md_native_fstype() { - echo "msdos" + echo "msdos" } md_native_fsopts() { - echo "ro" + echo "ro" } md_init_mbr() { @@ -120,10 +116,8 @@ md_init_mbr() { echo -n "Do you want to init the MBR and the MSDOS partition? [y] " getresp "y" case "$resp" in - n*|N*) - exit 0;; - *) - echo + n*|N*) exit 0;; + *) echo echo "An MBR record with an OpenBSD usable partition table will now be copied" echo "to your disk. Unless you have special requirements you will not need" echo "to edit this MBR. After the MBR is copied an empty 1MB MSDOS partition" @@ -136,12 +130,12 @@ md_init_mbr() { echo "This will take a minute or two..." sleep 2 echo -n "Creating Master Boot Record (MBR)..." - fdisk -i -f /usr/mdec/mbr $1 + fdisk -i -f /usr/mdec/mbr $1 echo "..done." echo -n "Copying 1MB MSDOS partition to disk..." gunzip < /usr/mdec/msdos1mb.gz | dd of=/dev/r$1c bs=512 seek=1 >/dev/null 2>&1 echo "..done." - ;; + ;; esac } @@ -169,13 +163,11 @@ md_checkfordisklabel() { echo -n "Do you want to choose (H)FS labeling or (M)BR labeling [H] " getresp "h" case "$resp" in - m*|M*) - export disklabeltype=MBR + m*|M*) export disklabeltype=MBR md_checkforMBRdisklabel $1 rval=$? ;; - *) - export disklabeltype=HFS + *) export disklabeltype=HFS md_init_hfs $1 rval=$? ;; @@ -188,20 +180,15 @@ md_checkforMBRdisklabel() { echo -n "Is this correct? [n] " getresp "n" case "$resp" in - n*|N*) - echo "aborting install" + n*|N*) echo "aborting install" exit 0;; - *) - ;; esac echo -n "Have you initialized an MSDOS partition using OpenFirmware? [n] " getresp "n" case "$resp" in - n*|N*) - md_init_mbr $1;; - *) - echo + n*|N*) md_init_mbr $1;; + *) echo echo "You may keep your current setup if you want to be able to use any" echo "already loaded OS. However you will be asked to prepare an empty" echo "partition for OpenBSD later. There must also be at least ~0.5MB free space" @@ -213,12 +200,9 @@ md_checkforMBRdisklabel() { echo -n "Do you want to keep the current MSDOS partition setup? [y]" getresp "y" case "$resp" in - n*|N*) - md_init_mbr $1;; - *) - ;; + n*|N*) md_init_mbr $1;; esac - ;; + ;; esac disklabel -r $1 > /dev/null 2> /tmp/checkfordisklabel @@ -294,8 +278,8 @@ __md_prep_fdisk_1 getresp "n" case "$resp" in - n*|N*) ;; - *) _done=1 ;; + n*|N*) ;; + *) _done=1 ;; esac done @@ -316,24 +300,20 @@ md_prep_disklabel() _disk=$1 md_checkfordisklabel $_disk case $? in - 0) - echo -n "Do you wish to edit the disklabel on $_disk? [y] " + 0) echo -n "Do you wish to edit the disklabel on $_disk? [y] " ;; - 1) - md_prep_fdisk ${_disk} + 1) md_prep_fdisk ${_disk} echo "WARNING: Disk $_disk has no label" echo -n "Do you want to create one with the disklabel editor? [y] " ;; - 2) - echo "WARNING: Label on disk $_disk is corrupted" + 2) echo "WARNING: Label on disk $_disk is corrupted" echo -n "Do you want to try and repair the damage using the disklabel editor? [y] " ;; - esac getresp "y" case "$resp" in - y*|Y*) ;; + y*|Y*) ;; *) return ;; esac @@ -341,7 +321,7 @@ md_prep_disklabel() cat << \__md_prep_disklabel_1 Disk partition sizes and offsets are in sector (most likely 512 bytes) units. -You may set these size/offset pairs on cylinder boundaries +You may set these size/offset pairs on cylinder boundaries (the number of sector per cylinder is given in ) (the `sectors/cylinder' entry, which is not shown here) Also, you *must* make sure that the 'i' partition points at the MSDOS @@ -366,10 +346,10 @@ Do not change any parameters except the partition layout and the label name. __md_prep_disklabel_1 echo -n "Press [Enter] to continue " getresp "" - if [[ $disklabeltype = "HFS" ]] + if [[ $disklabeltype = "HFS" ]] then disklabel -c -f /tmp/fstab.${_disk} -E ${_disk} - elif [[ $disklabeltype = "MBR" ]] + elif [[ $disklabeltype = "MBR" ]] then disklabel -W ${_disk} disklabel ${_disk} >/tmp/label.$$ @@ -443,11 +423,3 @@ has rebooted, use Open Firmware to boot into OpenBSD. __EOT } - -hostname() { - case $# in - 0) cat /kern/hostname ;; - 1) echo "$1" > /kern/hostname ;; - *) echo usage: hostname [name-of-host] - esac -} diff --git a/distrib/sparc/install.md b/distrib/sparc/install.md index 522851cae2b..5a10bedf3aa 100644 --- a/distrib/sparc/install.md +++ b/distrib/sparc/install.md @@ -1,4 +1,4 @@ -# $OpenBSD: install.md,v 1.36 2002/02/14 03:34:15 deraadt Exp $ +# $OpenBSD: install.md,v 1.37 2002/03/31 17:30:31 deraadt Exp $ # $NetBSD: install.md,v 1.3.2.5 1996/08/26 15:45:28 gwr Exp $ # # @@ -36,13 +36,12 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script. # # Machine-dependent install sets -MDSETS="kernel xbin xman xinc xcon" +MDSETS=kernel ARCH=ARCH md_set_term() { @@ -57,19 +56,19 @@ md_get_msgbuf() { # Only want to see one boot's worth of info dmesg > /tmp/msgbuf sed -n -f /dev/stdin /tmp/msgbuf <<- OOF - /^OpenBSD /h - /^OpenBSD /!H - \${ - g - p - } + /^OpenBSD /h + /^OpenBSD /!H + \${ + g + p + } OOF } md_get_diskdevs() { # return available disk devices md_get_msgbuf | sed -n -e '/^sd[0-9] /{s/ .*//;p;}' \ - -e '/^x[dy][0-9] /{s/ .*//;p;}' + -e '/^x[dy][0-9] /{s/ .*//;p;}' } md_get_cddevs() { @@ -78,8 +77,8 @@ md_get_cddevs() { } md_get_partition_range() { - # return range of valid partition letters - echo [a-p] + # return range of valid partition letters + echo [a-p] } md_questions() { @@ -104,7 +103,7 @@ md_installboot() { echo No boot block prototypes found, you must run installboot manually. return fi - + echo Installing boot block... cp ${_prefix}/boot /mnt/boot sync; sync; sync @@ -142,14 +141,11 @@ md_prep_disklabel() md_checkfordisklabel $_disk case $? in - 0) - ;; - 1) - echo WARNING: Label on disk $_disk has no label. You will be creating a new one. + 0) ;; + 1) echo WARNING: Label on disk $_disk has no label. You will be creating a new one. echo ;; - 2) - echo WARNING: Label on disk $_disk is corrupted. You will be repairing. + 2) echo WARNING: Label on disk $_disk is corrupted. You will be repairing. echo ;; esac diff --git a/distrib/sparc64/common/install.md b/distrib/sparc64/common/install.md index 9cde4dddd1c..264dd070712 100644 --- a/distrib/sparc64/common/install.md +++ b/distrib/sparc64/common/install.md @@ -1,4 +1,4 @@ -# $OpenBSD: install.md,v 1.4 2002/03/27 18:24:32 deraadt Exp $ +# $OpenBSD: install.md,v 1.5 2002/03/31 17:30:31 deraadt Exp $ # $NetBSD: install.md,v 1.3.2.5 1996/08/26 15:45:28 gwr Exp $ # # @@ -36,13 +36,12 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script. # # Machine-dependent install sets -MDSETS="kernel xbin xman xinc xcon" +MDSETS=kernel ARCH=ARCH md_set_term() { @@ -57,12 +56,12 @@ md_get_msgbuf() { # Only want to see one boot's worth of info dmesg > /tmp/msgbuf sed -n -f /dev/stdin /tmp/msgbuf <<- OOF - /^OpenBSD /h - /^OpenBSD /!H - \${ - g - p - } + /^OpenBSD /h + /^OpenBSD /!H + \${ + g + p + } OOF } @@ -77,8 +76,8 @@ md_get_cddevs() { } md_get_partition_range() { - # return range of valid partition letters - echo [a-p] + # return range of valid partition letters + echo [a-p] } md_questions() { @@ -86,11 +85,8 @@ md_questions() { echo -n "Do you expect to run the X Window System? [y] " getresp y case "$resp" in - y*|Y*) - xfree86=y - ;; - *) - ;; + y*|Y*) xfree86=y + ;; esac echo } @@ -113,7 +109,7 @@ md_installboot() { echo No boot block prototypes found, you must run installboot manually. return fi - + echo Installing boot block... ${_prefix}/installboot -v ${_prefix}/bootblk ${_rawdev} sync; sync; sync @@ -169,14 +165,11 @@ md_prep_disklabel() md_checkfordisklabel $_disk case $? in - 0) - ;; - 1) - echo WARNING: Label on disk $_disk has no label. You will be creating a new one. + 0) ;; + 1) echo WARNING: Label on disk $_disk has no label. You will be creating a new one. echo ;; - 2) - echo WARNING: Label on disk $_disk is corrupted. You will be repairing. + 2) echo WARNING: Label on disk $_disk is corrupted. You will be repairing. echo ;; esac diff --git a/distrib/sun3/install.md b/distrib/sun3/install.md index 7a56e6ca792..8fcb57b1195 100644 --- a/distrib/sun3/install.md +++ b/distrib/sun3/install.md @@ -1,4 +1,4 @@ -# $OpenBSD: install.md,v 1.4 2002/02/14 03:34:15 deraadt Exp $ +# $OpenBSD: install.md,v 1.5 2002/03/31 17:30:31 deraadt Exp $ # # # Copyright (c) 1996 The NetBSD Foundation, Inc. @@ -35,13 +35,12 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script. # # Machine-dependent install sets -MDSETS="kernel" +MDSETS=kernel ARCH=ARCH md_set_term() { @@ -56,19 +55,19 @@ md_get_msgbuf() { # Only want to see one boot's worth of info dmesg > /tmp/msgbuf sed -n -f /dev/stdin /tmp/msgbuf <<- OOF - /^OpenBSD /h - /^OpenBSD /!H - \${ - g - p - } + /^OpenBSD /h + /^OpenBSD /!H + \${ + g + p + } OOF } md_get_diskdevs() { # return available disk devices md_get_msgbuf | sed -n -e '/^sd[0-9] /{s/ .*//;p;}' \ - -e '/^x[dy][0-9] /{s/ .*//;p;}' + -e '/^x[dy][0-9] /{s/ .*//;p;}' } md_get_cddevs() { @@ -77,8 +76,8 @@ md_get_cddevs() { } md_get_partition_range() { - # return range of valid partition letters - echo [a-p] + # return range of valid partition letters + echo [a-p] } md_questions() { @@ -103,7 +102,7 @@ md_installboot() { echo No boot block prototypes found, you must run installboot manually. return fi - + echo Installing boot block... cp ${_prefix}/ufsboot /mnt/boot sync; sync; sync @@ -141,14 +140,11 @@ md_prep_disklabel() md_checkfordisklabel $_disk case $? in - 0) - ;; - 1) - echo WARNING: Label on disk $_disk has no label. You will be creating a new one. + 0) ;; + 1) echo WARNING: Label on disk $_disk has no label. You will be creating a new one. echo ;; - 2) - echo WARNING: Label on disk $_disk is corrupted. You will be repairing. + 2) echo WARNING: Label on disk $_disk is corrupted. You will be repairing. echo ;; esac diff --git a/distrib/vax/install.md b/distrib/vax/install.md index ccada6c154e..fb11cb90fba 100644 --- a/distrib/vax/install.md +++ b/distrib/vax/install.md @@ -1,4 +1,4 @@ -# $OpenBSD: install.md,v 1.8 2002/03/19 08:43:56 hugh Exp $ +# $OpenBSD: install.md,v 1.9 2002/03/31 17:30:31 deraadt Exp $ # $NetBSD: install.md,v 1.3.2.5 1996/08/26 15:45:28 gwr Exp $ # # @@ -36,7 +36,6 @@ # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # - # # machine dependent section of installation/upgrade script. # @@ -79,8 +78,8 @@ md_get_cddevs() { } md_get_partition_range() { - # return range of valid partition letters - echo [a-p] + # return range of valid partition letters + echo [a-p] } md_questions() { @@ -124,14 +123,11 @@ md_prep_disklabel() md_checkfordisklabel $_disk case $? in - 0) - ;; - 1) - echo WARNING: Label on disk $_disk has no label. You will be creating a new one. + 0) ;; + 1) echo WARNING: Label on disk $_disk has no label. You will be creating a new one. echo ;; - 2) - echo WARNING: Label on disk $_disk is corrupted. You will be repairing. + 2) echo WARNING: Label on disk $_disk is corrupted. You will be repairing. echo ;; esac |