Annotation of wikisrc/guide/exinst.mdwn, revision 1.7

1.3       jdf         1: **Contents**
                      2: 
                      3: [[!toc levels=3]]
                      4: 
1.1       jdf         5: # Example installation
                      6: 
                      7: ## Introduction
                      8: 
1.5       jdf         9: This chapter will guide you through the installation process. The concepts
                     10: presented here apply to all installation methods. The only difference is in the
                     11: way the distribution sets are fetched by the installer. Some details of the
1.7     ! sevan      12: installation differ depending on the NetBSD release. The examples from this
        !            13: chapter were created with NetBSD 8.0.
1.1       jdf        14: 
                     15: ### Note
                     16: 
1.5       jdf        17: The following install screens are just examples. Do not simply copy them, as
1.1       jdf        18: your hardware and configuration details may be different!
                     19: 
                     20: ## The installation process
                     21: 
1.5       jdf        22: The installation process is divided logically in two parts. In the first part
                     23: you create a partition for NetBSD and write the disklabel for that partition. In
                     24: the second part you decide which distribution sets (subsets of the operating
                     25: system) you want to install and then extract the files into the newly created
1.1       jdf        26: partition(s).
                     27: 
                     28: ## Keyboard layout
                     29: 
1.7     ! sevan      30: The NetBSD install program sysinst allows you to change the keyboard layout
        !            31: during the installation. If for some reason this does not work for you, you can
        !            32: use the map in the following table.
        !            33: 
1.2       jdf        34: [[!table data="""
                     35: US | IT | DE | FR
                     36: `-` | `'` | `ß` | `)`
                     37: `/` | `-` | `-` | `!`
                     38: `=` | `ì` | `'` | `-`
                     39: `:` | `ç` | `Ö` | `M`
                     40: `;` | `ò` | `ö` | `m`
                     41: `#` | `£` | `§` | `3`
                     42: `"` | `°` | `Ä` | `%`
                     43: `*` | `(` | `(` | `8`
                     44: `(` | `)` | `)` | `9`
                     45: `)` | `=` | `=` | `0`
                     46: `'` | `à` | `ä` | `ù`
                     47: `` ` `` | `\` | `^` | `@`
                     48: `\` | `ù` | `#` | `` ` ``
                     49: """]]
1.1       jdf        50: 
                     51: ## Starting the installation
                     52: 
1.5       jdf        53: To start the installation of NetBSD, insert your chosen boot media (CD/DVD, USB
                     54: drive, floppy, etc.) and reboot the computer. The kernel on the installation
1.7     ! sevan      55: medium will be booted and it will start displaying a lot of messages on the
        !            56: screen about hardware being detected.
1.1       jdf        57: 
                     58: ![Selecting the language](/guide/images/exinst_language.png)  
                     59: **Selecting the language**
                     60: 
1.5       jdf        61: When the kernel has booted you will find yourself in the NetBSD installation
                     62: program, sysinst, shown in the previous figure. From here on you should follow
                     63: the instructions displayed on the screen, using the `INSTALL` document as a
                     64: companion reference. You will find the INSTALL document in various formats in
                     65: the root directory of the NetBSD release. The sysinst screens all have more or
                     66: less the same layout: the upper part of the screen shows a short description of
                     67: the current operation or a short help message, and the rest of the screen is
                     68: made up of interactive menus and prompts. To make a choice, use the cursor keys,
                     69: the `Ctrl+N` (next) and `Ctrl+P` (previous) keys, or press one of the letters
1.7     ! sevan      70: displayed left of each choice. Confirm your choice by pressing the Return (also
        !            71: known as "Enter") key.
1.1       jdf        72: 
                     73: Start by selecting the language you prefer to use for the installation process.
                     74: 
                     75: The next screen will allow you to select a suitable keyboard type:
                     76: 
                     77: ![Selecting a keyboard type](/guide/images/exinst_keyboard.png)  
                     78: **Selecting a keyboard type**
                     79: 
                     80: This will bring you to the main menu of the installation program:
                     81: 
                     82: ![The sysinst main menu](/guide/images/exinst_main.png)  
                     83: **The sysinst main menu**
                     84: 
1.5       jdf        85: Choosing the *Install NetBSD to hard disk* option brings you to the next screen
1.1       jdf        86: , where you need to confirm that you want to continue the installation:
                     87: 
                     88: ![Confirming to install NetBSD](/guide/images/exinst_confirm.png)  
                     89: **Confirming to install NetBSD**
                     90: 
1.5       jdf        91: After choosing *Yes* to continue, sysinst displays a list of one or more disks
                     92: and asks which one you want to install NetBSD on. In the example given in the
                     93: following figure, there are two disks, and NetBSD will be installed on `wd0`,
1.7     ! sevan      94: the first SATA or IDE disk found. If you use SCSI or external USB disks, the first will
1.1       jdf        95: be named `sd0`, the second `sd1` and so on.
                     96: 
                     97: ![Choosing a hard disk](/guide/images/exinst_select_disk.png)  
                     98: **Choosing a hard disk**
                     99: 
