[BACK]Return to install CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / distrib / notes / sparc

Annotation of src/distrib/notes/sparc/install, Revision 1.6

1.1       deraadt     1: Installing NetBSD is a relatively complex process, but if you have
                      2: this document in hand it shouldn't be too much trouble.
                      3:
1.4       pk          4: There are several ways to install NetBSD onto a disk. If your Sparcstation
                      5: is hooked up in a network you can find find a server and arrange for a
                      6: diskless setup which is a convenient way to install on a machine with
                      7: a single disk attached. Alternatively, you could use SunOS (booted from
                      8: a local disk) and install NetBSD onto a second disk. For the latter method,
                      9: skip to the section "Installing from SunOS" below.
                     10:
1.5       pk         11:
1.4       pk         12: Installing using a diskless setup.
                     13:
                     14: First, you must setup a diskless client configuration on a server. Consult
                     15: your server installation documents on how to proceed with this.
                     16: Put all the *.tar.gz files you want to install into the root directory
                     17: for your client on the server.
                     18:
                     19: Next, unpack base.tar.gz on the server in the root directory for your machine.
1.5       pk         20: If you elect to you a separately NFS-mounted filesystem for `/usr' on your
                     21: diskless setup, make sure the "./usr" base files in base.tar.gz end up
                     22: in the correct location. One way to do this is to temporarily use a loopback
                     23: mount on the server, re-routing <root>/usr to your server's exported
                     24: NetBSD "/usr" directory.
                     25:
1.4       pk         26: A few configuration files need to be edited:
                     27:
                     28:        <root>/etc/hosts
1.5       pk         29:                Add the IP addresses of both server and client.
                     30:
1.4       pk         31:        <root>/etc/myname
1.5       pk         32:                This files contains the client's hostname; use the same
                     33:                name as in <root>/etc/hosts.
                     34:
1.4       pk         35:        <root>/etc/fstab
1.5       pk         36:                Enter the entries for remotely mounted `root', `swap' and
                     37:                possibly `/usr' filesystems.
                     38:
                     39: Now you must populate the the `/dev' directory for your client. If you server
                     40: runs SunOS 4.x, you can simply change your working directory to `<root>/dev'
                     41: and run the MAKEDEV script: `sh MAKEDEV all'.
                     42:
                     43: On SunOS 5.x systems, MAKEDEV can also be used, but there'll be error
                     44: messages about unknown user and groups. These errors are inconsequential
                     45: for the purpose of installing NetBSD. However, you may want to correct them
                     46: if you plan to the diskless setup regularly. In that case, you may re-run
                     47: MAKEDEV on your NetBSD machine once it has booted.
