2010/03/22

The Labs.Com OS Lab NetBSD
Last update 2004/07/14

The Labs - Design & Functionality For The Net

Yet Another BSD UNIX Distribution

The BSD Family: FreeBSD, OpenBSD, NetBSD, DragonFlyBSD.
  1. Introduction
  2. Installation with VMWare
  3. Packages
  4. Tuning
  5. ...
NetBSD
1. Introduction
NetBSD impresses with the wide variety of supported CPU and platforms, even supports more platforms than Linux, and this means a lot.

From their mission-statement: "Probably the primary goal of the NetBSD project is emphasizing correct design and well written code."

NetBSD.org
Primary site
DaemonNews.Org
*BSD info site
BSDToday.Com
Another news-site

NetBSD
2. Installation with VMWare

VMWare is very handy to run and test multiple operating-systems without much overhead and disk-partitioning; also this way you can move entire file-systems (which when done as virtual-disk) as files between machines.

Installation NetBSD-1.4.2 (update 03/2003: NetBSD-1.6 also boots) with VMWare was easy and rather user-friendly (compared to OpenBSD). Just run Wizard within vmware, chose "Other" for Operating System, virtual-disk, etc, power-on and have NetBSD-CD insert, and go ahead, and you are done in few mins.


VMWare booting NetBSD 1.4.2 (K6-2/500 with 64MB)

Next steps:

  1. define in /etc/myname the hostname, in /etc/defaultdomain your domain-name (e.g. local), or define the settings in /etc/rc.conf (lines hostname= and domainname=)
  2. edit /etc/resolv.conf and add (assuming your dns runs at 192.168.0.1)

     search local 
     nameserver 192.168.0.1 

  3. create /etc/ifconfig.le0 with following line (having 192.168. network)

     192.168.0.51 netmask 255.255.255.0 broadcast 192.168.0.255 

  4. additionally I installed the /usr/pgksrc (check NetBSD: Documentation)
Check the dmesg :-)

BSD Disklayout

 The BSD disklayout as experienced on the i386 platform follows a convention important to realize. You can install *BSD within a disk-partition, which is known as a slice using the BSD-terminology. Within this slice are the partitions layed out, starting with 'a', 'b', and so forth.
  • b-partition is reserved for swap,
  • c-partition for the slice and won't be used,
  • d-partition is the entire disk and won't be used either but just is there for reference purposes.
This leaves partitions a, e, f, and so forth for data:

 % disklabel wd0 
 # /dev/rwd0d: 
 .... 
 #        size   offset     fstype   [fsize bsize   cpg] 
   a:   174762       63     4.2BSD     1024  8192    16   # (Cyl.    0*- 184) 
   b:   133245   174825       swap                        # (Cyl.  185 - 325) 
   c:  1023372       63     unused        0     0         # (Cyl.    0*- 1082) 
   d:  1023435        0     unused        0     0         # (Cyl.    0 - 1082) 
   e:   715365   308070     4.2BSD     1024  8192    16   # (Cyl.  326 - 1082) 

NetBSD
3. Packages

Packages are the jewel of the *BSD distributions, also NetBSD in this case. Under NetBSD the 'Ports' (FreeBSD) are known as 'Package-Sources', so either the package is availale as source (/usr/pkgsrc) or precompiled (/usr/pkg).

 cd /usr/pkgsrc/ 

and explore the ports there are available.

Installing apache + mod_perl (as root)

 % cd /usr/pkgsrc/www/ap-perl 
 % make install 

and it does all: fetching apache-source (or precompiled version of it) and all dependend packages and libs, configuring them and compiling if you build if from pkgsrc. If you want to just make it without install, obmit 'install'. If you want to remove the port, just type make deinstall and the install is undone. Unlike in case of FreeBSD and OpenBSD, NetBSD's packages are installed in /usr/pkg/bin/.

NetBSD
4. Tuning

Kernel

 
NetBSD Kernel Compiling
Some hints for FreeBSD users

rc.d System

 Since 1.5 a new rc.d system was introduced:
DaemonNews: The NetBSD rc.d System
Good intro article

NetBSD
5. ...

More infos later ...

                                                                                                                                   

OpenBSD OS LabDragonFlyBSD

Hipocrisy of the finest: "I agree that no single company can create all the hardware and software. Openness is central because it's the foundation of choice."
-- Steve Balmer (Microsoft) blaming Apple regarding iPhone, February 18, 2009

Last update 2004/07/14

All Rights Reserved - (C) 1997 - 2009 by The Labs.Com

Top of Page

The Labs.Com