1.7     ! sevan     100: Then installer will ask to confirm the detected disk geometry from the
        !           101: information provided by the BIOS. It gives almost always the right values. Choose
        !           102: "This is the correct geometry", unless you know that the information provided by
        !           103: your BIOS is reportedly incorrect.
1.1       jdf       104: 
1.7     ! sevan     105: ![Disk geometry](/guide/images/exinst_disk-geometry.png)
        !           106: **Disk geometry**
1.1       jdf       107: 
                    108: ## MBR partitions
                    109: 
1.5       jdf       110: The first important step of the installation has come: the partitioning of the
                    111: hard disk. First, you need to specify whether NetBSD will use a partition
                    112: (suggested choice) or the whole disk. In the former case it is still possible to
                    113: create a partition that uses the whole hard disk (see below) so we recommend
                    114: that you select this option as it keeps the BIOS partition table in a format
1.1       jdf       115: which is compatible with other operating systems.
                    116: 
                    117: ![Choosing the partitioning scheme](/guide/images/exinst_mbr.png)  
                    118: **Choosing the partitioning scheme**
                    119: 
1.5       jdf       120: The next screen shows the current state of the MBR partition table on the hard
                    121: disk before the installation of NetBSD. There are four primary partitions, and
                    122: as you can see, this example disk is currently empty. If you do have other
                    123: partitions you can leave them around and install NetBSD on a partition that is
1.1       jdf       124: currently unused, or you can overwrite a partition to use it for NetBSD.
                    125: 
                    126: ![fdisk](/guide/images/exinst_fdisk.png)  
                    127: **fdisk**
                    128: 
1.5       jdf       129: Deleting a partition is simple: after selecting the partition, a menu with
                    130: options for that partition will appear (see below). Change the partition kind to
                    131: *Delete partition* to remove the partition. Of course, if you want to use the
1.1       jdf       132: partition for NetBSD you can set the partition kind to *NetBSD*.
                    133: 
1.5       jdf       134: You can create a partition for NetBSD by selecting the partition you want to
                    135: install NetBSD to. The partition names `a` to `d` correspond to the four primary
                    136: partitions on other operating systems. After selecting a partition, a menu with
1.1       jdf       137: options for that partition will appear, as shown here:
                    138: 
                    139: ![Partition options](/guide/images/exinst_fdisk-type.png)  
                    140: **Partition options**
                    141: 
                    142: To create a new partition, the following information must be supplied:
                    143: 
                    144:  * the type (kind) of the new partition
                    145:  * the first (start) sector of the new partition
                    146:  * the size of the new partition
                    147: 
1.5       jdf       148: Choose the partition type *NetBSD* for the new partition (using the `type`
                    149: option). The installation program will try to guess the *start* position based
                    150: on the end of the preceding partition. Change this value if necessary. The same
                    151: thing applies to the `size` option; the installation program will try to fill in
                    152: the space that is available until the next partition or the end of the disk
                    153: (depending on which comes first). You can change this value if it is incorrect,
1.1       jdf       154: or if you do not want NetBSD to use the suggested amount of space.
                    155: 
1.5       jdf       156: After you have chosen the partition type, start position, and size, it is a good
                    157: idea to set the name that should be used in the boot menu. You can do this by
1.7     ! sevan     158: selecting the *bootmenu* option and providing a label, e.g., `NetBSD`.
        !           159: Repeat this step for other bootable partitions so you can boot both
1.5       jdf       160: NetBSD and a Windows system (or other operating systems) using the NetBSD
1.7     ! sevan     161: bootselector. You can also choose one of the labelled partitions as default for
        !           162: the boot menu. If you are satisfied with the partition options, confirm your
1.5       jdf       163: choice by selecting *Partition OK*. Choose *Partition table OK* to leave the MBR
1.1       jdf       164: partition table editor.
                    165: 
1.5       jdf       166: If you have made an error in partitioning (for example you have created
1.7     ! sevan     167: overlapping partitions) sysinst will display a message and suggest to go
1.5       jdf       168: back to the MBR partition editor (but you are also allowed to continue). If the
                    169: data is correct but the NetBSD partition lies outside the range of sectors which
                    170: is bootable by the BIOS, sysinst will warn you and ask if you want to proceed
1.1       jdf       171: anyway. Doing so may lead to problems on older PCs.
                    172: 
1.5       jdf       173: *Note*: This is not a limitation of NetBSD. Some old BIOSes cannot boot a
                    174: partition which lies outside the first 1024 cylinders. To fully understand the
                    175: problem you should study the different type of BIOSes and the many addressing
                    176: schemes that they use (*physical CHS*, *logical CHS*, *LBA*, ...). These topics
1.1       jdf       177: are not described in this guide.
                    178: 
1.5       jdf       179: On modern computers (those with support for *int13 extensions*), it is possible
                    180: to install NetBSD in partitions that live outside the first 8 GB of the hard
1.1       jdf       181: disk, provided that the NetBSD boot selector is installed.
                    182: 