1.4       pk         48:
                     49: Boot your workstation from the server by entering the appropriate `boot'
                     50: command at the monitor prompt. Depending on the PROM version in your machine,
                     51: this command takes one of the following forms:
                     52:
                     53:        > b le()netbsd -s               # for sun4 monitors
                     54:        ok boot le()netbsd -s           # for version 1 OpenBOOT ROMs
                     55:        ok boot net netbsd -s           # for version 2 OpenBOOT ROMs
                     56:
                     57: This will boot the NetBSD kernel in single-user mode.
                     58:
                     59: [[
                     60: NOTE: the latter two examples assume you operate the OpenBOOT ROM in
                     61: "new command mode". If your machine comes up and gives you a `>' prompt
                     62: instead of `ok', type:
                     63:
                     64:     >n                                 # enter native OpenBOOT mode
                     65:     ok setenv sunmon-compat? false     # make it permanent
                     66:     ok
                     67: ]]
1.5       pk         68:
                     69: If you use a diskless setup with a separately NFS-mounted /usr filesystem,
                     70: mount /usr by hand now:
                     71:
                     72: netbsd# mount /usr
                     73:
1.6     ! pk         74: If you are upgrading a NetBSD installation, start the upgrade script:
1.4       pk         75:
1.6     ! pk         76: #netbsd ./upgrade.sh
        !            77:
        !            78: else, start the installation procedure:
1.4       pk         79:
                     80: netbsd# ./install.sh
                     81:
                     82:
1.6     ! pk         83: These scripts will do most of the work of transferring the system from the
1.4       pk         84: tar files onto your disk. You will frequently be asked for confirmation
                     85: before the script proceeds with each phase of the installation process.
                     86: Occasionally, you'll have to provide a piece of information such as the
                     87: name of the disk you want to install on or IP addresses and domain names
                     88: you want to assign.
                     89:
                     90: The installation script goes through the following phases:
                     91:
                     92:        - determination of the disk to install NetBSD on
                     93:        - checking of the partition information on the disk
                     94:        - creating and mounting the NetBSD filesystems
                     95:        - setup of IP configuration
                     96:        - extraction of the distribution tar files
                     97:        - installation of boot programs
                     98:
                     99:
                    100: Now try a reboot.  (If needed, swap your scsi id's first).  Initially
                    101: I'd suggest you "boot sd()netbsd -bs", then try multiuser after that.
                    102: if you boot single-user the NetBSD incantation to make the root
                    103: filesystem writable is
                    104:
                    105:     netbsd# mount -u /dev/sd0a /
                    106:
                    107: The Sun monitor normally tries to load a file called "vmunix". On
                    108: OpenBOOT ROM systems you can change it to load NetBSD instead using
                    109: the following commands:
                    110:
                    111: On version 1 OpenBOOT ROMs:
                    112:     >n
                    113:     ok setenv boot-from sd(0,0,0)netbsd
                    114:     ok
                    115:
                    116: On version 2 OpenBOOT ROMs:
                    117:     ok setenv boot-file netbsd
                    118:     ok setenv boot-device /sbus/esp/sd@0,0
                    119:
                    120:
                    121: Congratulations, you have successfully installed NetBSD 1.0.  When you
                    122: reboot into NetBSD, you should log in as "root" at the login prompt.
                    123: There is no initial password, but if you're using the machine in a
                    124: networked environment, you should create yourself an account and
                    125: protect it and the "root" account with good passwords.
                    126:
                    127: Some of the files in the NetBSD 1.0 distribution might need to be
                    128: tailored for your site.  In particular, the /etc/sendmail.cf file will
                    129: almost definitely need to be adjusted, and other files in /etc will
                    130: probably need to be modified.  If you are unfamiliar with UN*X-like
                    131: system administration, it's recommended that you buy a book that
                    132: discusses it.
                    133:
                    134:
                    135:
                    136: Installing from SunOS.
                    137:
1.1       deraadt   138: You need a SunOS machine to install NetBSD.  You also need at
                    139: least the following pieces:
                    140:
                    141:     the *.tar.gz files you want to install (as a minimum, base.tar.gz)
                    142:     gzip (GNU gzip) SunOS binary
                    143:     gtar (GNU tar) SunOS binary
                    144:     the "install.sh" script
                    145:     a "/boot" file from a SunOS sun4c machine
1.4       pk        146:     a kernel, most likely "/netbsd"
1.1       deraadt   147:
                    148: All these pieces, except "/boot", are supplied in the NetBSD/sparc
                    149: distribution.
                    150:
                    151: You need to format and partition the disk using SunOS (since
                    152: NetBSD/sparc uses SunOS disk labels.)  Give yourself adequate
                    153: partition sizes.  Here is an example layout:
                    154:
                    155:     partition    size   offset   will be..
                    156:     sd2a        28140        0   /
                    157:     sd2b        16170    28140   swap
                    158:     sd2c       204540        0   `whole disk'
                    159:     sd2g       160230    44310   /usr
                    160:
                    161: BTW, These are not recommended sizes.  They simply match the first
                    162: (tiny) disk that NetBSD/sparc ran on.
                    163:
                    164: Use SunOS to newfs the partitions which will have filesystems on them.
                    165: (NetBSD's filesystem format is identical to SunOS).
                    166:
                    167:     sunos# newfs /dev/rsd2a
                    168:     [... lots of output]
                    169:     sunos# newfs /dev/rsd2g
                    170:     [... lots of output]
                    171:
                    172: NOTE: If you are able to, there is a performance benefit from
                    173: newfs'ing using NetBSD.  If you newfs using the NetBSD newfs command,
                    174: be sure to use the -O flag for your / partition, so that newfs will
                    175: use the 4.3BSD filesystem format, rather than the new 4.4BSD filesystem
                    176: format.  If you forget, you will not be able to boot -- the SunOS boot
                    177: blocks do not understand the extended 4.4BSD filesystem format.
                    178:
                    179: Mount those partitions in a tree formation, under /mnt; ie:
                    180:
                    181:     sunos# df
                    182:     Filesystem            kbytes    used   avail capacity  Mounted on
                    183:     [...]
                    184:     /dev/sd2a              11501       0   11501     0%    /mnt
                    185:     /dev/sd2g             179529       0  179529     0%    /mnt/usr
                    186:
                    187: Place a standard SunOS "/boot" program in /mnt (your new root
                    188: partition), and use the SunOS command "installboot" to make it work.
                    189: The installboot man page says to do something like this:
                    190:
                    191:     sunos# cp /boot /mnt/boot
                    192:     sunos# /usr/mdec/installboot -vlt /mnt/boot /usr/mdec/bootsd /dev/rsd2a
                    193:
                    194: You can now extract the provided "*.tar.gz files onto your disk.  The
                    195: provided script, "install.sh" will help you:
                    196:
                    197:     sunos# ls -FC
                    198:     base.tar.gz      etc.tar.gz       man.tar.gz       secr.tar.gz
                    199:     comp.tar.gz      games.tar.gz     misc.tar.gz      text.tar.gz
                    200:     install.sh       netbsd.id3_scsi
                    201:     sunos# ./install.sh
                    202:     [...]
                    203:
                    204: This script NEEDS gzip and gtar (GNU gzip and GNU tar) on your
                    205: execution path!  The tar files are in a "new format" that includes
                    206: directory information, and SunOS tar will not read them.  Statically
                    207: linked versions of these programs for SunOS are supplied in the
                    208: distribution.
                    209:
                    210: After the files have been extracted, repair /mnt/etc/fstab to match
                    211: your actual disk layout.  (Minus the "/mnt" component of each path, of
                    212: course :-)
                    213:
1.4       pk        214: Now proceed to reboot the machine as described above in "Installing
                    215: using a diskless setup".

CVSweb <webmaster@jp.NetBSD.org>