Diff for /wikisrc/guide/inst-media.mdwn between versions 1.3 and 1.4

version 1.3, 2015/06/19 19:18:31 version 1.4, 2021/04/12 13:15:03
Line 1 Line 1
 **Contents**  This page was moved to:
   [The NetBSD Guide - Building NetBSD installation media](//www.NetBSD.org/docs/guide/en/chap-inst-media.html)
 [[!toc levels=3]]  
 # Building NetBSD installation media  
 ## Creating custom install or boot floppies for your architecture e.g. i386  
 Sometimes you may want to create your own boot or install floppies for i386  
 instead of using the precompiled ones, or tailor the ones built by the NetBSD  
 build system. This section outlines the steps to do so.  
 The overall idea is to have a filesystem with some tools (sysinst, ls,  
 whatever), and embed this filesystem as some sort of ramdisk into a NetBSD  
 kernel. The kernel needs to include the `md` pseudo device to be able to hold a  
 ramdisk. The kernel with the ramdisk can then be put on removable media or made  
 available via the net (using NFS or TFTP).  
 To perform the following steps, you need to be running a kernel with the `vnd`  
 pseudo device enabled (this is the default for a GENERIC kernel).  
  1. First, you must create a valid kernel to put on your floppies, e.g.  
     INSTALL. This kernel must include the `md` pseudo device, which allows  
     embedding a ramdisk. See [[Compiling the kernel|guide/kernel]] for kernel  
         building instructions.  
  2. The next step is to create the ramdisk that gets embedded into the kernel.  
     The ramdisk contains a filesystem with whatever tools are needed, usually  
         [[!template id=man name="init" section="8"]] and  
     some tools like sysinst,  
         [[!template id=man name="ls" section="1"]], etc.  
         To create the standard ramdisk, run `make` in the  
     `src/distrib/i386/ramdisks/ramdisk-big` directory (for NetBSD 3.x:  
         This will create the `ramdisk.fs` file in the directory. If you want to  
         customize the contents of the filesystem, customize the `list` file.  
  3. Now, the ramdisk gets inserted into the kernel, producing a new kernel which  
     includes the ramdisk, all in one file. To do so, change into the  
     `src/distrib/i386/instkernel` directory (for NetBSD 3.x:  
     `src/distrib/i386/floppies/instkernel`) and run `make`.  
  4. The next step is to make one or more floppy images, depending on the size of  
     the kernel (including the ramdisk). This is done by changing into  
     `/usr/src/distrib/i386/floppies/bootfloppy-big`, and running `make` again.  
         This will create one or two (depending on the size of kernel) files named  
         `boot1.fs` and `boot2.fs`  
  5. Last, transfer these files to the floppies with the commands  
         # dd if=boot1.fs of=/dev/fd0a bs=36b  
         # dd if=boot2.fs of=/dev/fd0a bs=36b  
  6. Put the first floppy in the drive and power on!  
 ## Creating a custom install or boot CD with build.sh  
 Creating custom install or boot CDs is easy with `build.sh`. The NetBSD base  
 system includes the  
 [[!template id=man name="makefs" section="8"]]  
 tool for creating filesystems. This tool is used to create iso-images. Creating  
 iso-images includes these tasks:  
  1. Release build  
         #./build.sh release  
  2. CD-ROM iso-image build  
         #./build.sh iso-image  
 The `build.sh` iso-image command will build a CD-ROM image in  
 **Warning**: For now not all architectures are supported. The mac/68k ports  
 doesn't boot for now.  

Removed from v.1.3  
changed lines
  Added in v.1.4

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