1.5       jdf       183: Next, sysinst will offer to install a boot selector on the hard disk. This
1.1       jdf       184: screen is shown here:
                    185: 
                    186: ![Installing the boot selector](/guide/images/exinst_bootselect.png)  
                    187: **Installing the boot selector**
                    188: 
1.5       jdf       189: At this point, the *BIOS partitions* (called *slices* on BSD systems) have been
                    190: created. They are also called *PC BIOS partitions*, *MBR partitions* or *fdisk
1.1       jdf       191: partitions*.
                    192: 
1.5       jdf       193: *Note*: Do not confuse the *slices* or *BIOS partitions* with the *BSD
1.1       jdf       194: partitions*, which are different things.
                    195: 
                    196: ## Disklabel partitions
                    197: 
1.5       jdf       198: Some platforms, like PC systems (amd64 and i386), use DOS-style MBR partitions
                    199: to separate file systems. The MBR partition you created earlier in the
                    200: installation process is necessary to make sure that other operating systems do
1.1       jdf       201: not overwrite the diskspace that you allocated to NetBSD.
                    202: 
1.5       jdf       203: NetBSD uses its own partition scheme, called a *disklabel*, which is stored at
                    204: the start of the MBR partition. In the next few steps you will create a
1.6       plunky    205: [[!template id=man name="disklabel" section="5"]]
1.5       jdf       206: and set the sizes of the NetBSD partitions, or use existing partition sizes, as
1.1       jdf       207: shown here:
                    208: 
                    209: ![Edit partitions?](/guide/images/exinst_disklabel.png)  
                    210: **Edit partitions?**
                    211: 
1.5       jdf       212: When you choose to set the sizes of the NetBSD partitions you can define the
                    213: partitions you would like to create. The installation program will generate a
1.1       jdf       214: disklabel based on these settings. This installation screen is shown here:
                    215: 
                    216: ![Setting partition sizes](/guide/images/exinst_disklabel-change.png)  
                    217: **Setting partition sizes**
                    218: 
1.5       jdf       219: The default partition scheme of just using a big `/` (root) file system (plus
                    220: swap) works fine with NetBSD, and there is little need to change this. The
1.7     ! sevan     221: previous figure shows how to change the size of the swap partition to 4096 MB.
        !           222: Note also that partition / is marked with a "+", so it will occupy all the remaining free space (not located for any other partition).
1.5       jdf       223: Changing `/tmp` to reside on a *RAM disk*
1.7     ! sevan     224: ([[!template id=man name="mount_tmpfs" section="8"]] or [[!template id=man name="mfs" section="8"]]) for
1.5       jdf       225: extra speed may be a good idea. Other partition schemes may use separate
                    226: partitions for `/var`, `/usr` and/or `/home`, but you should use your own
1.7     ! sevan     227: experience to decide if you need this. When you completed the definition of all the desired partitions, choose *Accept partition sizes*.
1.1       jdf       228: 
1.5       jdf       229: The next step is to create the disklabel and edit its partitions, if necessary,
                    230: using the disklabel editor (see below). If you predefined the partition sizes in
                    231: the previous step, the resulting disklabel will probably fit your wishes. In
                    232: that case you can complete the process immediately by selecting *Partition sizes
1.1       jdf       233: ok*.
                    234: 
                    235: ![The disklabel editor](/guide/images/exinst_disklabel-partitions.png)  
                    236: **The disklabel editor**
                    237: 
1.7     ! sevan     238: In the amd64 port, there are two reserved partitions, `c`, representing the NetBSD partition, and
1.5       jdf       239: `d`, representing the whole disk. You can edit all other partitions by using the
1.7     ! sevan     240: cursor keys and pressing the return key or using the corresponding letters. You can add a partition by selecting an
1.5       jdf       241: unused slot and setting parameters for that partition. The partition editing
1.7     ! sevan     242: screen is shown below. When you are satisfied with all the values, choose *Partition sizes ok".
1.1       jdf       243: 
                    244: ![Disklabel partition editing](/guide/images/exinst_disklabel-partition-editor.png)  
                    245: **Disklabel partition editing**
                    246: 
                    247: ## Setting the disk name
                    248: 
1.5       jdf       249: After defining the partitions in the new disklabel, the last item is to enter a
1.7     ! sevan     250: name for the NetBSD disk as shown below. This can be used later to distinguish
1.1       jdf       251: between disklabels of otherwise identical disks.
                    252: 
                    253: ![Naming the NetBSD disk](/guide/images/exinst_diskname.png)  
                    254: **Naming the NetBSD disk**
                    255: 
                    256: ## Last chance!
                    257: 
1.5       jdf       258: The installer now has all the data it needs to prepare the disk. Nothing has
                    259: been written to the disk at this point, and now is your last chance to abort the
                    260: installation process before actually writing data to the disk. Choose *no* to
                    261: abort the installation process and return to the main menu, or continue by
1.1       jdf       262: selecting *yes*.
                    263: 
                    264: ![Last chance to abort](/guide/images/exinst_last-chance.png)  
                    265: **Last chance to abort**
                    266: 
                    267: ## The disk preparation process
                    268: 
