Home | History | Annotate | Line # | Download | only in x68k
install revision 1.5
      1  1.5  minoura 	$NetBSD: install,v 1.5 1998/10/21 14:32:36 minoura Exp $	
      2  1.3    perry 
      3  1.1      oki Installing NetBSD is a relatively complex process, but if you have
      4  1.1      oki this document in hand and are careful to read and remember the
      5  1.1      oki information which is presented to you by the install program, it
      6  1.1      oki shouldn't be too much trouble.
      7  1.1      oki 
      8  1.1      oki Before you begin, you should know the geometry of your hard disk, i.e.
      9  1.1      oki the sector size (note that sector sizes other than 512 bytes are not
     10  1.1      oki currently supported), the number of sectors per track, the number of
     11  1.1      oki tracks per cylinder (also known as the number of heads), and the
     12  1.1      oki number of cylinders on the disk.  The NetBSD kernel will try to
     13  1.1      oki discover these parameters on its own, and if it can it will print them
     14  1.1      oki at boot time.  If possible, you should use the parameters it prints.
     15  1.1      oki (You might not be able to because you're sharing your disk with
     16  1.1      oki another operating system, or because your disk is old enough that the
     17  1.1      oki kernel can't figure out its geometry.)
     18  1.1      oki 
     19  1.1      oki You should now be ready to install NetBSD.  It might be handy for you
     20  1.1      oki to have a pencil, some paper, and a calculator handy.
     21  1.1      oki 
     22  1.1      oki The following is a walk-through of the steps you will take while
     23  1.1      oki getting NetBSD installed on your hard disk.  If any question has a
     24  1.1      oki default answer, it will be displayed in brackets ("[]") after the
     25  1.1      oki question.  If you wish to stop the installation, you may hit Control-C
     26  1.1      oki at any time, but if you do, you'll have to begin the installation
     27  1.1      oki process again from scratch.
     28  1.1      oki 
     29  1.5  minoura 	Boot your machine using of boot floppy.  If the boot prompt
     30  1.5  minoura 	does not appear in a reasonable amount of time, you either
     31  1.5  minoura 	have a bad boot floppy or a hardware problem.  Try writing the
     32  1.5  minoura 	boot floppy image to a different disk, and using that.  If it
     33  1.5  minoura 	still doesn't work, NetBSD probably can't be run on your
     34  1.5  minoura 	hardware.  This can probably be considered a bug, so you might
     35  1.5  minoura 	want to report it.  If you do, please include as many details
     36  1.5  minoura 	about your system configuration as you can.
     37  1.1      oki 
     38  1.1      oki 	It will take a while to load the kernel from the floppy,
     39  1.5  minoura 	probably around a minute or so.  
     40  1.1      oki 
     41  1.1      oki 	You will then be presented with the NetBSD kernel boot
     42  1.1      oki 	messages.  You will want to read them, to determine your
     43  1.1      oki 	disk's name and geometry.  Its name will be something like
     44  1.5  minoura 	"sd0" and the geometry will be printed on a line that
     45  1.1      oki 	begins with its name.  As mentioned above, you will need your
     46  1.1      oki 	disk's geometry when creating NetBSD's partitions.  You will
     47  1.1      oki 	also need to know the name, to tell the install tools what
     48  1.1      oki 	disk to install on.
     49  1.1      oki 
     50  1.1      oki 	While booting, you will probably see several warnings.  You
     51  1.1      oki 	should be warned that no swap space is present, and that
     52  1.1      oki 	init(8) cannot find /etc/rc.  Do not be alarmed, these are
     53  1.1      oki 	completely normal.  When you reach the prompt asking you for a
     54  1.1      oki 	shell name, just hit return.
     55  1.1      oki 
     56  1.1      oki 	You will be presented with a welcome message and a prompt,
     57  1.1      oki 	asking if you wish to proceed with the installation process.
     58  1.1      oki 	If you wish to proceed, enter "y" and hit return.
     59  1.1      oki 
     60  1.1      oki 	You will be asked what type of disk driver you have.  The
     61  1.1      oki 	valid options are listed by the install program, to make sure
     62  1.1      oki 	you get it right.  If you are SURE that it does, reply
     63  1.1      oki 	affirmatively.  Otherwise, the install program will
     64  1.1      oki 	automatically reserve space for bad144 tables.
     65  1.1      oki 
     66  1.1      oki 	The install program will then tell you which disks of that
     67  1.1      oki 	type it can install on, and ask you which it should use.
     68  1.1      oki 	Reply with the name of your disk.
     69  1.1      oki 
     70  1.1      oki 	You will then be asked to name your disk's disklabel.  The
     71  1.5  minoura 	default response is "mysd", and for most purposes it will be
     72  1.5  minoura 	OK.  If you choose to name it something different, make sure
     73  1.5  minoura 	the name is a single word and contains no special characters.
     74  1.5  minoura 	You don't need to remember this name.
     75  1.1      oki 
     76  1.1      oki 	You will be prompted for your disk's geometry information,
     77  1.1      oki 	i.e. the number of bytes per sector, cylinders on the disk,
     78  1.1      oki 	tracks per cylinder (heads), and sectors per track.  Enter
     79  1.1      oki 	them when they are requested.  If you make a mistake, hit
     80  1.1      oki 	Control-C and when you get to the shell prompt, restart the
     81  1.1      oki 	install process by running the "install" command.  Once you
     82  1.1      oki 	have entered this data, the install program will tell you the
     83  1.1      oki 	total size of your disk, in both sectors, and cylinders.
     84  1.1      oki 	Remember this number; if you're installing on the whole disk,
     85  1.1      oki 	you'll need it again soon.
     86  1.1      oki 
     87  1.1      oki 	When describing your partitions, you will have the option of
     88  1.1      oki 	entering data about them in units of disk sectors or
     89  1.1      oki 	cylinders.  If you choose to enter the information in units of
     90  1.1      oki 	sectors, remember that, for optimal performance, partitions
     91  1.1      oki 	should begin and end on cylinder boundaries.  You will be
     92  1.1      oki 	asked about which units you wish to use, and you should reply
     93  1.1      oki 	with "c" for cylinders, or "s" for sectors.
     94  1.1      oki 
     95  1.1      oki 	You will be asked to enter the size of your NetBSD root
     96  1.5  minoura 	partition.  It should be at least 15M, but if you are going to
     97  1.5  minoura 	be doing development, 20M is a more desirable size.  This
     98  1.1      oki 	size should be expressed in units of sectors or cylinders,
     99  1.1      oki 	depending on which you said you wanted to use.
    100  1.1      oki 
    101  1.1      oki 	Next, you will be asked for the size of your swap partition.
    102  1.1      oki 	You should probably allocate twice as much swap space as you
    103  1.1      oki 	have real memory.  Systems that will be heavily used should
    104  1.1      oki 	have more swap space allocated, and systems that will be
    105  1.1      oki 	lightly used can get by with less.  If you want the system to
    106  1.1      oki 	be able to save crash dumps when it panics, you will need at
    107  1.1      oki 	least as much swap space as you have RAM.  Again, this number
    108  1.1      oki 	should be expressed in units of sectors or cylinders, as
    109  1.1      oki 	appropriate.
    110  1.1      oki 
    111  1.1      oki 	The install program will then ask you for information about
    112  1.1      oki 	the rest of the partitions you want on your disk.  For most
    113  1.1      oki 	purposes, you will want only one more partition, "/usr".
    114  1.1      oki 	(Machines used as servers will probably also want /var as a
    115  1.1      oki 	separate partition.  That can be done with these installation
    116  1.1      oki 	tools, but is not covered here.)  The install program will
    117  1.1      oki 	tell you how much space there is left to be allocated in the
    118  1.1      oki 	NetBSD area of the disk, and, if you only want one more
    119  1.1      oki 	partition ("/usr"), you should enter it at the prompt when the
    120  1.1      oki 	installer asks you how large the next partition should be.
    121  1.1      oki 	It will then ask you for the name of the mount point for that
    122  1.1      oki 	partition.  If you're doing a basic installation, that is
    123  1.1      oki 	"/usr".
    124  1.1      oki 
    125  1.1      oki 	YOU ARE NOW AT THE POINT OF NO RETURN.  Nothing has been
    126  1.1      oki 	written to your disk yet, but if you confirm that you want to
    127  1.1      oki 	install NetBSD, your hard drive will be modified, and its
    128  1.1      oki 	contents may be scrambled at the whim of the install program.
    129  1.1      oki 	This is especially likely if you have given the install
    130  1.1      oki 	program incorrect information.  If you are sure you want to
    131  1.1      oki 	proceed, enter "yes" at the prompt.
    132  1.1      oki 
    133  1.1      oki 	The install program will now label your disk and make the file
    134  1.1      oki 	systems you specified.  The filesystems will be initialized to
    135  1.1      oki 	contain NetBSD bootstrapping binaries and configuration files.
    136  1.1      oki 	It will also create an /etc/fstab for your system, and mount
    137  1.1      oki 	all of the file systems under /mnt. (In other words, your root
    138  1.1      oki 	partition will be mounted on /mnt, your /usr partition on
    139  1.1      oki 	/mnt/usr, and so on.)  There should be no errors in this
    140  1.1      oki 	section of the installation.  If there are, restart from the
    141  1.1      oki 	beginning of the installation process.
    142  1.1      oki 
    143  1.1      oki 	You will be placed at a shell prompt ("#").  The remaining
    144  1.1      oki 	tasks are to copy the kernel from the kernel copy floppy to
    145  1.1      oki 	the hard drive's root filesystem and install the distribution
    146  1.1      oki 	sets.  The flow of installation differs depending on your
    147  1.1      oki 	hardware resources, and on what media the distribution sets
    148  1.1      oki 	reside.
    149  1.1      oki 
    150  1.5  minoura 	To install from removable hard disk:
    151  1.5  minoura 		The first thing you should do is pick a temporary
    152  1.5  minoura 		directory where the distribution files can be stored.
    153  1.5  minoura 		To do this, enter the command "Set_tmp_dir", and enter
    154  1.5  minoura 		the name of the temporary directory.  (Don't forget
    155  1.5  minoura 		that your disk is mounted under /mnt; you should
    156  1.5  minoura 		probably pick a directory under /mnt/usr.)  The
    157  1.5  minoura 		default is /mnt/usr/distrib.
    158  1.5  minoura 
    159  1.5  minoura 		Insert the media onto the drive.  Check the device
    160  1.5  minoura 		name of your drive from the boot message.  The device
    161  1.5  minoura 		name is something like "sd2" depending on the SCSI
    162  1.5  minoura 		disk drives connected to your machine.  Note that the
    163  1.5  minoura 		boot message can be displayed with the command
    164  1.5  minoura 		"more /kern/msgbuf".
    165  1.5  minoura 
    166  1.5  minoura 		Mount the disk on the temporary directory with a
    167  1.5  minoura 		command like:
    168  1.5  minoura 
    169  1.5  minoura 		mount -t msdos /dev/sd2c <tmp_dir>
    170  1.5  minoura 
    171  1.5  minoura 		if your removable drive's name is sd2.
    172  1.5  minoura 
    173  1.1      oki 	To install from floppy:
    174  1.1      oki 		The first thing you should do is pick a temporary
    175  1.1      oki 		directory where the distribution files can be stored.
    176  1.1      oki 		To do this, enter the command "Set_tmp_dir", and enter
    177  1.1      oki 		the name of the temporary directory.  (Don't forget
    178  1.1      oki 		that if your disk is still mounted under /mnt; you
    179  1.1      oki 		should probably pick a directory under /mnt/usr.)
    180  1.1      oki 
    181  1.1      oki 		After you have picked a temporary directory, enter the
    182  1.1      oki 		"Load_fd" command, to load the distribution sets from
    183  1.1      oki 		your floppies.
    184  1.1      oki 
    185  1.1      oki 		You will be asked which floppy drive to use.  Enter
    186  1.1      oki 		"0" (zero) if you're using the first floppy drive
    187  1.1      oki 		(i.e. what DOS would call "A:"), or enter "1" if
    188  1.5  minoura 		you're using the second.
    189  1.1      oki 
    190  1.1      oki 		You will be prompted to insert a floppy into the drive,
    191  1.1      oki 		to have its contents copied to your hard disk.  Do so,
    192  1.1      oki 		and hit return to begin copying.  When that is done,
    193  1.1      oki 		read the remainder of the floppies that contain the
    194  1.1      oki 		distribution sets that you want to install, one by
    195  1.1      oki 		one.  When the last is read, and you are being
    196  1.1      oki 		prompted for another, hit Control-C.
    197  1.1      oki 
    198  1.1      oki 		Run the "Extract" command once for each distribution
    199  1.1      oki 		set you wish to install.  For instance, if you wish to
    200  1.5  minoura 		install the "base" distribution set, followed by the
    201  1.5  minoura 		"man" distribution set, and finally the "etc"
    202  1.1      oki 		distribution set, use the commands:
    203  1.5  minoura 			Extract base
    204  1.5  minoura 			Extract man
    205  1.5  minoura 			Extract etc
    206  1.1      oki 
    207  1.1      oki 		For each extraction, it will ask you if the extraction
    208  1.1      oki 		should be verbose.  If you reply affirmatively, it
    209  1.1      oki 		will print out the name of each file that's being
    210  1.1      oki 		extracted.
    211  1.1      oki 
    212  1.1      oki 		(Note: if you know that you will be running low on
    213  1.1      oki 		disk space when installing NetBSD, you can load and
    214  1.1      oki 		extract one distribution set at a time.  To do this,
    215  1.1      oki 		load only the floppies which contain the files for the
    216  1.1      oki 		first distribution set, extract them, and then change
    217  1.1      oki 		to the temporary directory and remove them with the
    218  1.1      oki 		command "rm set_name.??".)
    219  1.1      oki 
    220  1.1      oki 		Once you are finished extracting all of the sets that
    221  1.1      oki 		you wish to install, you should proceed to the
    222  1.1      oki 		instructions below (after the last install medium
    223  1.1      oki 		type-specific instructions), that explain how you
    224  1.1      oki 		should configure your system.
    225  1.1      oki 
    226  1.1      oki 	To install from tape:
    227  1.1      oki 		The first thing you should do is pick a temporary
    228  1.1      oki 		directory where the distribution files can be stored.
    229  1.1      oki 		To do this, enter the command "Set_tmp_dir", and enter
    230  1.1      oki 		the name of the temporary directory.  (Don't forget
    231  1.1      oki 		that your disk is mounted under /mnt; you should
    232  1.1      oki 		probably pick a directory under /mnt/usr.)  The
    233  1.1      oki 		default is /mnt/usr/distrib.
    234  1.1      oki 
    235  1.1      oki 		After you have picked a temporary directory, enter the
    236  1.1      oki 		"Load_tape" command, to load the distribution sets from
    237  1.1      oki 		tape.
    238  1.1      oki 
    239  1.1      oki 		You will be asked which tape drive to use.  The
    240  1.1      oki 		default is "rst0", which is correct if you're using
    241  1.1      oki 		the SCSI tape drive with the lowest SCSI ID number.
    242  1.1      oki 		(For the SCSI tape drive with the next lowest SCSI ID
    243  1.1      oki 		number, you should use "rst1", and so on.)
    244  1.1      oki 
    245  1.1      oki 		You will be prompted to hit return when you have
    246  1.1      oki 		inserted the tape into the tape drive.  When you do,
    247  1.1      oki 		the contents of the tape will be extracted into the
    248  1.1      oki 		temporary directory, and the names of the files being
    249  1.1      oki 		extracted will be printed.
    250  1.1      oki 
    251  1.1      oki 		After the tape has been extracted, to go the directory
    252  1.1      oki 		containing the first distribution set you wish to
    253  1.1      oki 		install.  (Depending on how you made the tape, it's
    254  1.1      oki 		probably a subdirectory of the temporary directory you
    255  1.1      oki 		specified above.)  Once there, run the "Set_tmp_dir"
    256  1.1      oki 		command again, and accept its default answer by
    257  1.1      oki 		hitting return at the prompt.
    258  1.1      oki 
    259  1.1      oki 		Use the "Extract" command to extract the distribution
    260  1.5  minoura 		set.  For instance, if you're extracting the "base"
    261  1.1      oki 		set, use the command:
    262  1.5  minoura 			Extract base
    263  1.1      oki 		You will be asked if you wish the extraction to be
    264  1.1      oki 		verbose.  If you reply affirmatively, the name of each
    265  1.1      oki 		file being extracted will be printed.
    266  1.1      oki 
    267  1.1      oki 		Repeat the previous two steps for each distribution
    268  1.1      oki 		set you wish to install.  Change to the set's
    269  1.1      oki 		directory, run "Set_tmp_dir", and then run
    270  1.1      oki 		"Extract <set_name>" to extract the set.
    271  1.1      oki 
    272  1.1      oki 		Once you are finished extracting all of the sets that
    273  1.1      oki 		you wish to install, you should proceed to the
    274  1.1      oki 		instructions below (after the last install medium
    275  1.1      oki 		type-specific instructions), that explain how you
    276  1.1      oki 		should configure your system.
    277  1.1      oki 
    278  1.1      oki 	To install via FTP or NFS:
    279  1.1      oki 		The first thing you should do is pick a temporary
    280  1.1      oki 		directory where the distribution files can be stored.
    281  1.1      oki 		To do this, enter the command "Set_tmp_dir", and enter
    282  1.1      oki 		the name of the temporary directory.  (Don't forget
    283  1.1      oki 		that your disk is mounted under /mnt; you should
    284  1.1      oki 		probably pick a directory under /mnt/usr.)  The
    285  1.1      oki 		default is /mnt/usr/distrib.
    286  1.1      oki 
    287  1.2      oki 		Configure the SLIP interface, with the following
    288  1.2      oki 		command sequence:
    289  1.1      oki 
    290  1.2      oki 		slattach -h -s <speed> tty00
    291  1.2      oki 		ifconfig sl0 <my_ipaddr> <peer_ipaddr>
    292  1.1      oki 
    293  1.2      oki 		where "<speed>" is the network speed, and "<my_ipaddr>"
    294  1.2      oki 		is the numeric IP address of the machine you are going
    295  1.2      oki 		to install NetBSD/x68k, while "<peer_ipaddr>" is the
    296  1.2      oki 		address of the peer machine connected with your machine.
    297  1.2      oki 		You might have to configure the peer SLIP interface
    298  1.2      oki 		with similar sequence (depending on the peer system).
    299  1.2      oki 
    300  1.2      oki 		For instance, the sequence
    301  1.2      oki 
    302  1.2      oki 		slattach -h -s 38400 tty00
    303  1.2      oki 		ifconfig sl0 192.168.0.1 192.168.0.10
    304  1.2      oki 
    305  1.2      oki 		configures the SLIP interface for the network between
    306  1.2      oki 		your machine (with IP address 192.168.0.1) and the peer
    307  1.2      oki 		(192.168.0.10) with speed 38400 bps.  Note that IP
    308  1.2      oki 		addresses 192.168.*.* are the private IP addresses 
    309  1.2      oki 		described in RFC 1597.
    310  1.1      oki 
    311  1.1      oki 		If you are NFS-mounting the distribution sets, mount
    312  1.1      oki 		them on the temporary directory with a command like:
    313  1.1      oki 
    314  1.1      oki 		mount -t nfs <serv_ipaddr>:<dist_dir> <tmp_dir>
    315  1.1      oki 
    316  1.1      oki 		where <serv_ipaddr> is the server's numeric IP address,
    317  1.1      oki 		<dist_dir> is the path to the distribution files on
    318  1.1      oki 		the server, and <tmp_dir> is the name of the local
    319  1.1      oki 		temporary directory.
    320  1.1      oki 
    321  1.1      oki 		Once this is done, proceed as if you had loaded the
    322  1.1      oki 		files from tape, changing to the appropriate
    323  1.1      oki 		directories, running "Set_tmp_dir", and running
    324  1.1      oki 		"Extract" as appropriate.
    325  1.1      oki 
    326  1.1      oki 		If you are retrieving the distribution sets using ftp,
    327  1.1      oki 		change into the temporary directory, and execute the
    328  1.1      oki 		command:
    329  1.1      oki 
    330  1.1      oki 		ftp <serv_ipaddr>
    331  1.1      oki 
    332  1.1      oki 		where <serv_ipaddr> is once again the server's numeric
    333  1.1      oki 		IP address.  Get the files with FTP, taking care to
    334  1.1      oki 		use binary mode when transferring the files.
    335  1.1      oki 
    336  1.1      oki 		Once you have all of the files for the distribution
    337  1.1      oki 		sets that you wish to install, you can proceed using
    338  1.1      oki 		the instructions above, as if you had installed from a
    339  1.1      oki 		floppy.  (Note that as with the floppy install, if
    340  1.1      oki 		you're short on disk space, you can transfer only one
    341  1.1      oki 		set at a time, extract it, then delete it, to save
    342  1.1      oki 		space.)
    343  1.1      oki 
    344  1.1      oki 	Once you have finished extracting all of the distribution sets
    345  1.1      oki 	that you wish to install, and are back at the "#" prompt, you
    346  1.1      oki 	are ready to configure your system.  The configuration utility
    347  1.5  minoura 	expects that you have installed the "base" and "etc"
    348  1.1      oki 	distribution sets.  If you have not, you will not be able to
    349  1.1      oki 	run it successfully (nor will you have a functional system, in
    350  1.1      oki 	any case).  To configure your newly-installed NetBSD system,
    351  1.1      oki 	run the command "Configure".  It will ask you for the system's
    352  1.1      oki 	host name, domain name, and other network configuration
    353  1.1      oki 	information.  It will set up your configuration files and make
    354  1.1      oki 	the device nodes for the newly-installed system.
    355  1.1      oki 
    356  1.1      oki Kernel Installation:
    357  1.5  minoura 	The kernel must be installed by hand.  Type
    358  1.5  minoura 		# cd /mnt
    359  1.5  minoura 		# gzip -dc $tmp_dir/netbsd-ALL.gz > netbsd
    360  1.5  minoura 	where $tmp_dir will be extracted to the distribution sets
    361  1.5  minoura 	directory.
    362  1.5  minoura 
    363  1.5  minoura 
    364  1.5  minoura Congratulations, you have successfully installed NetBSD _VER.  When you
    365  1.5  minoura reboot into NetBSD, you should log in as "root" at the login prompt.
    366  1.5  minoura There is no initial password, but if you're using the machine in a
    367  1.5  minoura networked environment, you should create yourself an account and
    368  1.5  minoura protect it and the "root" account with good passwords.
    369  1.5  minoura 
    370  1.5  minoura Some of the files in the NetBSD _VER distribution might need to be
    371  1.5  minoura tailored for your site.  In particular, the /etc/sendmail.cf file will
    372  1.5  minoura almost definitely need to be adjusted, and other files in /etc
    373  1.5  minoura including /etc/rc.conf will probably need to be modified, as well.  If
    374  1.5  minoura you are unfamiliar with UN*X-like system administration, it's
    375  1.5  minoura recommended that you buy a book that discusses it.
    376