1.5       jdf       269: After confirming that sysinst should prepare the disk, it will run
1.6       plunky    270: [[!template id=man name="disklabel" section="8"]]
1.5       jdf       271: to create the NetBSD partition layout and
1.6       plunky    272: [[!template id=man name="newfs" section="8"]] to
1.1       jdf       273: create the file systems on the disk.
                    274: 
1.5       jdf       275: After preparing the NetBSD partitions and their filesystems, the next question
                    276: (shown in the next figure) is which *bootblocks* to install. Usually you will
                    277: choose the default of *BIOS console*, i.e., show boot messages on your
1.1       jdf       278: computer's display.
                    279: 
1.5       jdf       280: If you run a farm of machines without monitor, it may be more convenient to use
                    281: a serial console running on one of the serial ports. The menu also allows
                    282: changing the serial port's baud rate from the default of 9600 baud, 8 data bits,
1.1       jdf       283: no parity and one stopbit.
                    284: 
                    285: ![Selecting bootblocks](/guide/images/exinst_bootblocks.png)  
                    286: **Selecting bootblocks**
                    287: 
1.7     ! sevan     288: ## Installation type
        !           289: 
        !           290: The installer will then ask whether you want to do a full, minimal or custom
        !           291: installation. NetBSD is broken into a collection of distributions sets. *Full
        !           292: installation* is the default and will install all sets; *Minimal installation*
        !           293: will only install a small core set, the minimum of what is needed for a working
        !           294: system. If you select *Custom installation* you can select which sets you would
        !           295: like to have installed. This step is shown here:
        !           296: 
        !           297: ![Full or custom installation](/guide/images/exinst_install-type.png)  
        !           298: **Full or custom installation**
        !           299: 
        !           300: If you choose to do a custom installation, sysinst will allow you to choose
        !           301: which distribution sets to install, as shown in the following figure. At a
        !           302: minimum, you must select a kernel and the *Base* and *System (/etc)* sets.
        !           303: 
1.1       jdf       304: ## Choosing the installation media
                    305: 
1.5       jdf       306: At this point, you have finished the first and most difficult part of the
1.1       jdf       307: installation!
                    308: 
1.5       jdf       309: The second half of the installation process consists of populating the file
                    310: systems by extracting the distribution sets that you selected earlier (base,
1.7     ! sevan     311: compiler tools, games, etc). Now sysinst needs to find the NetBSD sets and you
        !           312: must tell it where to find them: it can be the same medium where sysinst
        !           313: resides, or a different one, according to your preferences. The menu offers
        !           314: several choices, as shown below. The options are explained in detail in the
        !           315: `INSTALL` documents.
1.1       jdf       316: 
                    317: ![Installation media](/guide/images/exinst_medium.png)  
                    318: **Installation media**
                    319: 
1.7     ! sevan     320: ### Installing from CD-ROM / DVD / install image media
1.1       jdf       321: 
1.7     ! sevan     322: Choose this option if you want to install NetBSD from either an optic medium
        !           323: ("CD-ROM / DVD") or another medium, such as an USB drive. If the running sysinst
        !           324: itself has been loaded from there, the corresponding device will be
        !           325: automatically selected and the extraction of the distribution sets will begin.
1.1       jdf       326: 
1.7     ! sevan     327: ### The CD-ROM/DVD or other device name
1.1       jdf       328: 
1.7     ! sevan     329: If sysinst is not able to detect the CD-ROM/DVD or the USB flash device, you can
        !           330: gather more information about the hardware configuration as follows:
1.1       jdf       331: 
                    332:  1. Press Ctrl-Z to pause sysinst and go to the shell prompt.
                    333: 
                    334:  2. Type the command:
                    335: 
                    336:         # dmesg
                    337: 
                    338:     This will show the kernel startup messages, including the name of the CD-ROM device, for example *cd0*.
                    339: 
                    340:  3. If the display scrolls too quickly, you can also use **more**:
                    341: 
                    342:         # dmesg | more
                    343: 
1.7     ! sevan     344:    This will show the kernel startup messages, including information about not
        !           345:  detected or not configured devices. When the first CD-ROM or DVD drive in the
        !           346:  system is properly working, it is usually named `cd0`, regardless of whether it is
        !           347:  IDE or SCSI (or even USB or FireWire). The first USB flash drive is named sd0
        !           348:  when it is correctly configured.
1.1       jdf       349: 
1.7     ! sevan     350:  4. As instructed, you can return to the NetBSD installation by typing either
        !           351:  `exit` or `^D` (`Ctrl+D`).
1.1       jdf       352: 
                    353: ### Installing from an unmounted file system
                    354: 
1.5       jdf       355: The next figure shows the menu to install NetBSD from an unmounted file system.
1.7     ! sevan     356: It is necessary to specify the device (*Device*), its file system type
        !           357: (*File system*) and a root directory inside it (*Base directory*). The binary
        !           358: sets and source sets are `.tgz` files. The default mountpoint in `mnt` in
        !           359: amd64. The path is formed as follows:
        !           360: 
        !           361:        /<default mountpoint>/<Base directory>/<Binary set directory> or <Source set directory>/set.tgz
        !           362: 
        !           363: Choose a combination of *Base directory* and *Binary set directory* (or *Source set directory*) that generates a valid path in your unmounted filesystem. If more than one consecutive `/` appear, only the first `/` will actually be considered. You need to specify a *Source set directory* only if you previously chose to install some sources. Source sets are usually not included in the installation images.
1.1       jdf       364: 
1.5       jdf       365: In the following example the install sets are stored on a *MSDOS* file system,
1.1       jdf       366: on partition `e` on the device `sd0`.
                    367: 
                    368: ![Mounting a file system](/guide/images/exinst_mount.png)  
                    369: **Mounting a file system**
                    370: 
1.7     ! sevan     371: Specify the device name and the partition. The
1.1       jdf       372: following figure shows how to specify device `sd0` with partition `e`.
                    373: 
                    374: ![Mounting a partition](/guide/images/exinst_mount-partition.png)  
                    375: **Mounting a partition**
                    376: 
1.7     ! sevan     377: In the next figure, the file system type specified is `msdos`. This value is
        !           378: used to form the command `mount_<File system>` to mount the volume. Any string
        !           379: (representing a "File system" type) which forms a valid command is accepted: for
        !           380: example, the NetBSD file system "ffs" or "ext2fs", a Linux file system.
        !           381: In this example, the *Base directory* item is left blank and the binary sets are
        !           382: stored under `/sets`, so that the path becomes:
        !           383: 
        !           384:        /mnt///sets
        !           385: 
        !           386: Ignoring the multiple /, this is equivalent to /mnt/sets and it is a valid one.
1.1       jdf       387: Choosing *Continue* will start the extraction of the sets.
                    388: 
                    389: ![Accessing a MSDOS file system](/guide/images/exinst_mount-msdos.png)  
                    390: **Accessing a MSDOS file system**
                    391: 
1.7     ! sevan     392: ### Installing via FTP and Network configuration
1.1       jdf       393: 
1.5       jdf       394: If you choose to install from a local network or the Internet via FTP, sysinst
1.7     ! sevan     395: must be instructed to properly get the distribution sets, as shown below.
        !           396: 
        !           397: The defaults work most of the time. You also need to configure your network
        !           398: connection, before proceeding: go to the corresponding menu item, pressing
        !           399: letter *j*.
1.1       jdf       400: 
1.5       jdf       401: NetBSD currently supports installation via ethernet, USB ethernet or wireless,
                    402: and wireless LAN. Installation via DSL (PPP over Ethernet) is not supported
1.1       jdf       403: during installation.
                    404: 
1.5       jdf       405: The first step shown in the next figure further below consists of selecting
                    406: which network card to configure. sysinst will determine a list of available
1.1       jdf       407: network interfaces, present them and ask which one to use.
                    408: 
1.5       jdf       409: *Note*: The exact names of your network interfaces depend on the hardware you
                    410: use. Example interfaces are `wm` for Intel Gigabit interfaces, `ne` for NE2000
                    411: and compatible ethernet cards, and `ath` for Atheros based wireless cards. This
1.1       jdf       412: list is by no means complete, and NetBSD supports many more network devices.
                    413: 
1.5       jdf       414: To get a list of network interfaces available on your system, interrupt the
1.1       jdf       415: installation process by pressing `Ctrl+Z`, then enter
                    416: 
                    417:     # ifconfig -a
1.7     ! sevan     418:     wm0: flags=0x8802<BROADCAST,SIMPLEX,MULTICAST> mtu 1500
        !           419:             capabilities=2bf80<TSO4,IP4CSUM_Rx,IP4CSUM_Tx,TCP4CSUM_Rx>
        !           420:             capabilities=2bf80<TCP4CSUM_Tx,UDP4CSUM_Rx,UDP4CSUM_Tx,TCP6CSUM_Tx>
        !           421:             capabilities=2bf80<UDP6CSUM_Tx>
        !           422:             enabled=0
        !           423:             ec_capabilities=7<VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU>
        !           424:             ec_enabled=0
        !           425:             address: 08:00:27:7e:85:d7
        !           426:             media: Ethernet autoselect (1000baseT full-duplex)
1.1       jdf       427:             status: active
1.7     ! sevan     428:     lo0: flags=0x8048<LOOPBACK,RUNNING,MULTICAST> mtu 33624
1.1       jdf       429: 
1.7     ! sevan     430: If the desired interface has not been shown, get more information about all the
        !           431: devices found during system boot. Type:
1.1       jdf       432: 
                    433:     # dmesg | more
                    434: 
1.7     ! sevan     435: As instructed, you can return to the NetBSD installation by typing either `exit`
        !           436: or `^D` (`Ctrl+D`).
        !           437: 
        !           438: Next, you have a chance to set your network medium. Press *Enter* to choose the
        !           439: default.
        !           440: 
        !           441: *Note*: It is unlikely that you will need anything other than the default here.
        !           442: If you experience problems like very slow transfers or timeouts, you may, for
        !           443: example, force different duplex settings for ethernet cards. To get a list of
        !           444: supported media and media options for a given network device ("wm0", for
        !           445: example), escape from sysinst by pressing `Ctrl+Z`, then enter:
1.1       jdf       446: 
1.7     ! sevan     447:     # ifconfig -m wm0
        !           448:     wm0: flags=0x8802<BROADCAST,SIMPLEX,MULTICAST> mtu 1500
        !           449:             capabilities=2bf80<TSO4,IP4CSUM_Rx,IP4CSUM_Tx,TCP4CSUM_Rx>
        !           450:             capabilities=2bf80<TCP4CSUM_Tx,UDP4CSUM_Rx,UDP4CSUM_Tx,TCP6CSUM_Tx>
        !           451:             capabilities=2bf80<UDP6CSUM_Tx>
        !           452:             enabled=0
        !           453:             ec_capabilities=7<VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU>
        !           454:             ec_enabled=0
        !           455:             address: 08:00:27:7e:85:d7
        !           456:             media: Ethernet autoselect (1000baseT full-duplex)
        !           457:             status: active
        !           458:             supported Ethernet media:
        !           459:                     media none
        !           460:                     media 10baseT
        !           461:                     media 10baseT mediaopt full-duplex
        !           462:                     media 100baseTX
        !           463:                     media 100baseTX mediaopt full-duplex
        !           464:                     media autoselect
        !           465: 
        !           466: The several values printed after `media` may be of interest here, including
        !           467: keywords like `autoselect` but also including any `mediaopt` settings.
        !           468: 
        !           469: Return to the installation by typing `exit` or `^D` (`Ctrl+D`).
1.1       jdf       470: 
                    471: ![Which network interface to configure](/guide/images/exinst_ftp-if.png)  
                    472: **Which network interface to configure**
                    473: 
                    474: Next, you have a chance to set your network medium.
                    475: 
1.5       jdf       476: *Note*: It is unlikely that you will need to enter anything other than the
                    477: default here. If you experience problems like very slow transfers or timeouts,
                    478: you may, for example, force different duplex settings for ethernet cards. To get
                    479: a list of supported media and media options for a given network device (ne2, for
1.1       jdf       480: example), escape from sysinst by pressing `Ctrl+Z`, then enter:
                    481: 
                    482:     # ifconfig -m ne2
                    483:     ne2: flags=8822<UP,BROADCAST,NOTRAILERS,SIMPLEX,MULTICAST> mtu 1500
                    484:             address: 00:03:0d:c6:73:d5
                    485:             media: Ethernet 10baseT full-duplex
                    486:             status: active
                    487:             supported Ethernet media:
                    488:                     media 10baseT
                    489:                     media 10baseT mediaopt full-duplex
                    490:                     media 10base2
                    491:                     media autoselect
                    492: 
1.5       jdf       493: The various values printed after `media` may be of interest here, including
1.1       jdf       494: keywords like `autoselect` but also including any `mediaopt` settings.
                    495: 
                    496: Return to the installation by typing:
                    497: 
                    498:     # fg
                    499: 
1.5       jdf       500: The next question will be whether you want to perform DHCP autoconfiguration as
                    501: shown in the figure below. Answer *Yes* if you have a DHCP *Dynamic Host
                    502: Configuration Protocol* (DHCP) running somewhere on your network, and sysinst
                    503: will fetch a number of defaults from it. Answer *No* to enter all the values
1.1       jdf       504: manually.
                    505: 
                    506: We will assume you answered *No* and go into all the questions asked in detail.
                    507: 
                    508: ![Using DHCP for network configuration](/guide/images/exinst_ftp-dhcp.png)  
                    509: **Using DHCP for network configuration**
                    510: 
1.5       jdf       511: The image below shows the questions asked for the network configuration. The
1.1       jdf       512: values to be entered are:
                    513: 
                    514:  * *Your DNS Domain:* -- This is the name of the domain you are in.
1.5       jdf       515:  * *Your hostname:* -- The name by which other machines can usually address your
1.1       jdf       516:    computer. Not used during installation.
1.5       jdf       517:  * *Your IPv4 number:* -- Enter your numerical Internet Protocol address in
1.1       jdf       518:    *dotted quad* notation here, for example, 192.168.1.3
1.5       jdf       519:  * *IPv4 Netmask:* -- The netmask for your network, either given as a hex value
1.1       jdf       520:    (`0xffffff00`) or in dotted-quad notation (`255.255.255.0`).
1.5       jdf       521:  * *IPv4 gateway:* -- Your router's (or default gateway's) IP address. Do not
1.1       jdf       522:    use a hostname here!
1.5       jdf       523:  * *IPv4 name server:* -- Your (first) DNS server's IP address. Again, don't use
1.1       jdf       524:    a hostname.
                    525: 
                    526: ![Entering and configuring network data](/guide/images/exinst_ftp-cfg.png)  
                    527: **Entering and configuring network data**
                    528: 
1.5       jdf       529: After answering all of your network configuration info, it will be displayed,
1.1       jdf       530: and you will have a chance to go back and make changes.
                    531: 
                    532: ![Confirming network parameters](/guide/images/exinst_ftp-cfgok.png)  
                    533: **Confirming network parameters**
                    534: 
1.5       jdf       535: sysinst will now run a few commands (not displayed in detail here) to configure
                    536: the network: flushing the routing table, setting the default route, and testing
1.1       jdf       537: if the network connection is operational.
                    538: 
1.5       jdf       539: Now that you have a functional network connection, you must tell the installer
1.1       jdf       540: how to get the distribution sets, as shown in the next figure.
                    541: 
1.5       jdf       542: When you are satisfied with your settings (the defaults work most of the time),
1.1       jdf       543: choose *Get Distribution* to continue.
                    544: 
                    545: ![Defining the FTP settings](/guide/images/exinst_ftp-src.png)  
                    546: **Defining the FTP settings**
                    547: 
                    548: ### Installing via NFS
                    549: 
1.5       jdf       550: If you want to install NetBSD from a server in your local network, NFS is an
1.1       jdf       551: alternative to FTP.
                    552: 
1.5       jdf       553: *Note*: Using this installation method requires the ability to set up an NFS
1.1       jdf       554: server, a topic which is not discussed here.
                    555: 
1.5       jdf       556: As shown below, you must specify the IP address of the NFS server with "Host",
                    557: the "Base directory" that is *exported* by the NFS server, and the "Set
1.1       jdf       558: directory", which contains the install sets.
                    559: 
                    560: ![NFS install screen](/guide/images/exinst_nfs.png)  
                    561: **NFS install screen**
                    562: 
1.5       jdf       563: The following image shows an example: Host `192.168.1.50` is the NFS server that
                    564: provides the directory `/home/username/Downloads` The NetBSD install sets are
                    565: stored in the directory `/home/username/Downloads/sets` on the NFS server.
1.1       jdf       566: Choose *Continue* to start the installation of the distribution sets.
                    567: 
                    568: ![NFS example](/guide/images/exinst_nfs-example.png)  
                    569: **NFS example**
                    570: 
                    571: ## Extracting sets
                    572: 
1.5       jdf       573: After the method for obtaining distribution sets has been chosen, and (if
                    574: applicable) after those sets have been transferred, they will be extracted into
1.1       jdf       575: the new NetBSD file system.
                    576: 
1.5       jdf       577: After extracting all selected sets, sysinst will create device nodes in the
1.1       jdf       578: `/dev` directory and then display a message saying that everything went well.
                    579: 
1.5       jdf       580: Another message will let you know that the set extraction is now completed, and
                    581: that you will have an opportunity to configure some essential things before
1.1       jdf       582: finishing the NetBSD installation:
                    583: 
                    584: ![Extraction of sets completed](/guide/images/exinst_extraction-complete.png)  
                    585: **Extraction of sets completed**
                    586: 
                    587: ## System configuration
                    588: 
1.5       jdf       589: Having reached this point of the installation you will see the configuration
1.4       jdf       590: menu:
1.1       jdf       591: 
1.4       jdf       592: ![Configuration menu](/guide/images/exinst_configuration_menu.png)  
                    593: **Configuration menu**
                    594: 
                    595: Here, you can do the following:
                    596: 
                    597:  * *Configure network* -- make changes to the network settings on the installed
1.5       jdf       598:    system, i.e. either configure it or if you already did, write that
1.4       jdf       599:    configuration to disk.
                    600: 
                    601:  * *Timezone* -- set your time zone.
                    602: 
1.5       jdf       603:  * *Root shell* -- this potion allows you to choose which command line
1.4       jdf       604:    interpreter, also known as *shell*, will be used for the root account.
                    605: 
                    606:  * *Change root password* -- set the password you will use to login in as root.
                    607: 
1.5       jdf       608:  * *Enable installation of binary packages* -- this option enables the
1.4       jdf       609:    installation of binary packages (3rd party software).
                    610: 
1.5       jdf       611:  * *Fetch and unpack pkgsrc for building from source* -- install the pkgsrc
                    612:    tree for installing third-party software from source.
1.4       jdf       613: 
1.5       jdf       614:  * *Enable sshd* -- enable the secure shell daemon sshd(8) to allow users to
1.4       jdf       615:    login over an insecure network.
                    616: 
                    617:  * *Enable ntpd* -- ntpd(8) is the daemon to keep the system time accurate.
                    618: 
                    619:  * *Run ntpdate at boot* -- sets the local date and time.
                    620: 
1.5       jdf       621:  * *Enable mdnsd* -- a daemon invoked at boot time to implement Multicast DNS
1.4       jdf       622:    and DNS Service Discovery.
                    623: 
                    624: #### Configure network
                    625: 
1.5       jdf       626: The process was already described previously, you can just call it again and
1.4       jdf       627: have the results directly written to disk.
                    628: 
                    629: #### Timezone
                    630: 
1.5       jdf       631: The timezone is Universal Time Coordinated (UTC) by default, and you can use the
                    632: two-level menu of continents/countries and cities shown in the figure below to
1.4       jdf       633: select your timezone with the Return Key.
                    634: 
                    635: ![Timezone selection](/guide/images/exinst_timezone.png)  
1.1       jdf       636: **Selecting the system's time zone**
                    637: 
1.4       jdf       638: #### Root Shell
                    639: 
1.5       jdf       640: The default is the classic Bourne shell, sh(1). Other choices are the Korn shell
                    641: (ksh(1)) and the C shell(csh(1)). If, upon reading this, you don't have some
                    642: idea of which shell you prefer, simply use the default, as this is a highly
                    643: subjective decision. Should you later change your mind, root's shell can always
1.4       jdf       644: be changed with the chsh(1) command or by directly editing master.passwd(5).
                    645: 
                    646: ![Root Shell](/guide/images/exinst_rootshell.png)  
                    647: **Root Shell**
                    648: 
                    649: #### Change root password
                    650: 
1.5       jdf       651: Perhaps one of the things that you would want to configurate is your root
                    652: password. If you don't, it is unset, i.e. you can login as root just by entering
1.4       jdf       653: the login name without a password.
                    654: 
                    655: ![Change root password](/guide/images/exinst_change_root_password.png)  
                    656: **Change root password**
                    657: 
1.5       jdf       658: When you agree to set a root password, sysinst will run the passwd(1) utility
1.4       jdf       659: for you. Please note that the password is not echoed:
                    660: 
                    661: ![Entering root password](/guide/images/exinst_entering_root_password.png)  
                    662: **Entering the root password**
                    663: 
                    664: #### Enable installation of binary packages
                    665: 
1.5       jdf       666: This option installs pkgin(1) and initialises its database. This will feel
1.4       jdf       667: familiar to users of other package tools, such as apt-get, pkg or yum.
                    668: 
1.5       jdf       669: Note that installing pkgin will need a network connection. If you didn't set it
1.4       jdf       670: up yet, this option will call the configuration for you.
                    671: 
                    672: ![Enable installation of binary packages](/guide/images/exinst_pkgin.png)  
                    673: **Enable installation of binary packages**
                    674: 
1.5       jdf       675: When the installation is finished, a short help is provided, and you can return
1.4       jdf       676: to the main menu:
                    677: 
                    678: ![After enabling installation of binary packages](/guide/images/exinst_pkgin_after.png)  
                    679: **After enabling installation of binary packages**
                    680: 
                    681: #### Fetch and unpack pkgsrc for building from source.
                    682: 
1.5       jdf       683: Use this option to download the [pkgsrc](http://pkgsrc.org) tree to install
                    684: additional packages by source. Note that this method in many cases conflicts
                    685: with binary packages, so you should decide for either one of them or use
1.4       jdf       686: different directories for installing packages.
                    687: 
1.5       jdf       688: This will require a network connection set up, otherwise, it will ask for it
1.4       jdf       689: itself.
                    690: 
                    691: ![Fetch and unpack pkgsrc](/guide/images/exinst_fetch_and_unpack_pkgsrc.png)  
                    692: **Fetch and unpack pkgsrc for building from source**
                    693: 
1.5       jdf       694: This step will take a while, as pkgsrc consists of many small files which have
1.4       jdf       695: to be unpacked on your hard disk, and several 10MB have to be downloaded.
                    696: 
                    697: #### Enabling daemons
                    698: 
1.5       jdf       699: Finally, you can enable some daemons such as sshd(8), ntpd(8) or mdnsd(8) and
                    700: choose whether you want to run ntpdate(8) at boot, which will set the time no
                    701: matter how large the gap between "real" time and you computer's time is. ntpd
1.4       jdf       702: will not set the time when the time skew is too large.
                    703: 
1.5       jdf       704: *Note*: You can change these settings any time you want after the installation.
                    705: You can either do this by directly editing the configuration files, or by
                    706: running sysinst(8) again (either from the running system, or from an
1.4       jdf       707: installation CD).
1.1       jdf       708: 
1.5       jdf       709: *Note*: When you run this menu when you already installed NetBSD, but want to
                    710: configure the running system, you have to choose the hard disk NetBSD is
                    711: installed on. When sysinst doesn't find an NetBSD installation, it will fail,
1.4       jdf       712: and you have to choose another disk.
1.1       jdf       713: 
                    714: ## Finishing the installation
                    715: 
                    716: At this point the installation is finished.
                    717: 
                    718: ![Installation completed](/guide/images/exinst_completed.png)  
                    719: **Installation completed**
                    720: 
1.5       jdf       721: After passing the dialog that confirms the installation, sysinst will return to
                    722: the main menu. Remove any installation media (CD, floppy, etc.) and choose
1.1       jdf       723: *Reboot the computer* to boot your new NetBSD installation.
                    724: 
                    725: ![Reboot to finish installation](/guide/images/exinst_reboot.png)  
                    726: **Reboot to finish installation**
                    727: 

CVSweb for NetBSD wikisrc <wikimaster@NetBSD.org> software: FreeBSD-CVSweb