Recent changes to this wiki:

no source ISO images in the future.
Index: wikisrc/releng/release-prep.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/releng/release-prep.mdwn,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -r1.17 -r1.18
--- wikisrc/releng/release-prep.mdwn	7 Nov 2014 04:32:36 -0000	1.17
+++ wikisrc/releng/release-prep.mdwn	24 Jan 2015 07:49:06 -0000	1.18
@@ -98,7 +98,7 @@
    preserve the -B flag's argument.  Copy the results back to build.netbsd.org
    and proceed.
 
-8. Create ISOs (macppc, mac68k, source).  See below for instructions.
+8. Create ISOs (macppc and mac68k).  See below for instructions.
    Create hashes for ISOs (<code>cksum -a sha512 NetBSD* > SHA512</code>)
 
 9. rsync to nbftp.  It goes to a staging dir in /pub/NetBSD/misc/releng first.
@@ -169,7 +169,7 @@
 The following stuff should be done on build.netbsd.org as the 'builds'
 user.
 
-Images that need to be built manually: macppc, mac68k, source
+Images that need to be built manually: macppc and mac68k
 
 Needs to be cdrtools 2.01 (but not newer!).  The binary in ~/bin/mkisofs
 will work.
@@ -182,8 +182,7 @@
 Copy and fiddle with some ridiculous .mk and .conf files, adjusting for the
 relevant release.
 
-Do the following three times, changing TARGET_CD_IMAGE to macppccd, mac68kcd,
-and sourcecd.
+Do the following two times, changing TARGET_CD_IMAGE to macppccd and mac68kcd.
 
         make MKISOFS=/home/builds/bin/mkisofs USETOOLS=no RELEASE=5.0 TARGET_CD_IMAGE=macppccd DISTRIBDIR=/home/builds/ab/netbsd-5-0-RC4/release/netbsd-5-0-RC4/200904142015Z all
 

mention that 4.5 has just arrived, but is not ready
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.84
retrieving revision 1.85
diff -u -r1.84 -r1.85
--- wikisrc/ports/xen/howto.mdwn	17 Jan 2015 13:18:50 -0000	1.84
+++ wikisrc/ports/xen/howto.mdwn	20 Jan 2015 21:47:14 -0000	1.85
@@ -92,10 +92,13 @@
 xenkernel42 provides Xen 4.2.  This is maintained by Xen, but old as
 of 2014-12.
 
+xenkernel45 provides Xen 4.5.  This is new to pkgsrc as of 2015-01 and
+not yet recommended for other than experimental/testing use.
+
 Ideally newer versions of Xen will be added to pkgsrc.
 
-Note that NetBSD support is called XEN3.  It works with 3.1 through
-4.2 because the hypercall interface has been stable.
+Note that NetBSD support is called XEN3.  It works with Xen 3 and Xen
+4 because the hypercall interface has been stable.
 
 Xen command program
 -------------------

mention pushlog extension.
Index: wikisrc/users/dholland/hgpath.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/users/dholland/hgpath.mdwn,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- wikisrc/users/dholland/hgpath.mdwn	18 Jan 2015 18:43:32 -0000	1.7
+++ wikisrc/users/dholland/hgpath.mdwn	19 Jan 2015 13:31:33 -0000	1.8
@@ -110,7 +110,10 @@
 
 Backend/admins deployment issues
 
-* how commits get pushed to the master tree
+* how commits get pushed to the master tree (log who's pushing
+  what, e.g. using the
+  [[pushlog|http://hg.mozilla.org/hgcustom/version-control-tools/summary]]
+  extension from mozilla)
 * log_accum / source-changes mails
 * access control for whole trees
 * access control for subsections of trees

add an item
Index: wikisrc/users/dholland/hgpath.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/users/dholland/hgpath.mdwn,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- wikisrc/users/dholland/hgpath.mdwn	18 Jan 2015 17:57:21 -0000	1.6
+++ wikisrc/users/dholland/hgpath.mdwn	18 Jan 2015 18:43:32 -0000	1.7
@@ -128,6 +128,8 @@
 
 * running live in parallel with CVS during a transition period
 * gatewaying to other VCS frontends
+* rcsids in source files
+
 
 
 

add an item
Index: wikisrc/users/dholland/hgpath.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/users/dholland/hgpath.mdwn,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- wikisrc/users/dholland/hgpath.mdwn	17 Jan 2015 20:47:55 -0000	1.5
+++ wikisrc/users/dholland/hgpath.mdwn	18 Jan 2015 17:57:21 -0000	1.6
@@ -65,7 +65,7 @@
 * non-ascii text in log messages
 * version references in log messages
 * retaining CVS file version numbers as metadata
-* restoring the pre-settlement history and/or including the CSRG history
+* restoring the pre-USL-settlement history and/or including the CSRG history
 
 Implementation concerns (demands on the system as it exists)
 
@@ -94,11 +94,12 @@
 * how to refer to other commits in log messages
 
 Many of these issues are already documented in [[the existing
-workflows writeup|hgnb.mdwn]].
+workflows writeup|hgnb]].
 
 Releng deployment issues
 
 * changes to the way pullups are filed
+* adjusting processing scripts for new source-changes format
 * release commit procedures
 * release branch procedures
 * dealing with accidental commits to release branches
@@ -109,6 +110,7 @@
 
 Backend/admins deployment issues
 
+* how commits get pushed to the master tree
 * log_accum / source-changes mails
 * access control for whole trees
 * access control for subsections of trees

fix more markup fail
Index: wikisrc/users/dholland/hgpath.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/users/dholland/hgpath.mdwn,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- wikisrc/users/dholland/hgpath.mdwn	17 Jan 2015 20:40:35 -0000	1.4
+++ wikisrc/users/dholland/hgpath.mdwn	17 Jan 2015 20:47:55 -0000	1.5
@@ -50,9 +50,7 @@
 * numbered versions
 * branch handling
 * tag handling
-* partial checkouts
-**   partial trees
-**   partial history
+* partial checkouts (partial trees, partial history)
 * blacklist extension (which is a legal requirement)
 * being able to migrate away in the future
 * ...

fix link
Index: wikisrc/users/dholland/hgpath.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/users/dholland/hgpath.mdwn,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- wikisrc/users/dholland/hgpath.mdwn	17 Jan 2015 20:39:55 -0000	1.3
+++ wikisrc/users/dholland/hgpath.mdwn	17 Jan 2015 20:40:35 -0000	1.4
@@ -37,7 +37,7 @@
 This includes not just user-facing things like commit procedures but
 also backend considerations and administration.
 
-There's a [[second page|hgtodo.mdwn]] with a list of work that needs
+There's a [[second page|hgtodo]] with a list of work that needs
 to be done.
 
 ### Issues

I guess lists can't have headings per se
Index: wikisrc/users/dholland/hgpath.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/users/dholland/hgpath.mdwn,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- wikisrc/users/dholland/hgpath.mdwn	17 Jan 2015 20:39:17 -0000	1.2
+++ wikisrc/users/dholland/hgpath.mdwn	17 Jan 2015 20:39:55 -0000	1.3
@@ -58,6 +58,7 @@
 * ...
 
 Conversion of CVS repository phenomena
+
 * vendor branches
 * conversion of repo-copies and similar CVS horrors
 * adding rename metadata to already-done moves
@@ -69,6 +70,7 @@
 * restoring the pre-settlement history and/or including the CSRG history
 
 Implementation concerns (demands on the system as it exists)
+
 * general performance
 * importing into base, or not
 * storage requirements vs. small systems
@@ -77,12 +79,14 @@
 * ...
 
 Community deployment issues
+
 * what becomes of anoncvs
 * making use of version numbers in mailing lists / security advisories
 * patches/contributions/commits from non-developers
 * collaborating with non-developers
   
 Developer deployment issues
+
 * commit procedures
 * development branch procedures
 * vendor branch procedures
@@ -95,6 +99,7 @@
 workflows writeup|hgnb.mdwn]].
 
 Releng deployment issues
+
 * changes to the way pullups are filed
 * release commit procedures
 * release branch procedures
@@ -105,6 +110,7 @@
 * ...
 
 Backend/admins deployment issues
+
 * log_accum / source-changes mails
 * access control for whole trees
 * access control for subsections of trees
@@ -113,11 +119,13 @@
 * ...
 
 cvs assumptions / scripted usage in the tree
+
 * pkgsrc: changes-entry and commit-changes-entry
 * pkgsrc: guide regen
 * ...
 
 Other questions
+
 * running live in parallel with CVS during a transition period
 * gatewaying to other VCS frontends
 

as usual, mdwn hates me
Index: wikisrc/users/dholland/hgpath.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/users/dholland/hgpath.mdwn,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- wikisrc/users/dholland/hgpath.mdwn	17 Jan 2015 20:37:20 -0000	1.1
+++ wikisrc/users/dholland/hgpath.mdwn	17 Jan 2015 20:39:17 -0000	1.2
@@ -43,6 +43,7 @@
 ### Issues
 
 Technical concerns (demands on the system's operational model)
+
 * atomic commits / changesets
 * rename support
 * authenticating commits

Some Mercurial stuff.
--- /dev/null	2015-01-17 20:32:00.000000000 +0000
+++ wikisrc/users/dholland/hgpath.mdwn	2015-01-17 20:37:23.000000000 +0000
@@ -0,0 +1,125 @@
+## NetBSD migration path to Mercurial
+
+This page describes what's involved in migrating NetBSD from CVS to
+Mercurial.
+
+### What Mercurial is
+
+[[Mercurial|http://mercurial.selenic.com]] is an open-source version
+control system.
+It is a distributed version control system based on the commit
+hashcode model shared with git and other DVCSes.
+It is fast and powerful and has long emphasized a certain polish of
+production.
+
+### Why Mercurial
+
+Mercurial is a modern VCS; it is maintained; it is capable of
+handling the NetBSD repositories; and it is cleanly designed, simple,
+and easy to use.
+The first three of these properties are necessary requirements for
+NetBSD to migrate (I don't think any of them are particularly
+controversial); the last sets it apart from git, which is the other
+immediately available alternative.
+(The third option, writing our own, is not currently realistic.)
+
+One could write a lot of gung-ho IT IS REALLY GR8!!!11!! boosterism
+here too, of course, but I'll leave that for someone else.
+
+### Migration
+
+There are two categories of issues related to migrating a project the
+size of NetBSD: first, what the project and the world around the
+project will look like after the migration is done, and second, what
+things need to be done to get there.
+The purpose of this page is to tackle the first: what things in the
+project will be different and what they'll be like.
+This includes not just user-facing things like commit procedures but
+also backend considerations and administration.
+
+There's a [[second page|hgtodo.mdwn]] with a list of work that needs
+to be done.
+
+### Issues
+
+Technical concerns (demands on the system's operational model)
+* atomic commits / changesets
+* rename support
+* authenticating commits
+* numbered versions
+* branch handling
+* tag handling
+* partial checkouts
+**   partial trees
+**   partial history
+* blacklist extension (which is a legal requirement)
+* being able to migrate away in the future
+* ...
+
+Conversion of CVS repository phenomena
+* vendor branches
+* conversion of repo-copies and similar CVS horrors
+* adding rename metadata to already-done moves
+* pkgsrc not-really-vendor imports
+* developer usernames vs. email addresses in log messages and commit metadata
+* non-ascii text in log messages
+* version references in log messages
+* retaining CVS file version numbers as metadata
+* restoring the pre-settlement history and/or including the CSRG history
+
+Implementation concerns (demands on the system as it exists)
+* general performance
+* importing into base, or not
+* storage requirements vs. small systems
+* memory requirements vs. small systems
+* possible workarounds for small systems
+* ...
+
+Community deployment issues
+* what becomes of anoncvs
+* making use of version numbers in mailing lists / security advisories
+* patches/contributions/commits from non-developers
+* collaborating with non-developers
+  
+Developer deployment issues
+* commit procedures
+* development branch procedures
+* vendor branch procedures
+* private branch procedures
+* collaboration without pushing to the master repositories
+* rebasing vs. merging
+* how to refer to other commits in log messages
+
+Many of these issues are already documented in [[the existing
+workflows writeup|hgnb.mdwn]].
+
+Releng deployment issues
+* changes to the way pullups are filed
+* release commit procedures
+* release branch procedures
+* dealing with accidental commits to release branches
+* preventing accidental merges into release branches
+* extracting formal release tarballs
+* shipping source tarballs
+* ...
+
+Backend/admins deployment issues
+* log_accum / source-changes mails
+* access control for whole trees
+* access control for subsections of trees
+* backups
+* pushing to anoncvs
+* ...
+
+cvs assumptions / scripted usage in the tree
+* pkgsrc: changes-entry and commit-changes-entry
+* pkgsrc: guide regen
+* ...
+
+Other questions
+* running live in parallel with CVS during a transition period
+* gatewaying to other VCS frontends
+
+
+
+
--- /dev/null	2015-01-17 20:32:00.000000000 +0000
+++ wikisrc/users/dholland/hgtodo.mdwn	2015-01-17 20:37:23.000000000 +0000
@@ -0,0 +1,3 @@
+## To-do list for Mercurial migration
+
+(coming soon)

note in qemu section the shutdown pr
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.83
retrieving revision 1.84
diff -u -r1.83 -r1.84
--- wikisrc/ports/xen/howto.mdwn	17 Jan 2015 13:14:32 -0000	1.83
+++ wikisrc/ports/xen/howto.mdwn	17 Jan 2015 13:18:50 -0000	1.84
@@ -485,7 +485,7 @@
 version of NetBSD as a dom0 does not run on the hardware in use, or to
 generate automated test cases involving Xen.
 
-In 2015-01, the following combination was reported to work:
+In 2015-01, the following combination was reported to mostly work:
 
         host OS: NetBSD/amd64 6.1.4
         qemu: 2.2.0 from pkgsrc
@@ -493,6 +493,8 @@
         dom0 kernel: NetBSD/amd64 6.1.5
         Xen tools: xentools42-4.2.5 from pkgsrc
 
+See http://gnats.netbsd.org/47720 for a problem with dom0 shutdown.
+
 Unprivileged domains (domU)
 ===========================
 

Note xl example should come first.
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.82
retrieving revision 1.83
diff -u -r1.82 -r1.83
--- wikisrc/ports/xen/howto.mdwn	17 Jan 2015 13:11:49 -0000	1.82
+++ wikisrc/ports/xen/howto.mdwn	17 Jan 2015 13:14:32 -0000	1.83
@@ -389,8 +389,8 @@
         Domain-0           0       64    0  r----     58.1
 
 With xl, the commands are the same, and the output may be slightly
-different.  TODO: add example output for xl, after confirming on 4.2
-and resolving the TODO about rc.conf.
+different.  TODO: add example output for xl before the xm example,
+after confirming on 4.2 and resolving the TODO about rc.conf.
 
 anita (for testing NetBSD)
 --------------------------

add xen/qemu example
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.81
retrieving revision 1.82
diff -u -r1.81 -r1.82
--- wikisrc/ports/xen/howto.mdwn	17 Jan 2015 13:05:28 -0000	1.81
+++ wikisrc/ports/xen/howto.mdwn	17 Jan 2015 13:11:49 -0000	1.82
@@ -395,15 +395,15 @@
 anita (for testing NetBSD)
 --------------------------
 
-With the setup so far, one should be able to run anita (see
-pkgsrc/misc/py-anita) to test NetBSD releases, by doing (as root,
-because anita must create a domU):
-
-        anita --vmm=xm test file:///usr/obj/i386/
-
-Alternatively, one can use --vmm=xl to use xl-based domU creation instead.
-TODO: check this, and make the example use xl when confirmed.
-
+With the setup so far (assuming 4.2/xl), one should be able to run
+anita (see pkgsrc/misc/py-anita) to test NetBSD releases, by doing (as
+root, because anita must create a domU):
+
+        anita --vmm=xl test file:///usr/obj/i386/
+
+Alternatively, one can use --vmm=xm to use xm-based domU creation
+instead (and must, on Xen <= 4.1).   TODO: confirm that anita xl really works.
+    
 Xen-specific NetBSD issues
 --------------------------
 
@@ -477,6 +477,22 @@
 for the new version.
 
 
+Running Xen under qemu
+----------------------
+
+The astute reader will note that this section is somewhat twisted.
+However, it can be useful to run Xen under qemu either because the
+version of NetBSD as a dom0 does not run on the hardware in use, or to
+generate automated test cases involving Xen.
+
+In 2015-01, the following combination was reported to work:
+
+        host OS: NetBSD/amd64 6.1.4
+        qemu: 2.2.0 from pkgsrc
+        Xen kernel: xenkernel42-4.2.5nb1 from pkgsrc
+        dom0 kernel: NetBSD/amd64 6.1.5
+        Xen tools: xentools42-4.2.5 from pkgsrc
+
 Unprivileged domains (domU)
 ===========================
 

fix typo
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.80
retrieving revision 1.81
diff -u -r1.80 -r1.81
--- wikisrc/ports/xen/howto.mdwn	17 Jan 2015 13:04:01 -0000	1.80
+++ wikisrc/ports/xen/howto.mdwn	17 Jan 2015 13:05:28 -0000	1.81
@@ -946,7 +946,7 @@
 Using npf
 ---------
 
-In standard kernels, npf is a module, and thus cannot be loadeed in a
+In standard kernels, npf is a module, and thus cannot be loaded in a
 DOMU kernel.
 
 TODO: explain how to compile npf into a custom kernel, answering (but

Strengten TODO about xm/xl text cleanup.
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.79
retrieving revision 1.80
diff -u -r1.79 -r1.80
--- wikisrc/ports/xen/howto.mdwn	17 Jan 2015 12:56:36 -0000	1.79
+++ wikisrc/ports/xen/howto.mdwn	17 Jan 2015 13:04:01 -0000	1.80
@@ -402,7 +402,7 @@
         anita --vmm=xm test file:///usr/obj/i386/
 
 Alternatively, one can use --vmm=xl to use xl-based domU creation instead.
-TODO: check this.
+TODO: check this, and make the example use xl when confirmed.
 
 Xen-specific NetBSD issues
 --------------------------

clarify xm/xl preference, and put in placeholder for an xl example.
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.78
retrieving revision 1.79
diff -u -r1.78 -r1.79
--- wikisrc/ports/xen/howto.mdwn	17 Jan 2015 01:37:37 -0000	1.78
+++ wikisrc/ports/xen/howto.mdwn	17 Jan 2015 12:56:36 -0000	1.79
@@ -100,10 +100,11 @@
 Xen command program
 -------------------
 
-Early Xen used a program called "xm" to manipulate the system from the
+Early Xen used a program called xm to manipulate the system from the
 dom0.  Starting in 4.1, a replacement program with similar behavior
-called "xl" is provided.  In 4.2 and later, "xl" is preferred.  4.4 is
-the last version that has "xm".
+called xl is provided, but it does not work well in 4.1.  In 4.2, both
+xm and xl work fine.  4.4 is the last version that has xm.  You must
+choose one or the other, because it affects which daemons you run.
 
 NetBSD
 ------
@@ -368,7 +369,7 @@
         xencommons=YES
         xend=YES
 
-For 4.2 with xl (preferred), add to rc.conf:
+For 4.2 with xl, add to rc.conf:
 
         xencommons=YES
         TODO: explain if there is a xend replacement
@@ -376,8 +377,8 @@
 TODO: Recommend for/against xen-watchdog.
 
 After you have configured the daemons and either started them (in the
-order given) or rebooted, run the following (or use xl) to inspect
-Xen's boot messages, available resources, and running domains:
+order given) or rebooted, use xm or xl to inspect Xen's boot messages,
+available resources, and running domains.  An example with xm follows:
 
         # xm dmesg
 	[xen's boot info]
@@ -387,6 +388,10 @@
         Name              Id  Mem(MB)  CPU  State  Time(s)  Console
         Domain-0           0       64    0  r----     58.1
 
+With xl, the commands are the same, and the output may be slightly
+different.  TODO: add example output for xl, after confirming on 4.2
+and resolving the TODO about rc.conf.
+
 anita (for testing NetBSD)
 --------------------------
 

fix anita pkgsrc path, from gson@
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.77
retrieving revision 1.78
diff -u -r1.77 -r1.78
--- wikisrc/ports/xen/howto.mdwn	17 Jan 2015 01:36:44 -0000	1.77
+++ wikisrc/ports/xen/howto.mdwn	17 Jan 2015 01:37:37 -0000	1.78
@@ -391,7 +391,7 @@
 --------------------------
 
 With the setup so far, one should be able to run anita (see
-pkgsrc/sysutils/py-anita) to test NetBSD releases, by doing (as root,
+pkgsrc/misc/py-anita) to test NetBSD releases, by doing (as root,
 because anita must create a domU):
 
         anita --vmm=xm test file:///usr/obj/i386/

Add serial console example from gson@.
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.76
retrieving revision 1.77
diff -u -r1.76 -r1.77
--- wikisrc/ports/xen/howto.mdwn	17 Jan 2015 01:34:29 -0000	1.76
+++ wikisrc/ports/xen/howto.mdwn	17 Jan 2015 01:36:44 -0000	1.77
@@ -295,8 +295,13 @@
         menu=Xen:load /netbsd-XEN3_DOM0.gz console=pc;multiboot /xen.gz dom0_mem=256M
 
 which specifies that the dom0 should have 256M, leaving the rest to be
-allocated for domUs.  To use In an attempt to add performance, one can
-also add
+allocated for domUs.  To use a serial console, use
+
+        menu=Xen:load /netbsd-XEN3_DOM0.gz console=com0;multiboot /xen.gz dom0_mem=256M console=com1 com1=9600,8n1
+
+which will use the first serial port for Xen (which counts starting
+from 1), forcing speed/parity, and also for NetBSD (which counts
+starting at 0).  In an attempt to add performance, one can also add
 
         dom0_max_vcpus=1 dom0_vcpus_pin
 

Clarify when to boot into xen.
Based on comment from gson@.
Members: 
	ports/xen/howto.mdwn:1.75->1.76 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.75
retrieving revision 1.76
diff -u -r1.75 -r1.76
--- wikisrc/ports/xen/howto.mdwn	17 Jan 2015 01:32:12 -0000	1.75
+++ wikisrc/ports/xen/howto.mdwn	17 Jan 2015 01:34:29 -0000	1.76
@@ -289,7 +289,8 @@
 beginning of your root filesystem, /boot present, and likely
 /boot.cfg.  (If not, fix before continuing!)
 
-See boot.cfg(5) for an example.  The basic line is
+Add a line to to /boot.cfg to boot Xen.  See boot.cfg(5) for an
+example.  The basic line is
 
         menu=Xen:load /netbsd-XEN3_DOM0.gz console=pc;multiboot /xen.gz dom0_mem=256M
 
@@ -306,6 +307,9 @@
 kernel that works without Xen) and fallback versions of the non-Xen
 kernel, Xen, and the dom0 kernel.
 
+Now, reboot so that you are running a DOM0 kernel under Xen, rather
+than GENERIC without Xen.
+
 Using grub (historic)
 ---------------------
 
@@ -324,13 +328,14 @@
 
 Xen logs will be in /var/log/xen.
 
-Now, you have a system that will boot Xen and the dom0 kernel, and
-just run the dom0 kernel.  There will be no domUs, and none can be
-started because you still have to configure the dom0 tools.  The
-daemons which should be run vary with Xen version and with whether one
-is using xm or xl.  Note that xend is for supporting "xm", and should
-only be used if you plan on using "xm".  Do NOT enable xend if you
-plan on using "xl" as it will cause problems.
+Now, you have a system that will boot Xen and the dom0 kernel, but not
+do anything else special.  Make sure that you have rebooted into Xen.
+There will be no domUs, and none can be started because you still have
+to configure the dom0 tools.  The daemons which should be run vary
+with Xen version and with whether one is using xm or xl.  Note that
+xend is for supporting "xm", and should only be used if you plan on
+using "xm".  Do NOT enable xend if you plan on using "xl" as it will
+cause problems.
 
 The installation of NetBSD should already have created devices for xen
 (xencons, xenevt), but if they are not present, create them:

Remove duplication about netbsd kernel as confusing.
Suggestion from gson@.
Members: 
	ports/xen/howto.mdwn:1.74->1.75 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.74
retrieving revision 1.75
diff -u -r1.74 -r1.75
--- wikisrc/ports/xen/howto.mdwn	4 Jan 2015 02:18:47 -0000	1.74
+++ wikisrc/ports/xen/howto.mdwn	17 Jan 2015 01:32:12 -0000	1.75
@@ -274,23 +274,15 @@
 to DIAGNOSTIC and DEBUG in NetBSD.  xen-debug.gz is basically only
 useful with a serial console.  Then, place a NetBSD XEN3_DOM0 kernel
 in /, copied from releasedir/amd64/binary/kernel/netbsd-XEN3_DOM0.gz
-of a NetBSD build.  Both xen and NetBSD may be left compressed.  (If
-using i386, use releasedir/i386/binary/kernel/netbsd-XEN3PAE_DOM0.gz.)
-
-With Xen as the kernel, you must provide a dom0 NetBSD kernel to be
-used as a module; place this in /.  Suitable kernels are provided in
-releasedir/binary/kernel:
-
-        i386 XEN3_DOM0
-        i386 XEN3PAE_DOM0
-	amd64 XEN3_DOM0
-
-The first one is only for use with Xen 3.1 and i386-mode Xen (and you
-should not do this).  Current Xen always uses PAE on i386, but you
-should generally use amd64 for the dom0.  In a dom0 kernel, kernfs is
-mandatory for xend to comunicate with the kernel, so ensure that /kern
-is in fstab.  TODO: Say this is default, or file a PR and give a
-reference.
+of a NetBSD build.  If using i386, use
+releasedir/i386/binary/kernel/netbsd-XEN3PAE_DOM0.gz.  (If using Xen
+3.1 and i386, you may use XEN3_DOM0 with the non-PAE Xen.  But you
+should not use Xen 3.1.)  Both xen and the NetBSD kernel may be (and
+typically are) left compressed.
+
+In a dom0 kernel, kernfs is mandatory for xend to comunicate with the
+kernel, so ensure that /kern is in fstab.  TODO: Say this is default,
+or file a PR and give a reference.
 
 Because you already installed NetBSD, you have a working boot setup
 with an MBR bootblock, either bootxx_ffsv1 or bootxx_ffsv2 at the
@@ -302,8 +294,8 @@
         menu=Xen:load /netbsd-XEN3_DOM0.gz console=pc;multiboot /xen.gz dom0_mem=256M
 
 which specifies that the dom0 should have 256M, leaving the rest to be
-allocated for domUs.  In an attempt to add performance, one can also
-add
+allocated for domUs.  To use In an attempt to add performance, one can
+also add
 
         dom0_max_vcpus=1 dom0_vcpus_pin
 

link to pr-list.html
Index: wikisrc/releng.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/releng.mdwn,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- wikisrc/releng.mdwn	19 Nov 2014 07:56:38 -0000	1.13
+++ wikisrc/releng.mdwn	16 Jan 2015 21:48:11 -0000	1.14
@@ -15,6 +15,7 @@
 * Next Major Release: NetBSD 7.0 (No release date proposed)
   + CVS branch tag: <code>netbsd-7</code>
 * [Current pull-up queue for the netbsd-7 branch](http://releng.netbsd.org/cgi-bin/req-7.cgi)
+* [NetBSD 7 open problem report summary](http://releng.NetBSD.org/pr-list.html)
 
 ### NetBSD 6.x
 

Fix pasto.
Index: wikisrc/users/ryoon/how_to_update_www_firefox.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/users/ryoon/how_to_update_www_firefox.mdwn,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- wikisrc/users/ryoon/how_to_update_www_firefox.mdwn	9 Jun 2014 08:47:26 -0000	1.6
+++ wikisrc/users/ryoon/how_to_update_www_firefox.mdwn	16 Jan 2015 14:04:45 -0000	1.7
@@ -67,11 +67,7 @@
 
 Create named branch for working.
 
-	$ hg branch ryoon_firefox-30.b9
-
-Create named branch for applying pkgsrc patches
-
-	$ hg branch ryoon_firefox-30.0
+	$ hg branch ryoon_firefox-30.0b9
 	$ hg commit -m "Create ryoon_firefox-30.0 branch for applying freebsd-gecko patches"
 
 Add .*\.orig$ to .hgignore, and commit this change

updated url for sun6i u-boot
Index: wikisrc/ports/evbarm/allwinner.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/evbarm/allwinner.mdwn,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -r1.45 -r1.46
--- wikisrc/ports/evbarm/allwinner.mdwn	21 Dec 2014 23:08:18 -0000	1.45
+++ wikisrc/ports/evbarm/allwinner.mdwn	16 Jan 2015 00:31:01 -0000	1.46
@@ -72,7 +72,7 @@
 * Start with an ARMv7 image from *evbarm-earmv7hf/binary/gzimg/* such as *beagleboard.img*
 * Download a U-Boot build for your board
   * A10/A20: Download from the linux-sunxi web site <http://dl.linux-sunxi.org/nightly/u-boot-sunxi/u-boot-sunxi/u-boot-sunxi-latest/>
-  * A31: The standard u-boot-sunxi tree doesn't support A31 yet. Until sun6i support is merged, a build is available at <http://dis.invisible.ca/allwinner/a31/> 
+  * A31: The standard u-boot-sunxi tree doesn't support A31 yet. Until sun6i support is merged, a build is available at <http://www.invisible.ca/allwinner/a31/> 
 * Write the *u-boot-sunxi-with-spl.bin* loader to the empty space at the start of the base image:
 [[!template  id=programlisting text="""
 # dd if=u-boot-sunxi-with-spl.bin of=beagleboard.img bs=1k seek=8 conv=notrunc

remove two npf projects via rmind
--- wikisrc/projects/project/npf_bpf_unparser.mdwn	2015-01-06 14:19:41.000000000 +0000
+++ /dev/null	2015-01-06 14:16:00.000000000 +0000
@@ -1,44 +0,0 @@
-[[!template id=project
-
-title="BPF unparser into NPF syntax"
-
-contact="""
-[tech-userlevel](mailto:tech-userlevel@NetBSD.org)
-"""
-
-mentors="""
-[Christos Zoulas](mailto:christos@NetBSD.org),
-[Mindaugas Rasiukevicius](mailto:rmind@NetBSD.org)
-"""
-
-category="userland"
-difficulty="hard"
-duration="3 months"
-
-description="""
-NPF is a packet filter for the NetBSD system.  For the packet classification
-engine it uses rules which are compiled into a byte-code.  Recently, support
-for the BPF code has been added (see bpf(4) and pcap(3) manual pages).  NPF has
-syntax parser which generates intermediate structures.  Combined with pcap(3)
-library, generating BPF byte-code is almost trivial.  However, there is no code
-to perform the inverse process i.e. generate npf.conf(5) syntax from the BPF
-byte-code.
-
-The goal of this project is to write an *unparser* which would generate NPF
-configuration in npf.conf(5) syntax from the BPF byte-code and which would use
-the techniques researched in academia.
-It is important to note that the key deliverable of this project is a good
-design, which would be structured and easy to maintain.
-Therefore, academic experience with parsers and unparsers is a prerequisite.
-
-High level deliverables are the following:
-
-* Academic reasoning on the design and the structure of the unparser,
-taking into account the flexibility of the configuration syntax.
-* Implementation of the BPF byte-code unparser into npf.conf(5).
-* Integration into the npfctl(8) utility.
-
-"""
-]]
-
-[[!tag gsoc]]
--- wikisrc/projects/project/npf_ipv6.mdwn	2015-01-06 14:19:41.000000000 +0000
+++ /dev/null	2015-01-06 14:16:00.000000000 +0000
@@ -1,46 +0,0 @@
-[[!template id=project
-
-title="IPv6 support for NPF"
-
-contact="""
-[tech-net](mailto:tech-net@NetBSD.org)
-"""
-
-mentors="""
-[Mindaugas Rasiukevicius](mailto:rmind@NetBSD.org)
-"""
-
-category="kernel"
-difficulty="hard"
-duration="3 months"
-
-description="""
-NPF is a recently developed firewall for the NetBSD system.  One of its
-missing features is support for IPv6.  The student would have to add fully
-functional and reasonably tested IPv6 support for NPF.  This work should not
-require design changes to NPF.  Many modules in NPF contain abstracted
-logic/mechanism and do not rely on the length IP addresses.  As an
-additional help, there is a task list document, describing specific
-steps at code level in order to achieve this objective.
-
-High level deliverables are the following:
-
-* Add support for IPv6 filtering criteria (userland + kernel).
-* Adjust components where needed and make sure that stateful filtering works with IPv6 (kernel).
-* Handle IPv6 addresses in the NPF tables - a container for a fast lookup (userland + kernel).
-* IPv6 reassembly support, re-using NetBSD's network stack code (kernel).
-
-Optionally (hard):
-
-* Analyse IPv6 reassembly implications.
-* Add support for protocol translation (NAT46, NAT64) and/or prefix translation (NPTv6).
-* Kittens!
-
-Note: good understanding of IPv6, some knowledge of data structures and
-concurrency are the prerequisites.
-"""
-
-done_by="Zoltan Arnold Nagy"
-]]
-
-[[!tag gsoc]]

Index: wikisrc/ports/evbarm/raspberry_pi.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/evbarm/raspberry_pi.mdwn,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -r1.24 -r1.25
--- wikisrc/ports/evbarm/raspberry_pi.mdwn	5 Jan 2015 17:34:34 -0000	1.24
+++ wikisrc/ports/evbarm/raspberry_pi.mdwn	5 Jan 2015 17:39:48 -0000	1.25
@@ -83,14 +83,14 @@
 
 # Wireless Networking
  - A Realtek 802.11n USB adaptor configures as urtwn(4).
-  - Configured with wpa_supplicant in /etc/rc.conf -
+   - Configure with wpa_supplicant in /etc/rc.conf -
 
            ifconfig_urtwn0=dhcp
            dhcpcd=YES
            dhcpcd_flags="-q -b"
            wpa_supplicant=YES
            wpa_supplicant_flags="-B -i urtwn0 -c /etc/wpa_supplicant.conf"
-
+   - A sample wpa_supplicant.conf can be found at /usr/share/examples/wpa_supplicant/wpa_supplicant.conf
 
 # Additional links
  - [ARM userland utilities](https://github.com/jaredmcneill/userland)

Index: wikisrc/ports/evbarm/raspberry_pi.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/evbarm/raspberry_pi.mdwn,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- wikisrc/ports/evbarm/raspberry_pi.mdwn	17 Dec 2014 08:01:34 -0000	1.23
+++ wikisrc/ports/evbarm/raspberry_pi.mdwn	5 Jan 2015 17:34:34 -0000	1.24
@@ -81,6 +81,17 @@
  - [rpi firmware files](https://github.com/raspberrypi/firmware/tree/master/boot)
    - Copy all files except 'kernel*.img' into /boot and reboot
 
+# Wireless Networking
+ - A Realtek 802.11n USB adaptor configures as urtwn(4).
+  - Configured with wpa_supplicant in /etc/rc.conf -
+
+           ifconfig_urtwn0=dhcp
+           dhcpcd=YES
+           dhcpcd_flags="-q -b"
+           wpa_supplicant=YES
+           wpa_supplicant_flags="-B -i urtwn0 -c /etc/wpa_supplicant.conf"
+
+
 # Additional links
  - [ARM userland utilities](https://github.com/jaredmcneill/userland)
 

Added a comment: @Jonathan
--- /dev/null	2015-01-05 17:00:00.000000000 +0000
+++ wikisrc/ports/evbarm/raspberry_pi/comment_4_2aa63cae578e7b4f938ec77a36d5e647._comment	2015-01-05 17:07:52.000000000 +0000
@@ -0,0 +1,8 @@
+[[!comment format=mdwn
+ username="https://www.google.com/accounts/o8/id?id=AItOawljikmK5KwP_VFyYnoEsWkb1Za2fYGeUkw"
+ nickname="Nick"
+ subject="@Jonathan"
+ date="2015-01-05T17:06:33Z"
+ content="""
+You might want to check out installing pkgsrc and building your own packages - this article may help <http://www.cambus.net/netbsd-on-the-raspberry-pi/>
+"""]]

add Cubieboard 4, remove Cubieboard from supported Allwinner device list
Index: wikisrc/ports/evbarm.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/evbarm.mdwn,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- wikisrc/ports/evbarm.mdwn	5 Jan 2015 10:57:41 -0000	1.14
+++ wikisrc/ports/evbarm.mdwn	5 Jan 2015 11:05:36 -0000	1.15
@@ -41,7 +41,7 @@
 BECC.
 
 ### Allwinner Technology A10/A20/A31
-Various boards based on [[Allwinner]] SoCs are supported, including the BananaPi, Cubieboard, Cubieboard 2, Cubietruck, and Merrii Hummingbird A31.
+Various boards based on [[Allwinner]] SoCs are supported, including the BananaPi, Cubieboard 2, Cubietruck, Cubieboard 4, and Merrii Hummingbird A31.
 
 ### Arcom **Viper**
 

Basic Rockchip page
--- /dev/null	2015-01-05 11:00:00.000000000 +0000
+++ wikisrc/ports/evbarm/rockchip.mdwn	2015-01-05 11:04:30.000000000 +0000
@@ -0,0 +1,21 @@
+[[!meta title="NetBSD/evbarm on Rockchip SoCs"]]
+
+[[!toc levels=2]]
+
+# Supported boards
+ - [MINIX NEO X7](http://www.minix.com.hk/Products/MINIX-NEOX7-ANDROID-TV.html)
+ - [Radxa Rock 2013/Pro/Lite](http://radxa.com/Rock)
+ - [Rayeager PX2](http://en.chipspark.com/goods/Rayeager%20PX2%20Board/13)
+
+# Supported hardware
+ - SoCs
+   - Cortex-A9: PX2/RK3066 (dual core), RK3188/RK3188+ (quad core)
+ - CPU frequency/voltage scaling (RK3188/RK3188+)
+ - SD/MMC controller
+ - GPIO
+ - UART
+ - I2C
+ - PMU
+   - ACT8834
+ - Watchdog timer
+ - USB host (DWC2)

Link to Rockchip subpage.
Index: wikisrc/ports/evbarm.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/evbarm.mdwn,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- wikisrc/ports/evbarm.mdwn	6 Nov 2014 16:46:23 -0000	1.13
+++ wikisrc/ports/evbarm.mdwn	5 Jan 2015 10:57:41 -0000	1.14
@@ -204,6 +204,9 @@
 ### Raspberry Pi Foundation **Raspberry Pi**
 The [[Raspberry Pi]] is a low-cost credit-card-sized computer from the Raspberry Pi Foundation.
 
+### Rockchip PX2/RK3066/RK3188/RK3188+
+Various [[Rockchip]] family SoCs are supported by the ROCKCHIP kernel.
+
 ### Samsung **SMDK2410**
 
 The SMDK2410 is the reference platform for the Samsung **S3C2410** processor,

Added a comment: Installing packages
--- /dev/null	2015-01-04 22:48:00.000000000 +0000
+++ wikisrc/ports/evbarm/raspberry_pi/comment_3_a94bded5b40cf5e232889708e8519339._comment	2015-01-04 22:49:27.000000000 +0000
@@ -0,0 +1,26 @@
+[[!comment format=mdwn
+ username="https://www.google.com/accounts/o8/id?id=AItOawmrYoZc1GRmQ705rl0FoW5Sjj53FSeMqUs"
+ nickname="Jonathan"
+ subject="Installing packages"
+ date="2015-01-04T22:48:08Z"
+ content="""
+I have successfully installed NetBSD to my pi from the supplied images, but it is just the core system with no X server.  I am a relative newby to Linux, let alone BSD and am slowly working my way around it, but I am struggling with pkg_add because I can't find a source file to match...
+
+I downloaded rpi.img.gz from here:
+http://nyftp.netbsd.org/pub/NetBSD-daily/netbsd-7/201501031030Z/evbarm-earmv6hf/binary/gzimg/
+
+I followed the instructions on this page, but fall down when trying to add packages
+
+but when following the instructions here: https://www.netbsd.org/docs/pkgsrc/using.html
+and here: http://www.netbsd.org/docs/guide/en/chap-boot.html
+
+I cannot find a matching distribution.
+
+uname -a reports:
+NetBSD rpi 7.0_BETA NetBSD 7.0_BETA (RPI_201501031030Z) evbarm
+
+but the closest I can get is
+ftp://ftp.netbsd.org/pub/pkgsrc/packages/NetBSD/evbarm/6.1
+
+Should I be looking elsewhere for the repository?
+"""]]

pkg/49349 fixed the perl issue, pkg/49512 fixes the ruby issue
Index: wikisrc/pkgsrc/macosx_tiger_powerpc.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/pkgsrc/macosx_tiger_powerpc.mdwn,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- wikisrc/pkgsrc/macosx_tiger_powerpc.mdwn	17 Aug 2014 18:22:07 -0000	1.10
+++ wikisrc/pkgsrc/macosx_tiger_powerpc.mdwn	4 Jan 2015 04:10:11 -0000	1.11
@@ -16,12 +16,6 @@
 Bored? Choose one of these problems we need solved. Annoyed? Write
 down the problem here.
 
-### [[!toggle id="perl5" text="lang/perl5"]]
-[[!toggleable id="perl5" text="""
-Some apparently incorrect default `MACOSX_DEPLOYMENT_TARGET` breaks
-the build.
-"""]]
-
 ### [[!toggle id="tmux" text="misc/tmux"]]
 [[!toggleable id="tmux" text="""
 [[!template id=filecontent name="misc/tmux" text=<<TMUXINNER
@@ -240,22 +234,6 @@
 CMAKEINNER]]
 """]]
 
-
-### [[!toggle id="ruby21-base" text="lang/ruby21-base"]]
-[[!toggleable id="ruby21-base" text="""
-[[!template id=filecontent name="lang/ruby21-base install.log" text=<<RUBYTWOONEBASEINNER
-Failed to configure dbm. It will not be installed.
-=> Automatic manual page handling
-=> Generating post-install file lists
-pkg_create: can't stat `/tmp/lang/ruby21-base/work/.destdir/usr/pkg/lib/ruby/2.1.2/powerpc-darwin8/dbm.bundle'
-=> Checking file-check results for ruby212-base-2.1.2
-ERROR: ************************************************************
-ERROR: The following files are in the PLIST but not in /tmp/lang/ruby21-base/work/.destdir/usr/pkg:
-ERROR:         /tmp/lang/ruby21-base/work/.destdir/usr/pkg/lib/ruby/2.1.2/powerpc-darwin8/dbm.bundle
-*** Error code 
-RUBYTWOONEBASEINNER]]
-"""]]
-
 ### [[!toggle id="MesaLib" text="graphics/MesaLib"]]
 [[!toggleable id="MesaLib" text="""
 [[!template id=filecontent name="graphics/MesaLib install.log" text=<<MESALIBINNER

note about multiple vcpus
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.73
retrieving revision 1.74
diff -u -r1.73 -r1.74
--- wikisrc/ports/xen/howto.mdwn	4 Jan 2015 02:17:17 -0000	1.73
+++ wikisrc/ports/xen/howto.mdwn	4 Jan 2015 02:18:47 -0000	1.74
@@ -893,6 +893,10 @@
 kernel from the domU filesystem.  This is closer to a regular physical
 computer, where someone who controls a machine can replace the kernel.
 
+A second issue is multiple CPUs.  With NetBSD 6, domUs support
+multiple vcpus, and it is typical for VPS providers to enable multiple
+CPUs for NetBSD domUs.
+
 pygrub
 -------
 
@@ -912,11 +916,12 @@
 that pvgrub works with FFsv2 with 16K/2K and 32K/4K block/frag sizes
 (and hence with defaults from "newfs -O 2").  See [Panix's pvgrub
 page](http://www.panix.com/v-colo/grub.html), which describes only
-Linux but should be updated to cover NetBSD :-)
+Linux but should be updated to cover NetBSD :-).
 
 [prgmr.com](http://prgmr.com/) also lets users with pvgrub to boot
 their own kernel.  See then [prgmr.com NetBSD
-HOWTO](http://wiki.prgmr.com/mediawiki/index.php/NetBSD_as_a_DomU).
+HOWTO](http://wiki.prgmr.com/mediawiki/index.php/NetBSD_as_a_DomU)
+(which is in need of updating).
 
 It appears that [grub's FFS
 code](http://xenbits.xensource.com/hg/xen-unstable.hg/file/bca284f67702/tools/libfsimage/ufs/fsys_ufs.c)

merge paragraphs
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.72
retrieving revision 1.73
diff -u -r1.72 -r1.73
--- wikisrc/ports/xen/howto.mdwn	4 Jan 2015 02:15:34 -0000	1.72
+++ wikisrc/ports/xen/howto.mdwn	4 Jan 2015 02:17:17 -0000	1.73
@@ -883,7 +883,6 @@
 is booted, because the kernel is nominally in the dom0 filesystem (to
 which VPS users do not normally have acesss).  A second issue is how
 to install NetBSD.
-
 A VPS user may want to compile a kernel for security updates, to run
 npf, run IPsec, or any other reason why someone would want to change
 their kernel.

Spell prgmr correctly. (For some reason this is challenging.)
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.71
retrieving revision 1.72
diff -u -r1.71 -r1.72
--- wikisrc/ports/xen/howto.mdwn	4 Jan 2015 02:14:15 -0000	1.71
+++ wikisrc/ports/xen/howto.mdwn	4 Jan 2015 02:15:34 -0000	1.72
@@ -922,7 +922,7 @@
 It appears that [grub's FFS
 code](http://xenbits.xensource.com/hg/xen-unstable.hg/file/bca284f67702/tools/libfsimage/ufs/fsys_ufs.c)
 does not support all aspects of modern FFS, but there are also reports
-that FFSv2 works fine.  At prmgr, typically one has an ext2 or FAT
+that FFSv2 works fine.  At prgmr, typically one has an ext2 or FAT
 partition for the kernel with the intent that grub can understand it,
 which leads to /netbsd not being the actual kernel.  One must remember
 to update the special boot partiion.

clarify panix block sizes/defaults
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.70
retrieving revision 1.71
diff -u -r1.70 -r1.71
--- wikisrc/ports/xen/howto.mdwn	4 Jan 2015 02:10:06 -0000	1.70
+++ wikisrc/ports/xen/howto.mdwn	4 Jan 2015 02:14:15 -0000	1.71
@@ -910,8 +910,8 @@
 /grub/menu.lst and loads a kernel from the domU filesystem.
 
 [Panix](http://www.panix.com/) lets users use pvgrub.  Panix reports
-that pvgrub works with FFsv2 with default "newfs -O2" as well as
-16K/2K and 32K/4K block/frag sizes.  See [Panix's pvgrub
+that pvgrub works with FFsv2 with 16K/2K and 32K/4K block/frag sizes
+(and hence with defaults from "newfs -O 2").  See [Panix's pvgrub
 page](http://www.panix.com/v-colo/grub.html), which describes only
 Linux but should be updated to cover NetBSD :-)
 

more pvgrub, panix links
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.69
retrieving revision 1.70
diff -u -r1.69 -r1.70
--- wikisrc/ports/xen/howto.mdwn	31 Dec 2014 00:33:48 -0000	1.69
+++ wikisrc/ports/xen/howto.mdwn	4 Jan 2015 02:10:06 -0000	1.70
@@ -875,12 +875,14 @@
 The bulk of the HOWTO is about using NetBSD as a dom0 on your own
 hardware.  This section explains how to deal with Xen in a domU as a
 virtual private server where you do not control or have access to the
-dom0.
+dom0.  This is not intended to be an exhaustive list of VPS providers;
+only a few are mentioned that specifically support NetBSD.
 
 VPS operators provide varying degrees of access and mechanisms for
 configuration.  The big issue is usually how one controls which kernel
 is booted, because the kernel is nominally in the dom0 filesystem (to
-which VPS users do not normally have acesss).
+which VPS users do not normally have acesss).  A second issue is how
+to install NetBSD.
 
 A VPS user may want to compile a kernel for security updates, to run
 npf, run IPsec, or any other reason why someone would want to change
@@ -907,15 +909,23 @@
 calls.  It is booted from the dom0 as the domU kernel, and then reads
 /grub/menu.lst and loads a kernel from the domU filesystem.
 
-[prgmr.com](http://prgmr.com/) uses this approach to let users choose
-their own operating system and kernel.  See then [prgmr.com NetBSD
+[Panix](http://www.panix.com/) lets users use pvgrub.  Panix reports
+that pvgrub works with FFsv2 with default "newfs -O2" as well as
+16K/2K and 32K/4K block/frag sizes.  See [Panix's pvgrub
+page](http://www.panix.com/v-colo/grub.html), which describes only
+Linux but should be updated to cover NetBSD :-)
+
+[prgmr.com](http://prgmr.com/) also lets users with pvgrub to boot
+their own kernel.  See then [prgmr.com NetBSD
 HOWTO](http://wiki.prgmr.com/mediawiki/index.php/NetBSD_as_a_DomU).
 
-Because [grub's FFS code](http://xenbits.xensource.com/hg/xen-unstable.hg/file/bca284f67702/tools/libfsimage/ufs/fsys_ufs.c)
-appears not to support all aspects of modern FFS,
-typically one has an ext2 or FAT partition for the kernel, so that
-grub can understand it, which leads to /netbsd not being the actual
-kernel.  One must remember to update the special boot partiion.
+It appears that [grub's FFS
+code](http://xenbits.xensource.com/hg/xen-unstable.hg/file/bca284f67702/tools/libfsimage/ufs/fsys_ufs.c)
+does not support all aspects of modern FFS, but there are also reports
+that FFSv2 works fine.  At prmgr, typically one has an ext2 or FAT
+partition for the kernel with the intent that grub can understand it,
+which leads to /netbsd not being the actual kernel.  One must remember
+to update the special boot partiion.
 
 Amazon
 ------
@@ -939,10 +949,11 @@
 * Get PCI passthrough working on Xen 4.2 (or 4.4).
 * Get pvgrub into pkgsrc, either via xentools or separately.
 * grub
-  * Add support to pkgsrc grub2 for UFS2 and arbitrary
+  * Check/add support to pkgsrc grub2 for UFS2 and arbitrary
     fragsize/blocksize (UFS2 support may be present; the point is to
     make it so that with any UFS1/UFS2 filesystem setup that works
     with NetBSD grub will also work).
+    See [pkg/40258](http://gnats.netbsd.org/40258).
   * Push patches upstream.
   * Get UFS2 patches into pvgrub.
 * Add support for PV ops to a version of /boot, and make it usable as

Exclude me from the list of completed tasks.
Index: wikisrc/wiki/todo/done.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/wiki/todo/done.mdwn,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- wikisrc/wiki/todo/done.mdwn	18 Dec 2009 21:05:33 -0000	1.2
+++ wikisrc/wiki/todo/done.mdwn	3 Jan 2015 14:41:40 -0000	1.3
@@ -1,5 +1,5 @@
 [[!inline
-pages="link(todo/done) and !wiki/todo and !Discussion"
+pages="link(todo/done) and !wiki/todo and !users/schmonz and !Discussion"
 show=0
 archive=yes
 ]]

Added a comment: Bug in kqdir.c
--- /dev/null	2015-01-01 07:40:01.000000000 +0000
+++ wikisrc/tutorials/kqueue_tutorial/comment_1_7634af8fc38da897ad26939a4b43c02f._comment	2015-01-01 07:46:12.000000000 +0000
@@ -0,0 +1,13 @@
+[[!comment format=mdwn
+ username="https://www.google.com/accounts/o8/id?id=AItOawkBSeahkJSobxTKsgHyEHNyp_xcS9E-2X4"
+ nickname="Kevin"
+ subject="Bug in kqdir.c "
+ date="2015-01-01T07:44:52Z"
+ content="""
+The example code at
+http://repo.or.cz/w/eleutheria.git/blob_plain/master:/kqueue/kqdir.c
+has a bug. It skips the first file in the directory of files it's supposed to monitor.
+
+I was able to fix this by changeing line 51 to
+     while(cnt++ < 2 && (pdent = readdir(pdir)) != NULL)
+"""]]

Welcome to 2015
Index: wikisrc/templates/page.tmpl
===================================================================
RCS file: /cvsroot/wikisrc/templates/page.tmpl,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -r1.27 -r1.28
--- wikisrc/templates/page.tmpl	30 Jul 2014 15:33:09 -0000	1.27
+++ wikisrc/templates/page.tmpl	1 Jan 2015 05:42:44 -0000	1.28
@@ -282,7 +282,7 @@
       <span class="footcopy"><a href="about/disclaimer.html">
         Disclaimer</a> |
         <span class="copyright">
-          Copyright &copy; 1994-2014 The NetBSD Foundation, Inc.
+          Copyright &copy; 1994-2015 The NetBSD Foundation, Inc.
         </span>
         ALL
         RIGHTS RESERVED. <br /> NetBSD<sup>&reg;</sup> is a registered

calendar update
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1 @@
+[[!calendar type=year year=2015 pages="internal(blog/*)"]]
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015/01.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1,5 @@
+[[!sidebar content="""
+[[!calendar type=month month=01 year=2015 pages="internal(blog/*)"]]
+"""]]
+
+[[!inline pages="creation_month(01) and creation_year(2015) and internal(blog/*)" show=0 feeds=no reverse=yes]]
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015/02.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1,5 @@
+[[!sidebar content="""
+[[!calendar type=month month=02 year=2015 pages="internal(blog/*)"]]
+"""]]
+
+[[!inline pages="creation_month(02) and creation_year(2015) and internal(blog/*)" show=0 feeds=no reverse=yes]]
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015/03.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1,5 @@
+[[!sidebar content="""
+[[!calendar type=month month=03 year=2015 pages="internal(blog/*)"]]
+"""]]
+
+[[!inline pages="creation_month(03) and creation_year(2015) and internal(blog/*)" show=0 feeds=no reverse=yes]]
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015/04.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1,5 @@
+[[!sidebar content="""
+[[!calendar type=month month=04 year=2015 pages="internal(blog/*)"]]
+"""]]
+
+[[!inline pages="creation_month(04) and creation_year(2015) and internal(blog/*)" show=0 feeds=no reverse=yes]]
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015/05.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1,5 @@
+[[!sidebar content="""
+[[!calendar type=month month=05 year=2015 pages="internal(blog/*)"]]
+"""]]
+
+[[!inline pages="creation_month(05) and creation_year(2015) and internal(blog/*)" show=0 feeds=no reverse=yes]]
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015/06.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1,5 @@
+[[!sidebar content="""
+[[!calendar type=month month=06 year=2015 pages="internal(blog/*)"]]
+"""]]
+
+[[!inline pages="creation_month(06) and creation_year(2015) and internal(blog/*)" show=0 feeds=no reverse=yes]]
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015/07.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1,5 @@
+[[!sidebar content="""
+[[!calendar type=month month=07 year=2015 pages="internal(blog/*)"]]
+"""]]
+
+[[!inline pages="creation_month(07) and creation_year(2015) and internal(blog/*)" show=0 feeds=no reverse=yes]]
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015/08.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1,5 @@
+[[!sidebar content="""
+[[!calendar type=month month=08 year=2015 pages="internal(blog/*)"]]
+"""]]
+
+[[!inline pages="creation_month(08) and creation_year(2015) and internal(blog/*)" show=0 feeds=no reverse=yes]]
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015/09.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1,5 @@
+[[!sidebar content="""
+[[!calendar type=month month=09 year=2015 pages="internal(blog/*)"]]
+"""]]
+
+[[!inline pages="creation_month(09) and creation_year(2015) and internal(blog/*)" show=0 feeds=no reverse=yes]]
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015/10.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1,5 @@
+[[!sidebar content="""
+[[!calendar type=month month=10 year=2015 pages="internal(blog/*)"]]
+"""]]
+
+[[!inline pages="creation_month(10) and creation_year(2015) and internal(blog/*)" show=0 feeds=no reverse=yes]]
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015/11.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1,5 @@
+[[!sidebar content="""
+[[!calendar type=month month=11 year=2015 pages="internal(blog/*)"]]
+"""]]
+
+[[!inline pages="creation_month(11) and creation_year(2015) and internal(blog/*)" show=0 feeds=no reverse=yes]]
--- /dev/null	2015-01-01 00:00:01.000000000 +0000
+++ wikisrc/archives/2015/12.mdwn	2015-01-01 00:00:06.000000000 +0000
@@ -0,0 +1,5 @@
+[[!sidebar content="""
+[[!calendar type=month month=12 year=2015 pages="internal(blog/*)"]]
+"""]]
+
+[[!inline pages="creation_month(12) and creation_year(2015) and internal(blog/*)" show=0 feeds=no reverse=yes]]

note build results on netbsd-7 i386
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.68
retrieving revision 1.69
diff -u -r1.68 -r1.69
--- wikisrc/ports/xen/howto.mdwn	30 Dec 2014 18:26:26 -0000	1.68
+++ wikisrc/ports/xen/howto.mdwn	31 Dec 2014 00:33:48 -0000	1.69
@@ -173,6 +173,12 @@
         xenkernel42 netbsd-6 i386
         xentools42 netbsd-6 i386 *MIXED
 
+	(all 3 and 33 seem to FAIL)
+        xenkernel41 netbsd-7 i386
+        xentools41 netbsd-7 i386
+        xenkernel42 netbsd-7 i386
+        xentools42 netbsd-7 i386 ??FAIL
+
 (*On netbsd-6 i386, there is a xentools42 in the 2014Q3 official builds,
 but it does not build for gdt.)
 

s/py-grub/pygrub/
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.67
retrieving revision 1.68
diff -u -r1.67 -r1.68
--- wikisrc/ports/xen/howto.mdwn	30 Dec 2014 18:25:46 -0000	1.67
+++ wikisrc/ports/xen/howto.mdwn	30 Dec 2014 18:26:26 -0000	1.68
@@ -881,17 +881,18 @@
 their kernel.
 
 One approach is to have an adminstrative interface to upload a kernel,
-or to select from a prepopulated list.  Other approaches are py-grub
+or to select from a prepopulated list.  Other approaches are pygrub
 (deprecated) and pvgrub, which are ways to have a bootloader obtain a
 kernel from the domU filesystem.  This is closer to a regular physical
 computer, where someone who controls a machine can replace the kernel.
 
-py-grub
+pygrub
 -------
 
-py-grub runs in the dom0 and looks into the domU filesystem.  This
+pygrub runs in the dom0 and looks into the domU filesystem.  This
 implies that the domU must have a kernel in a filesystem in a format
-known to py-grub.  As of 2014, py-grub seems to be of mostly historical interest.
+known to pygrub.  As of 2014, pygrub seems to be of mostly historical
+interest.
 
 pvgrub
 ------

TODO nits
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.66
retrieving revision 1.67
diff -u -r1.66 -r1.67
--- wikisrc/ports/xen/howto.mdwn	30 Dec 2014 18:05:59 -0000	1.66
+++ wikisrc/ports/xen/howto.mdwn	30 Dec 2014 18:25:46 -0000	1.67
@@ -929,10 +929,9 @@
 ===================================
 
 * Package Xen 4.4.
-* Get PCI passthrough working on Xen 4.2.
+* Get PCI passthrough working on Xen 4.2 (or 4.4).
 * Get pvgrub into pkgsrc, either via xentools or separately.
 * grub
-
   * Add support to pkgsrc grub2 for UFS2 and arbitrary
     fragsize/blocksize (UFS2 support may be present; the point is to
     make it so that with any UFS1/UFS2 filesystem setup that works

clarify grub UFS2
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.65
retrieving revision 1.66
diff -u -r1.65 -r1.66
--- wikisrc/ports/xen/howto.mdwn	30 Dec 2014 17:45:37 -0000	1.65
+++ wikisrc/ports/xen/howto.mdwn	30 Dec 2014 18:05:59 -0000	1.66
@@ -932,7 +932,11 @@
 * Get PCI passthrough working on Xen 4.2.
 * Get pvgrub into pkgsrc, either via xentools or separately.
 * grub
-  * Add support to pkgsrc grub2 for UFS2 and arbitrary fragsize/blocksize.
+
+  * Add support to pkgsrc grub2 for UFS2 and arbitrary
+    fragsize/blocksize (UFS2 support may be present; the point is to
+    make it so that with any UFS1/UFS2 filesystem setup that works
+    with NetBSD grub will also work).
   * Push patches upstream.
   * Get UFS2 patches into pvgrub.
 * Add support for PV ops to a version of /boot, and make it usable as

add semi-random todo list
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.64
retrieving revision 1.65
diff -u -r1.64 -r1.65
--- wikisrc/ports/xen/howto.mdwn	29 Dec 2014 14:35:58 -0000	1.64
+++ wikisrc/ports/xen/howto.mdwn	30 Dec 2014 17:45:37 -0000	1.65
@@ -924,3 +924,16 @@
 TODO: explain how to compile npf into a custom kernel, answering (but
 note that the problem was caused by not booting the right kernel):
 http://mail-index.netbsd.org/netbsd-users/2014/12/26/msg015576.html
+
+TODO items for improving NetBSD/xen
+===================================
+
+* Package Xen 4.4.
+* Get PCI passthrough working on Xen 4.2.
+* Get pvgrub into pkgsrc, either via xentools or separately.
+* grub
+  * Add support to pkgsrc grub2 for UFS2 and arbitrary fragsize/blocksize.
+  * Push patches upstream.
+  * Get UFS2 patches into pvgrub.
+* Add support for PV ops to a version of /boot, and make it usable as
+  a kernel in Xen, similar to pvgrub.

more build results
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.63
retrieving revision 1.64
diff -u -r1.63 -r1.64
--- wikisrc/ports/xen/howto.mdwn	29 Dec 2014 00:50:18 -0000	1.63
+++ wikisrc/ports/xen/howto.mdwn	29 Dec 2014 14:35:58 -0000	1.64
@@ -155,13 +155,13 @@
 
         xenkernel3 netbsd-5 amd64
         xentools3 netbsd-5 amd64
-        xentools3 netbsd-5 amd64 ????
+        xentools3=hvm netbsd-5 amd64 ????
         xenkernel33 netbsd-5 amd64
         xentools33 netbsd-5 amd64
         xenkernel41 netbsd-5 amd64
         xentools41 netbsd-5 amd64
         xenkernel42 netbsd-5 amd64
-        xentools42 netbsd-5 amd64 ????
+        xentools42 netbsd-5 amd64
 
         xenkernel3 netbsd-6 i386 FAIL
         xentools3 netbsd-6 i386
@@ -171,7 +171,10 @@
         xenkernel41 netbsd-6 i386
         xentools41 netbsd-6 i386
         xenkernel42 netbsd-6 i386
-        xentools42 netbsd-6 i386 FAIL
+        xentools42 netbsd-6 i386 *MIXED
+
+(*On netbsd-6 i386, there is a xentools42 in the 2014Q3 official builds,
+but it does not build for gdt.)
 
 NetBSD as a dom0
 ================

more build results
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.62
retrieving revision 1.63
diff -u -r1.62 -r1.63
--- wikisrc/ports/xen/howto.mdwn	29 Dec 2014 00:13:15 -0000	1.62
+++ wikisrc/ports/xen/howto.mdwn	29 Dec 2014 00:50:18 -0000	1.63
@@ -154,19 +154,23 @@
 support) is difficult to build.  The following are known to work or FAIL:
 
         xenkernel3 netbsd-5 amd64
+        xentools3 netbsd-5 amd64
+        xentools3 netbsd-5 amd64 ????
         xenkernel33 netbsd-5 amd64
+        xentools33 netbsd-5 amd64
         xenkernel41 netbsd-5 amd64
         xentools41 netbsd-5 amd64
         xenkernel42 netbsd-5 amd64
+        xentools42 netbsd-5 amd64 ????
 
         xenkernel3 netbsd-6 i386 FAIL
         xentools3 netbsd-6 i386
-	xentools3-hvm netbsd-6 i386 FAIL (dependencies fail)
-	xenkernel33 netbsd-6 i386
-	xentools33 netbsd-6 i386
+        xentools3-hvm netbsd-6 i386 FAIL (dependencies fail)
+        xenkernel33 netbsd-6 i386
+        xentools33 netbsd-6 i386
         xenkernel41 netbsd-6 i386
         xentools41 netbsd-6 i386
-	xenkernel42 netbsd-6 i386
+        xenkernel42 netbsd-6 i386
         xentools42 netbsd-6 i386 FAIL
 
 NetBSD as a dom0

update what builds and what doesn't
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.61
retrieving revision 1.62
diff -u -r1.61 -r1.62
--- wikisrc/ports/xen/howto.mdwn	28 Dec 2014 23:26:19 -0000	1.61
+++ wikisrc/ports/xen/howto.mdwn	29 Dec 2014 00:13:15 -0000	1.62
@@ -151,17 +151,23 @@
 Ideally, all versions of Xen in pkgsrc would build on all versions of
 NetBSD on both i386 and amd64.  However, that isn't the case.  Besides
 aging code and aging compilers, qemu (included in xentools for HVM
-support) is difficult to build.  The following are known to fail:
-
-        xenkernel3 netbsd-6 i386
-        xentools42 netbsd-6 i386 
-
-The following are known to work:
+support) is difficult to build.  The following are known to work or FAIL:
 
+        xenkernel3 netbsd-5 amd64
+        xenkernel33 netbsd-5 amd64
         xenkernel41 netbsd-5 amd64
         xentools41 netbsd-5 amd64
+        xenkernel42 netbsd-5 amd64
+
+        xenkernel3 netbsd-6 i386 FAIL
+        xentools3 netbsd-6 i386
+	xentools3-hvm netbsd-6 i386 FAIL (dependencies fail)
+	xenkernel33 netbsd-6 i386
+	xentools33 netbsd-6 i386
         xenkernel41 netbsd-6 i386
         xentools41 netbsd-6 i386
+	xenkernel42 netbsd-6 i386
+        xentools42 netbsd-6 i386 FAIL
 
 NetBSD as a dom0
 ================

add link to xen grub ffs code
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.60
retrieving revision 1.61
diff -u -r1.60 -r1.61
--- wikisrc/ports/xen/howto.mdwn	28 Dec 2014 18:31:50 -0000	1.60
+++ wikisrc/ports/xen/howto.mdwn	28 Dec 2014 23:26:19 -0000	1.61
@@ -891,7 +891,9 @@
 their own operating system and kernel.  See then [prgmr.com NetBSD
 HOWTO](http://wiki.prgmr.com/mediawiki/index.php/NetBSD_as_a_DomU).
 
-Typically one has an ext2 or FAT partition for the kernel, so that
+Because [grub's FFS code](http://xenbits.xensource.com/hg/xen-unstable.hg/file/bca284f67702/tools/libfsimage/ufs/fsys_ufs.c)
+appears not to support all aspects of modern FFS,
+typically one has an ext2 or FAT partition for the kernel, so that
 grub can understand it, which leads to /netbsd not being the actual
 kernel.  One must remember to update the special boot partiion.
 

Index: wikisrc/projects/project/zfs.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/projects/project/zfs.mdwn,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- wikisrc/projects/project/zfs.mdwn	28 Dec 2014 19:46:00 -0000	1.2
+++ wikisrc/projects/project/zfs.mdwn	28 Dec 2014 19:51:26 -0000	1.3
@@ -14,7 +14,7 @@
 The ZFS port to NetBSD is half-done, or maybe more than half. Finish
 it and get it really running.
 
-Now, OpenZFS is the main location of ZFS in the Free Software community, and supports FreeBSD, Illumos, Linux and Mac.  Probably the right approach is to get the most recent OpenZFS working with NetBSD.  This could either be via pkgsrc or via importing and reachover makefiles.  The hard part is probably in the ZFS/NetBSD kernel interface bits.
+Now, [OpenZFS](http://open-zfs.org/wiki/Main_Page) is the main location of ZFS in the Free Software community, and supports FreeBSD, Illumos, Linux and Mac.  Probably the right approach is to get the most recent OpenZFS working with NetBSD.  This could either be via pkgsrc or via importing and reachover makefiles.  The hard part is probably in the ZFS/NetBSD kernel interface bits.
 
 
 """

Index: wikisrc/projects/project/zfs.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/projects/project/zfs.mdwn,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- wikisrc/projects/project/zfs.mdwn	27 Feb 2014 09:19:29 -0000	1.1
+++ wikisrc/projects/project/zfs.mdwn	28 Dec 2014 19:46:00 -0000	1.2
@@ -14,7 +14,8 @@
 The ZFS port to NetBSD is half-done, or maybe more than half. Finish
 it and get it really running.
 
-(This page is a stub. Someone who knows what the current state is,
-please expand it.)
+Now, OpenZFS is the main location of ZFS in the Free Software community, and supports FreeBSD, Illumos, Linux and Mac.  Probably the right approach is to get the most recent OpenZFS working with NetBSD.  This could either be via pkgsrc or via importing and reachover makefiles.  The hard part is probably in the ZFS/NetBSD kernel interface bits.
+
+
 """
 ]]

typo fix (s/anme/name)
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.59
retrieving revision 1.60
diff -u -r1.59 -r1.60
--- wikisrc/ports/xen/howto.mdwn	27 Dec 2014 15:46:47 -0000	1.59
+++ wikisrc/ports/xen/howto.mdwn	28 Dec 2014 18:31:50 -0000	1.60
@@ -457,7 +457,7 @@
 This section describes general concepts about domUs.  It does not
 address specific domU operating systems or how to install them.  The
 config files for domUs are typically in /usr/pkg/etc/xen, and are
-typically named so that the file anme, domU name and the domU's host
+typically named so that the file name, domU name and the domU's host
 name match.
 
 The domU is provided with cpu and memory by Xen, configured by the

expand vps section
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.58
retrieving revision 1.59
diff -u -r1.58 -r1.59
--- wikisrc/ports/xen/howto.mdwn	27 Dec 2014 00:36:20 -0000	1.58
+++ wikisrc/ports/xen/howto.mdwn	27 Dec 2014 15:46:47 -0000	1.59
@@ -531,6 +531,8 @@
 (so they are near the dom0 kernel), in /usr/pkg/etc/xen (near the
 config files), or in /u0/xen (where the vdisks are).
 
+Note that loading the domU kernel from the dom0 implies that boot
+blocks, /boot, /boot.cfg, and so on are all ignored in the domU.
 See the VPS section near the end for discussion of alternate ways to
 obtain domU kernels.
 
@@ -866,19 +868,37 @@
 their kernel.
 
 One approach is to have an adminstrative interface to upload a kernel,
-or to select from a prepopulated list.
+or to select from a prepopulated list.  Other approaches are py-grub
+(deprecated) and pvgrub, which are ways to have a bootloader obtain a
+kernel from the domU filesystem.  This is closer to a regular physical
+computer, where someone who controls a machine can replace the kernel.
 
-Otehr approaches are pvgrub and py-grub, which are ways to start a
-bootloader from the dom0 instead of the actual domU kernel, and for
-that loader to then load a kernel from the domU filesystem.  This is
-closer to a regular physical computer, where someone who controls a
-machine can replace the kernel.
+py-grub
+-------
 
-prmgr and pvgrub
-----------------
+py-grub runs in the dom0 and looks into the domU filesystem.  This
+implies that the domU must have a kernel in a filesystem in a format
+known to py-grub.  As of 2014, py-grub seems to be of mostly historical interest.
 
-TODO: Perhaps reference panix, prmgr, amazon as interesting examples.
-Explain what prmgr does.
+pvgrub
+------
+
+pvgrub is a version of grub that uses PV operations instead of BIOS
+calls.  It is booted from the dom0 as the domU kernel, and then reads
+/grub/menu.lst and loads a kernel from the domU filesystem.
+
+[prgmr.com](http://prgmr.com/) uses this approach to let users choose
+their own operating system and kernel.  See then [prgmr.com NetBSD
+HOWTO](http://wiki.prgmr.com/mediawiki/index.php/NetBSD_as_a_DomU).
+
+Typically one has an ext2 or FAT partition for the kernel, so that
+grub can understand it, which leads to /netbsd not being the actual
+kernel.  One must remember to update the special boot partiion.
+
+Amazon
+------
+
+TODO: add link to NetBSD amazon howto.
 
 Using npf
 ---------
@@ -886,5 +906,6 @@
 In standard kernels, npf is a module, and thus cannot be loadeed in a
 DOMU kernel.
 
-TODO: explain how to compile npf into a custom kernel, answering:
+TODO: explain how to compile npf into a custom kernel, answering (but
+note that the problem was caused by not booting the right kernel):
 http://mail-index.netbsd.org/netbsd-users/2014/12/26/msg015576.html

update hypervisor language to catch up with 2014 vs 2004 terminology
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.57
retrieving revision 1.58
diff -u -r1.57 -r1.58
--- wikisrc/ports/xen/howto.mdwn	27 Dec 2014 00:33:45 -0000	1.57
+++ wikisrc/ports/xen/howto.mdwn	27 Dec 2014 00:36:20 -0000	1.58
@@ -4,15 +4,15 @@
 [![[Xen
 screenshot]](http://www.netbsd.org/gallery/in-Action/hubertf-xens.png)](http://www.netbsd.org/gallery/in-Action/hubertf-xen.png)
 
-Xen is a virtual machine monitor or hypervisor for x86 hardware
+Xen is a hypervisor (or virtual machine monitor) for x86 hardware
 (i686-class or higher), which supports running multiple guest
-operating systems on a single physical machine.  With Xen, one uses
-the Xen kernel to control the CPU, memory and console, a dom0
-operating system which mediates access to other hardware (e.g., disks,
-network, USB), and one or more domU operating systems which operate in
-an unprivileged virtualized environment.  IO requests from the domU
-systems are forwarded by the hypervisor (Xen) to the dom0 to be
-fulfilled.
+operating systems on a single physical machine.  Xen is a Type 1 or
+bare-metal hypervisor; one uses the Xen kernel to control the CPU,
+memory and console, a dom0 operating system which mediates access to
+other hardware (e.g., disks, network, USB), and one or more domU
+operating systems which operate in an unprivileged virtualized
+environment.  IO requests from the domU systems are forwarded by the
+hypervisor (Xen) to the dom0 to be fulfilled.
 
 Xen supports two styles of guests.  The original is Para-Virtualized
 (PV) which means that the guest OS does not attempt to access hardware

fix screenshot link
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.56
retrieving revision 1.57
diff -u -r1.56 -r1.57
--- wikisrc/ports/xen/howto.mdwn	27 Dec 2014 00:25:48 -0000	1.56
+++ wikisrc/ports/xen/howto.mdwn	27 Dec 2014 00:33:45 -0000	1.57
@@ -2,7 +2,7 @@
 ============
 
 [![[Xen
-screenshot]](http://www.netbsd.org/gallery/in-Action/hubertf-xens.png)](../../gallery/in-Action/hubertf-xen.png)
+screenshot]](http://www.netbsd.org/gallery/in-Action/hubertf-xens.png)](http://www.netbsd.org/gallery/in-Action/hubertf-xen.png)
 
 Xen is a virtual machine monitor or hypervisor for x86 hardware
 (i686-class or higher), which supports running multiple guest

Note xendomains 41 xm/xl fix
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.55
retrieving revision 1.56
diff -u -r1.55 -r1.56
--- wikisrc/ports/xen/howto.mdwn	27 Dec 2014 00:15:40 -0000	1.55
+++ wikisrc/ports/xen/howto.mdwn	27 Dec 2014 00:25:48 -0000	1.56
@@ -339,8 +339,8 @@
         xencommons=YES
         xend=YES
 
-TODO: Explain why if xm is preferred on 4.1, rc.d/xendomains has xl.
-Or fix the package.
+(If you are using xentools41 from before 2014-12-26, change
+rc.d/xendomains to use xm rather than xl.)
 
 For 4.2 with xm, add to rc.conf
 

explain how to switch from grub to /boot
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -r1.54 -r1.55
--- wikisrc/ports/xen/howto.mdwn	27 Dec 2014 00:04:00 -0000	1.54
+++ wikisrc/ports/xen/howto.mdwn	27 Dec 2014 00:15:40 -0000	1.55
@@ -407,10 +407,36 @@
 Note that one must update both the non-Xen kernel typically used for
 rescue purposes and the DOM0 kernel used with Xen.
 
-To convert from grub to /boot, install an mbr bootblock with fdisk,
-bootxx_ with installboot, /boot and /boot.cfg.  This really should be
-no different than completely reinstalling boot blocks on a non-Xen
-system.
+Converting from grub to /boot
+-----------------------------
+
+These instructions were [TODO: will be] used to convert a system from
+grub to /boot.  The system was originally installed in February of
+2006 with a RAID1 setup and grub to boot Xen 2, and has been updated
+over time.  Before these commands, it was running NetBSD 6 i386, Xen
+4.1 and grub, much like the message linked earlier in the grub
+section.
+
+        # Install mbr bootblocks on both disks. 
+        fdisk -i /dev/rwd0d
+        fdisk -i /dev/rwd1d
+        # Install NetBSD primary boot loader (/ is FFSv1) into RAID1 components.
+        installboot -v /dev/rwd0d /usr/mdec/bootxx_ffsv1
+        installboot -v /dev/rwd1d /usr/mdec/bootxx_ffsv1
+        # Install secondary boot loader
+        cp -p /usr/mdec/boot /
+        # Create boog.cfg following earlier guidance:
+        menu=Xen:load /netbsd-XEN3PAE_DOM0.gz console=pc;multiboot /xen.gz dom0_mem=256M
+        menu=Xen.ok:load /netbsd-XEN3PAE_DOM0.ok.gz console=pc;multiboot /xen.ok.gz dom0_mem=256M
+        menu=GENERIC:boot
+        menu=GENERIC single-user:boot -s
+        menu=GENERIC.ok:boot netbsd.ok
+        menu=GENERIC.ok single-user:boot netbsd.ok -s
+        menu=Drop to boot prompt:prompt
+        default=1
+        timeout=30
+
+TODO: actually do this and fix it if necessary.
 
 Updating Xen versions
 ---------------------

reorg ancient grub bits
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -r1.53 -r1.54
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 23:58:18 -0000	1.53
+++ wikisrc/ports/xen/howto.mdwn	27 Dec 2014 00:04:00 -0000	1.54
@@ -49,6 +49,8 @@
 of the dom0.  This can be useful to let a domU run X11, or access some
 network interface or other peripheral.
 
+NetBSD used to support Xen2; this has been removed.
+
 Prerequisites
 -------------
 
@@ -63,15 +65,6 @@
 on i386/amd64 hardware and installing software from pkgsrc.
 See also the [Xen website](http://www.xenproject.org/).
 
-History
--------
-
-NetBSD used to support Xen2; this has been removed.
-
-Before NetBSD's native bootloader could support Xen, the use of
-grub was recommended.  If necessary, see the
-[old grub information](/ports/xen/howto-grub/).
-
 Versions of Xen and NetBSD
 ==========================
 
@@ -302,6 +295,13 @@
 kernel that works without Xen) and fallback versions of the non-Xen
 kernel, Xen, and the dom0 kernel.
 
+Using grub (historic)
+---------------------
+
+Before NetBSD's native bootloader could support Xen, the use of
+grub was recommended.  If necessary, see the
+[old grub information](/ports/xen/howto-grub/).
+
 The [HowTo on Installing into
 RAID-1](http://mail-index.NetBSD.org/port-xen/2006/03/01/0010.html)
 explains how to set up booting a dom0 with Xen using grub with

fix domain0 -> dom0
fix ordering of daemons
Members: 
	ports/xen/howto.mdwn:1.52->1.53 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.52
retrieving revision 1.53
diff -u -r1.52 -r1.53
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 23:46:22 -0000	1.52
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 23:58:18 -0000	1.53
@@ -311,6 +311,8 @@
 Configuring Xen
 ---------------
 
+Xen logs will be in /var/log/xen.
+
 Now, you have a system that will boot Xen and the dom0 kernel, and
 just run the dom0 kernel.  There will be no domUs, and none can be
 started because you still have to configure the dom0 tools.  The
@@ -334,27 +336,27 @@
 
 For 4.1 (and thus xm; xl is believed not to work well), add to rc.conf:
 
-        xend=YES
         xencommons=YES
+        xend=YES
 
 TODO: Explain why if xm is preferred on 4.1, rc.d/xendomains has xl.
 Or fix the package.
 
 For 4.2 with xm, add to rc.conf
 
-        xend=YES
         xencommons=YES
+        xend=YES
 
 For 4.2 with xl (preferred), add to rc.conf:
 
-        TODO: explain if there is a xend replacement
         xencommons=YES
+        TODO: explain if there is a xend replacement
 
 TODO: Recommend for/against xen-watchdog.
 
-After you have configured the daemons and either started them or
-rebooted, run the following (or use xl) to inspect Xen's boot
-messages, available resources, and running domains:
+After you have configured the daemons and either started them (in the
+order given) or rebooted, run the following (or use xl) to inspect
+Xen's boot messages, available resources, and running domains:
 
         # xm dmesg
 	[xen's boot info]
@@ -595,7 +597,7 @@
 TODO: NAT appears to be configured by "vif = [ '' ]".
 
 The MAC address specified is the one used for the interface in the new
-domain.  The interface in domain0 will use this address XOR'd with
+domain.  The interface in dom0 will use this address XOR'd with
 00:00:00:01:00:00.  Random MAC addresses are assigned if not given.
 
 Sizing domains
@@ -695,7 +697,7 @@
         powerd=YES
 
 in rc.conf. This way, the domain will be properly shut down if
-`xm shutdown -R` or `xm shutdown -H` is used on the domain0.
+`xm shutdown -R` or `xm shutdown -H` is used on the dom0.
 
 Your domain should be now ready to work, enjoy.
 
@@ -753,17 +755,17 @@
 PCI passthrough: Using PCI devices in guest domains
 ---------------------------------------------------
 
-The domain0 can give other domains access to selected PCI
+The dom0 can give other domains access to selected PCI
 devices. This can allow, for example, a non-privileged domain to have
 access to a physical network interface or disk controller.  However,
 keep in mind that giving a domain access to a PCI device most likely
 will give the domain read/write access to the whole physical memory,
 as PCs don't have an IOMMU to restrict memory access to DMA-capable
-device.  Also, it's not possible to export ISA devices to non-domain0
+device.  Also, it's not possible to export ISA devices to non-dom0
 domains, which means that the primary VGA adapter can't be exported.
 A guest domain trying to access the VGA registers will panic.
 
-If the domain0 is NetBSD, it has to be running Xen 3.1, as support has
+If the dom0 is NetBSD, it has to be running Xen 3.1, as support has
 not been ported to later versions at this time.
 
 For a PCI device to be exported to a domU, is has to be attached to

reformat pci passthrough
update prmgr/pvgrub a bit
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.51
retrieving revision 1.52
diff -u -r1.51 -r1.52
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 23:36:34 -0000	1.51
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 23:46:22 -0000	1.52
@@ -750,78 +750,74 @@
 [Solaris domU instructions](/ports/xen/howto-solaris/).
 
 
-Using PCI devices in guest domains
-----------------------------------
+PCI passthrough: Using PCI devices in guest domains
+---------------------------------------------------
 
-The domain0 can give other domains access to selected PCI devices. This
-can allow, for example, a non-privileged domain to have access to a
-physical network interface or disk controller. However, keep in mind
-that giving a domain access to a PCI device most likely will give the
-domain read/write access to the whole physical memory, as PCs don't have
-an IOMMU to restrict memory access to DMA-capable device. Also, it's not
-possible to export ISA devices to non-domain0 domains (which means that
-the primary VGA adapter can't be exported. A guest domain trying to
-access the VGA registers will panic).
-
-This functionality is only available in NetBSD-5.1 (and later) domain0
-and domU. If the domain0 is NetBSD, it has to be running Xen 3.1, as
-support has not been ported to later versions at this time.
-
-For a PCI device to be exported to a domU, is has to be attached to the
-`pciback` driver in domain0. Devices passed to the domain0 via the
-pciback.hide boot parameter will attach to `pciback` instead of the
-usual driver. The list of devices is specified as `(bus:dev.func)`,
+The domain0 can give other domains access to selected PCI
+devices. This can allow, for example, a non-privileged domain to have
+access to a physical network interface or disk controller.  However,
+keep in mind that giving a domain access to a PCI device most likely
+will give the domain read/write access to the whole physical memory,
+as PCs don't have an IOMMU to restrict memory access to DMA-capable
+device.  Also, it's not possible to export ISA devices to non-domain0
+domains, which means that the primary VGA adapter can't be exported.
+A guest domain trying to access the VGA registers will panic.
+
+If the domain0 is NetBSD, it has to be running Xen 3.1, as support has
+not been ported to later versions at this time.
+
+For a PCI device to be exported to a domU, is has to be attached to
+the "pciback" driver in dom0.  Devices passed to the dom0 via the
+pciback.hide boot parameter will attach to "pciback" instead of the
+usual driver.  The list of devices is specified as "(bus:dev.func)",
 where bus and dev are 2-digit hexadecimal numbers, and func a
 single-digit number:
 
-    pciback.hide=(00:0a.0)(00:06.0)
+        pciback.hide=(00:0a.0)(00:06.0)
 
-pciback devices should show up in the domain0's boot messages, and the
+pciback devices should show up in the dom0's boot messages, and the
 devices should be listed in the `/kern/xen/pci` directory.
 
-PCI devices to be exported to a domU are listed in the `pci` array of
-the domU's config file, with the format `'0000:bus:dev.func'`
+PCI devices to be exported to a domU are listed in the "pci" array of
+the domU's config file, with the format "0000:bus:dev.func".
 
-    pci = [ '0000:00:06.0', '0000:00:0a.0' ]
+        pci = [ '0000:00:06.0', '0000:00:0a.0' ]
 
-In the domU an `xpci` device will show up, to which one or more pci
-busses will attach. Then the PCI drivers will attach to PCI busses as
-usual. Note that the default NetBSD DOMU kernels do not have `xpci` or
-any PCI drivers built in by default; you have to build your own kernel
-to use PCI devices in a domU. Here's a kernel config example:
-
-    include         "arch/i386/conf/XEN3_DOMU"
-    #include         "arch/i386/conf/XENU"           # in NetBSD 3.0
-
-    # Add support for PCI busses to the XEN3_DOMU kernel
-    xpci* at xenbus ?
-    pci* at xpci ?
-
-    # Now add PCI and related devices to be used by this domain
-    # USB Controller and Devices
-
-    # PCI USB controllers
-    uhci*   at pci? dev ? function ?        # Universal Host Controller (Intel)
-
-    # USB bus support
-    usb*    at uhci?
-
-    # USB Hubs
-    uhub*   at usb?
-    uhub*   at uhub? port ? configuration ? interface ?
-
-    # USB Mass Storage
-    umass*  at uhub? port ? configuration ? interface ?
-    wd*     at umass?
-    # SCSI controllers
-    ahc*    at pci? dev ? function ?        # Adaptec [23]94x, aic78x0 SCSI
-
-    # SCSI bus support (for both ahc and umass)
-    scsibus* at scsi?
-
-    # SCSI devices
-    sd*     at scsibus? target ? lun ?      # SCSI disk drives
-    cd*     at scsibus? target ? lun ?      # SCSI CD-ROM drives
+In the domU an "xpci" device will show up, to which one or more pci
+busses will attach.  Then the PCI drivers will attach to PCI busses as
+usual.  Note that the default NetBSD DOMU kernels do not have "xpci"
+or any PCI drivers built in by default; you have to build your own
+kernel to use PCI devices in a domU.  Here's a kernel config example;
+note that only the "xpci" lines are unusual.
+
+        include         "arch/i386/conf/XEN3_DOMU"
+
+        # Add support for PCI busses to the XEN3_DOMU kernel
+        xpci* at xenbus ?
+        pci* at xpci ?
+
+        # PCI USB controllers
+        uhci*   at pci? dev ? function ?        # Universal Host Controller (Intel)
+
+        # USB bus support
+        usb*    at uhci?
+
+        # USB Hubs
+        uhub*   at usb?
+        uhub*   at uhub? port ? configuration ? interface ?
+
+        # USB Mass Storage
+        umass*  at uhub? port ? configuration ? interface ?
+        wd*     at umass?
+        # SCSI controllers
+        ahc*    at pci? dev ? function ?        # Adaptec [23]94x, aic78x0 SCSI
+
+        # SCSI bus support (for both ahc and umass)
+        scsibus* at scsi?
+
+        # SCSI devices
+        sd*     at scsibus? target ? lun ?      # SCSI disk drives
+        cd*     at scsibus? target ? lun ?      # SCSI CD-ROM drives
 
 
 NetBSD as a domU in a VPS
@@ -832,10 +828,29 @@
 virtual private server where you do not control or have access to the
 dom0.
 
-TODO: Perhaps reference panix, prmgr, amazon as interesting examples.
+VPS operators provide varying degrees of access and mechanisms for
+configuration.  The big issue is usually how one controls which kernel
+is booted, because the kernel is nominally in the dom0 filesystem (to
+which VPS users do not normally have acesss).
+
+A VPS user may want to compile a kernel for security updates, to run
+npf, run IPsec, or any other reason why someone would want to change
+their kernel.
+
+One approach is to have an adminstrative interface to upload a kernel,
+or to select from a prepopulated list.
+
+Otehr approaches are pvgrub and py-grub, which are ways to start a
+bootloader from the dom0 instead of the actual domU kernel, and for
+that loader to then load a kernel from the domU filesystem.  This is
+closer to a regular physical computer, where someone who controls a
+machine can replace the kernel.
+
+prmgr and pvgrub
+----------------
 
-TODO: Somewhere, discuss pvgrub and py-grub to load the domU kernel
-from the domU filesystem.
+TODO: Perhaps reference panix, prmgr, amazon as interesting examples.
+Explain what prmgr does.
 
 Using npf
 ---------

better link to SMP dom0 issues
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -r1.50 -r1.51
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 20:28:45 -0000	1.50
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 23:36:34 -0000	1.51
@@ -204,7 +204,9 @@
 Xen daemons when not running Xen.
 
 Note that NetBSD as dom0 does not support multiple CPUs.  This will
-limit the performance of the Xen/dom0 workstation approach.
+limit the performance of the Xen/dom0 workstation approach.  In theory
+the only issue is that the "backend drivers" are not yet MPSAFE:
+  http://mail-index.netbsd.org/netbsd-users/2014/08/29/msg015195.html
 
 Installation of NetBSD
 ----------------------

Move solaris to own page.
--- /dev/null	2014-12-26 20:20:01.000000000 +0000
+++ wikisrc/ports/xen/howto-solaris.mdwn	2014-12-26 20:28:49.000000000 +0000
@@ -0,0 +1,134 @@
+Solaris domU creation
+=====================
+
+Download an Opensolaris [release](http://opensolaris.org/os/downloads/)
+or [development snapshot](http://genunix.org/) DVD image. Attach the DVD
+image to a MAN.VND.4 device. Copy the kernel and ramdisk filesystem
+image to your dom0 filesystem.
+
+    dom0# mkdir /root/solaris
+    dom0# vnconfig vnd0 osol-1002-124-x86.iso
+    dom0# mount /dev/vnd0a /mnt
+
+    ## for a 64-bit guest
+    dom0# cp /mnt/boot/amd64/x86.microroot /root/solaris
+    dom0# cp /mnt/platform/i86xpv/kernel/amd64/unix /root/solaris
+
+    ## for a 32-bit guest
+    dom0# cp /mnt/boot/x86.microroot /root/solaris
+    dom0# cp /mnt/platform/i86xpv/kernel/unix /root/solaris
+
+    dom0# umount /mnt
+          
+
+Keep the MAN.VND.4 configured. For some reason the boot process stalls
+unless the DVD image is attached to the guest as a "phy" device. Create
+an initial configuration file with the following contents. Substitute
+*/dev/wd0k* with an empty partition at least 8 GB large.
+
+    memory = 640
+    name = 'solaris'
+    disk = [ 'phy:/dev/wd0k,0,w' ]
+    disk += [ 'phy:/dev/vnd0d,6:cdrom,r' ]
+    vif = [ 'bridge=bridge0' ]
+    kernel = '/root/solaris/unix'
+    ramdisk = '/root/solaris/x86.microroot'
+    # for a 64-bit guest
+    extra = '/platform/i86xpv/kernel/amd64/unix - nowin -B install_media=cdrom'
+    # for a 32-bit guest
+    #extra = '/platform/i86xpv/kernel/unix - nowin -B install_media=cdrom'
+          
+
+Start the guest.
+
+    dom0# xm create -c solaris.cfg
+    Started domain solaris
+                          v3.3.2 chgset 'unavailable'
+    SunOS Release 5.11 Version snv_124 64-bit
+    Copyright 1983-2009 Sun Microsystems, Inc.  All rights reserved.
+    Use is subject to license terms.
+    Hostname: opensolaris
+    Remounting root read/write
+    Probing for device nodes ...
+    WARNING: emlxs: ddi_modopen drv/fct failed: err 2
+    Preparing live image for use
+    Done mounting Live image
+          
+
+Make sure the network is configured. Note that it can take a minute for
+the xnf0 interface to appear.
+
+    opensolaris console login: jack
+    Password: jack
+    Sun Microsystems Inc.   SunOS 5.11      snv_124 November 2008
+    jack@opensolaris:~$ pfexec sh
+    sh-3.2# ifconfig -a
+    sh-3.2# exit
+          
+
+Set a password for VNC and start the VNC server which provides the X11
+display where the installation program runs.
+
+    jack@opensolaris:~$ vncpasswd
+    Password: solaris
+    Verify: solaris
+    jack@opensolaris:~$ cp .Xclients .vnc/xstartup
+    jack@opensolaris:~$ vncserver :1
+          
+
+From a remote machine connect to the VNC server. Use `ifconfig xnf0` on
+the guest to find the correct IP address to use.
+
+    remote$ vncviewer 172.18.2.99:1
+          
+
+It is also possible to launch the installation on a remote X11 display.
+
+    jack@opensolaris:~$ export DISPLAY=172.18.1.1:0
+    jack@opensolaris:~$ pfexec gui-install
+           
+
+After the GUI installation is complete you will be asked to reboot.
+Before that you need to determine the ZFS ID for the new boot filesystem
+and update the configuration file accordingly. Return to the guest
+console.
+
+    jack@opensolaris:~$ pfexec zdb -vvv rpool | grep bootfs
+                    bootfs = 43
+    ^C
+    jack@opensolaris:~$
+           
+
+The final configuration file should look like this. Note in particular
+the last line.
+
+    memory = 640
+    name = 'solaris'
+    disk = [ 'phy:/dev/wd0k,0,w' ]
+    vif = [ 'bridge=bridge0' ]
+    kernel = '/root/solaris/unix'
+    ramdisk = '/root/solaris/x86.microroot'
+    extra = '/platform/i86xpv/kernel/amd64/unix -B zfs-bootfs=rpool/43,bootpath="/xpvd/xdf@0:a"'
+           
+
+Restart the guest to verify it works correctly.
+
+    dom0# xm destroy solaris
+    dom0# xm create -c solaris.cfg
+    Using config file "./solaris.cfg".
+    v3.3.2 chgset 'unavailable'
+    Started domain solaris
+    SunOS Release 5.11 Version snv_124 64-bit
+    Copyright 1983-2009 Sun Microsystems, Inc.  All rights reserved.
+    Use is subject to license terms.
+    WARNING: emlxs: ddi_modopen drv/fct failed: err 2
+    Hostname: osol
+    Configuring devices.
+    Loading smf(5) service descriptions: 160/160
+    svccfg import warnings. See /var/svc/log/system-manifest-import:default.log .
+    Reading ZFS config: done.
+    Mounting ZFS filesystems: (6/6)
+    Creating new rsa public/private host key pair
+    Creating new dsa public/private host key pair
+
+    osol console login:
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.49
retrieving revision 1.50
diff -u -r1.49 -r1.50
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 20:25:19 -0000	1.49
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 20:28:45 -0000	1.50
@@ -744,138 +744,9 @@
 Creating an unprivileged Solaris domain (domU)
 ----------------------------------------------
 
-Download an Opensolaris [release](http://opensolaris.org/os/downloads/)
-or [development snapshot](http://genunix.org/) DVD image. Attach the DVD
-image to a MAN.VND.4 device. Copy the kernel and ramdisk filesystem
-image to your dom0 filesystem.
-
-    dom0# mkdir /root/solaris
-    dom0# vnconfig vnd0 osol-1002-124-x86.iso
-    dom0# mount /dev/vnd0a /mnt
-
-    ## for a 64-bit guest
-    dom0# cp /mnt/boot/amd64/x86.microroot /root/solaris
-    dom0# cp /mnt/platform/i86xpv/kernel/amd64/unix /root/solaris
-
-    ## for a 32-bit guest
-    dom0# cp /mnt/boot/x86.microroot /root/solaris
-    dom0# cp /mnt/platform/i86xpv/kernel/unix /root/solaris
-
-    dom0# umount /mnt
-          
-
-Keep the MAN.VND.4 configured. For some reason the boot process stalls
-unless the DVD image is attached to the guest as a "phy" device. Create
-an initial configuration file with the following contents. Substitute
-*/dev/wd0k* with an empty partition at least 8 GB large.
-
-    memory = 640
-    name = 'solaris'
-    disk = [ 'phy:/dev/wd0k,0,w' ]
-    disk += [ 'phy:/dev/vnd0d,6:cdrom,r' ]
-    vif = [ 'bridge=bridge0' ]
-    kernel = '/root/solaris/unix'
-    ramdisk = '/root/solaris/x86.microroot'
-    # for a 64-bit guest
-    extra = '/platform/i86xpv/kernel/amd64/unix - nowin -B install_media=cdrom'
-    # for a 32-bit guest
-    #extra = '/platform/i86xpv/kernel/unix - nowin -B install_media=cdrom'
-          
-
-Start the guest.
-
-    dom0# xm create -c solaris.cfg
-    Started domain solaris
-                          v3.3.2 chgset 'unavailable'
-    SunOS Release 5.11 Version snv_124 64-bit
-    Copyright 1983-2009 Sun Microsystems, Inc.  All rights reserved.
-    Use is subject to license terms.
-    Hostname: opensolaris
-    Remounting root read/write
-    Probing for device nodes ...
-    WARNING: emlxs: ddi_modopen drv/fct failed: err 2
-    Preparing live image for use

(Diff truncated)
redo netbsd domU instructions.
clean up Linux domU from pandoc conversion.
Members: 
	ports/xen/howto.mdwn:1.48->1.49 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.48
retrieving revision 1.49
diff -u -r1.48 -r1.49
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 20:00:44 -0000	1.48
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 20:25:19 -0000	1.49
@@ -263,8 +263,20 @@
 of a NetBSD build.  Both xen and NetBSD may be left compressed.  (If
 using i386, use releasedir/i386/binary/kernel/netbsd-XEN3PAE_DOM0.gz.)
 
-In a dom0 kernel, kernfs is mandatory for xend to comunicate with the
-kernel, so ensure that /kern is in fstab.
+With Xen as the kernel, you must provide a dom0 NetBSD kernel to be
+used as a module; place this in /.  Suitable kernels are provided in
+releasedir/binary/kernel:
+
+        i386 XEN3_DOM0
+        i386 XEN3PAE_DOM0
+	amd64 XEN3_DOM0
+
+The first one is only for use with Xen 3.1 and i386-mode Xen (and you
+should not do this).  Current Xen always uses PAE on i386, but you
+should generally use amd64 for the dom0.  In a dom0 kernel, kernfs is
+mandatory for xend to comunicate with the kernel, so ensure that /kern
+is in fstab.  TODO: Say this is default, or file a PR and give a
+reference.
 
 Because you already installed NetBSD, you have a working boot setup
 with an MBR bootblock, either bootxx_ffsv1 or bootxx_ffsv2 at the
@@ -541,12 +553,14 @@
 "hda1" or "sda1" are common.  In a NetBSD domU, the first disk appears
 as xbd0, the second as xbd1, and so on.  However, xm/xl demand a
 second argument.  The name given is converted to a major/minor by
-consulting /dev and this is passed to the domU (TODO: check this).  In
-the general case, the dom0 and domU can be different operating
+calling stat(2) on the name in /dev and this is passed to the domU.
+In the general case, the dom0 and domU can be different operating
 systems, and it is an unwarranted assumption that they have consistent
 numbering in /dev, or even that the dom0 OS has a /dev.  With NetBSD
 as both dom0 and domU, using values of 0x0 for the first disk and 0x1
-for the second works fine and avoids this issue.
+for the second works fine and avoids this issue.  For a GNU/Linux
+guest, one can create /dev/hda1 in /dev, or to pass 0x301 for
+/dev/hda1.
 
 The third element is "w" for writable disks, and "r" for read-only
 disks.
@@ -578,6 +592,10 @@
 dom0.  This is often appropriate when running Xen on a workstation.
 TODO: NAT appears to be configured by "vif = [ '' ]".
 
+The MAC address specified is the one used for the interface in the new
+domain.  The interface in domain0 will use this address XOR'd with
+00:00:00:01:00:00.  Random MAC addresses are assigned if not given.
+
 Sizing domains
 --------------
 
@@ -605,238 +623,58 @@
 =============================================
 
 Creating domUs is almost entirely independent of operating system.  We
-first explain NetBSD, and then differences for Linux and Solaris.
-Note that you must have already completed the dom0 setup so that "xm
-list" (or "xl list") works.
+have already presented the basics of config files.  Note that you must
+have already completed the dom0 setup so that "xl list" (or "xm list")
+works.
 
 Creating an unprivileged NetBSD domain (domU)
 ---------------------------------------------
 
-'xm create' allows you to create a new domain. It uses a config file in
-PKG\_SYSCONFDIR for its parameters. By default, this file will be in
-`/usr/pkg/etc/xen/`. On creation, a kernel has to be specified, which
-will be executed in the new domain (this kernel is in the *domain0* file
-system, not on the new domain virtual disk; but please note, you should
-install the same kernel into *domainU* as `/netbsd` in order to make
-your system tools, like savecore(8), work). A suitable kernel is
-provided as part of the i386 and amd64 binary sets: XEN3\_DOMU.
-
-Here is an /usr/pkg/etc/xen/nbsd example config file:
-
-    #  -*- mode: python; -*-
-    #============================================================================
-    # Python defaults setup for 'xm create'.
-    # Edit this file to reflect the configuration of your system.
-    #============================================================================
-
-    #----------------------------------------------------------------------------
-    # Kernel image file. This kernel will be loaded in the new domain.
-    kernel = "/home/bouyer/netbsd-XEN3_DOMU"
-    #kernel = "/home/bouyer/netbsd-INSTALL_XEN3_DOMU"
-
-    # Memory allocation (in megabytes) for the new domain.
-    memory = 128
-
-    # A handy name for your new domain. This will appear in 'xm list',
-    # and you can use this as parameters for xm in place of the domain
-    # number. All domains must have different names.
-    #
-    name = "nbsd"
-
-    # The number of virtual CPUs this domain has.
-    #
-    vcpus = 1
-
-    #----------------------------------------------------------------------------
-    # Define network interfaces for the new domain.
-
-    # Number of network interfaces (must be at least 1). Default is 1.
-    nics = 1
-
-    # Define MAC and/or bridge for the network interfaces.
-    #
-    # The MAC address specified in ``mac'' is the one used for the interface
-    # in the new domain. The interface in domain0 will use this address XOR'd
-    # with 00:00:00:01:00:00 (i.e. aa:00:00:51:02:f0 in our example). Random
-    # MACs are assigned if not given.
-    #
-    # ``bridge'' is a required parameter, which will be passed to the
-    # vif-script called by xend(8) when a new domain is created to configure
-    # the new xvif interface in domain0.
-    #
-    # In this example, the xvif is added to bridge0, which should have been
-    # set up prior to the new domain being created -- either in the
-    # ``network'' script or using a /etc/ifconfig.bridge0 file.
-    #
-    vif = [ 'mac=aa:00:00:50:02:f0, bridge=bridge0' ]
-
-    #----------------------------------------------------------------------------
-    # Define the disk devices you want the domain to have access to, and
-    # what you want them accessible as.
-    #
-    # Each disk entry is of the form:
-    #
-    #   phy:DEV,VDEV,MODE
-    #
-    # where DEV is the device, VDEV is the device name the domain will see,
-    # and MODE is r for read-only, w for read-write.  You can also create
-    # file-backed domains using disk entries of the form:
-    #
-    #   file:PATH,VDEV,MODE
-    #
-    # where PATH is the path to the file used as the virtual disk, and VDEV
-    # and MODE have the same meaning as for ``phy'' devices.
-    #
-    # VDEV doesn't really matter for a NetBSD guest OS (it's just used as an index),
-    # but it does for Linux.
-    # Worse, the device has to exist in /dev/ of domain0, because xm will
-    # try to stat() it. This means that in order to load a Linux guest OS
-    # from a NetBSD domain0, you'll have to create /dev/hda1, /dev/hda2, ...
-    # on domain0, with the major/minor from Linux :(
-    # Alternatively it's possible to specify the device number in hex,
-    # e.g. 0x301 for /dev/hda1, 0x302 for /dev/hda2, etc ...
+See the earlier config file, and adjust memory.  Decide on how much
+storage you will provide, and prepare it (file or lvm).
 
-    disk = [ 'phy:/dev/wd0e,0x1,w' ]
-    #disk = [ 'file:/var/xen/nbsd-disk,0x01,w' ]
-    #disk = [ 'file:/var/xen/nbsd-disk,0x301,w' ]
+While the kernel will be obtained from the dom0 filesystem, the same
+file should be present in the domU as /netbsd so that tools like
+savecore(8) can work.   (This is helpful but not necessary.)
+
+The kernel must be specifically for Xen and for use as a domU.  The
+i386 and amd64 provide the following kernels:
+
+        i386 XEN3_DOMU
+        i386 XEN3PAE_DOMU
+	amd64 XEN3_DOMU
+
+Unless using Xen 3.1 (and you shouldn't) with i386-mode Xen, you must
+use the PAE version of the i386 kernel.
+
+This will boot NetBSD, but this is not that useful if the disk is
+empty.  One approach is to unpack sets onto the disk outside of xen
+(by mounting it, just as you would prepare a physical disk for a
+system you can't run the installer on).
+
+A second approach is to run an INSTALL kernel, which has a miniroot
+and can load sets from the network.  To do this, copy the INSTALL
+kernel to / and change the kernel line in the config file to:
 
-    #----------------------------------------------------------------------------
-    # Set the kernel command line for the new domain.
+        kernel = "/home/bouyer/netbsd-INSTALL_XEN3_DOMU"
 
-    # Set root device. This one does matter for NetBSD
-    root = "xbd0"
-    # extra parameters passed to the kernel
-    # this is where you can set boot flags like -s, -a, etc ...
-    #extra = ""
-
-    #----------------------------------------------------------------------------

(Diff truncated)
move config file section earlier.
expand on disk arguments.
explain xendomains
Members: 
	ports/xen/howto.mdwn:1.47->1.48 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.47
retrieving revision 1.48
diff -u -r1.47 -r1.48
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 18:35:45 -0000	1.47
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 20:00:44 -0000	1.48
@@ -425,16 +425,84 @@
 Entropy in domUs can be an issue; physical disks and network are on
 the dom0.  NetBSD's /dev/random system works, but is often challenged.
 
+Config files
+------------
+
+There is no good order to present config files and the concepts
+surrounding what is being configured.  We first show an example config
+file, and then in the various sections give details.
+
+See (at least in xentools41) /usr/pkg/share/examples/xen/xmexample*,
+for a large number of well-commented examples, mostly for running
+GNU/Linux.
+
+The following is an example minimal domain configuration file
+"/usr/pkg/etc/xen/foo".  It is (with only a name change) an actual
+known working config file on Xen 4.1 (NetBSD 5 amd64 dom0 and NetBSD 5
+i386 domU).  The domU serves as a network file server.
+
+        # -*- mode: python; -*-
+
+        kernel = "/netbsd-XEN3PAE_DOMU-i386-foo.gz"
+        memory = 1024
+        vif = [ 'mac=aa:00:00:d1:00:09,bridge=bridge0' ]
+        disk = [ 'file:/n0/xen/foo-wd0,0x0,w',
+                 'file:/n0/xen/foo-wd1,0x1,w' ]
+
+The domain will have the same name as the file.  The kernel has the
+host/domU name in it, so that on the dom0 one can update the various
+domUs independently.  The vif line causes an interface to be provided,
+with a specific mac address (do not reuse MAC addresses!), in bridge
+mode.  Two disks are provided, and they are both writable; the bits
+are stored in files and Xen attaches them to a vnd(4) device in the
+dom0 on domain creation.  The system treates xbd0 as the boot device
+without needing explicit configuration.
+
+By default xm looks for domain config files in /usr/pkg/etc/xen.  Note
+that "xm create" takes the name of a config file, while other commands
+take the name of a domain.  To create the domain, connect to the
+console, create the domain while attaching the console, shutdown the
+domain, and see if it has finished stopping, do (or xl with Xen >=
+4.2):
+
+        xm create foo
+        xm console foo
+        xm create -c foo
+        xm shutdown foo
+	xm list
+
+Typing ^] will exit the console session.  Shutting down a domain is
+equivalent to pushing the power button; a NetBSD domU will receive a
+power-press event and do a clean shutdown.  Shutting down the dom0
+will trigger controlled shutdowns of all configured domUs.
+
+domU kernels
+------------
+
+On a physical computer, the BIOS reads sector 0, and a chain of boot
+loaders finds and loads a kernel.  Normally this comes from the root
+filesystem.  With Xen domUs, the process is totally different.  The
+normal path is for the domU kernel to be a file in the dom0's
+filesystem.  At the request of the dom0, Xen loads that kernel into a
+new domU instance and starts execution.  While domU kernels can be
+anyplace, reasonable places to store domU kernels on the dom0 are in /
+(so they are near the dom0 kernel), in /usr/pkg/etc/xen (near the
+config files), or in /u0/xen (where the vdisks are).
+
+See the VPS section near the end for discussion of alternate ways to
+obtain domU kernels.
+
 CPU and memory
 --------------
 
-A domain is provided with some number of vcpus, less than the
-number of cpus seen by the hypervisor.  For a dom0, this is controlled
-by the boot argument "dom0_max_vcpus=1".  For a domU, it is controlled
-from the config file.
-
-A domain is provided with memory, In the straightforward case, the sum
-of the the memory allocated to the dom0 and all domUs must be less
+A domain is provided with some number of vcpus, less than the number
+of cpus seen by the hypervisor.  (For a dom0, this is controlled by
+the boot argument "dom0_max_vcpus=1".)  For a domU, it is controlled
+from the config file by the "vcpus = N" directive.
+
+A domain is provided with memory; this is controlled in the config
+file by "memory = N" (in megabytes).  In the straightforward case, the
+sum of the the memory allocated to the dom0 and all domUs must be less
 than the available memory.
 
 Xen also provides a "balloon" driver, which can be used to let domains
@@ -460,7 +528,28 @@
         dd if=/dev/zero of=foo-xbd0 bs=1m count=4096
 
 With the lvm style, one creates logical devices.  They are then used
-similarly to vnds.
+similarly to vnds.  TODO: Add an example with lvm.
+
+In domU config files, the disks are defined as a sequence of 3-tuples.
+The first element is "method:/path/to/disk".  Common methods are
+"file:" for file-backed vnd. and "phy:" for something that is already
+a (TODO: character or block) device.
+
+The second element is an artifact of how virtual disks are passed to
+Linux, and a source of confusion with NetBSD Xen usage.  Linux domUs
+are given a device name to associate with the disk, and values like
+"hda1" or "sda1" are common.  In a NetBSD domU, the first disk appears
+as xbd0, the second as xbd1, and so on.  However, xm/xl demand a
+second argument.  The name given is converted to a major/minor by
+consulting /dev and this is passed to the domU (TODO: check this).  In
+the general case, the dom0 and domU can be different operating
+systems, and it is an unwarranted assumption that they have consistent
+numbering in /dev, or even that the dom0 OS has a /dev.  With NetBSD
+as both dom0 and domU, using values of 0x0 for the first disk and 0x1
+for the second works fine and avoids this issue.
+
+The third element is "w" for writable disks, and "r" for read-only
+disks.
 
 Virtual Networking
 ------------------
@@ -473,13 +562,13 @@
 configurations.  We focus on two common and useful cases for which
 there are existing scripts: bridging and NAT.
 
-With bridging, the domU perceives itself to be on the same network as
-the dom0.  For server virtualization, this is usually best.  Bridging
-is accomplished by creating a bridge(4) device and adding the dom0's
-physical interface and the various xvifN.0 interfaces to the bridge.
-One specifies "bridge=bridge0" in the domU config file.  The bridge
-must be set up already in the dom0; an example /etc/ifconfig.bridge0
-is:
+With bridging (in the example above), the domU perceives itself to be
+on the same network as the dom0.  For server virtualization, this is
+usually best.  Bridging is accomplished by creating a bridge(4) device
+and adding the dom0's physical interface and the various xvifN.0
+interfaces to the bridge.  One specifies "bridge=bridge0" in the domU
+config file.  The bridge must be set up already in the dom0; an
+example /etc/ifconfig.bridge0 is:
 
         create
         up
@@ -487,6 +576,7 @@
 
 With NAT, the domU perceives itself to be behind a NAT running on the
 dom0.  This is often appropriate when running Xen on a workstation.
+TODO: NAT appears to be configured by "vif = [ '' ]".
 
 Sizing domains
 --------------
@@ -500,60 +590,16 @@
 just like updating physical disks, but without having to be there and
 without those pesky connectors.
 
-domU kernels
-------------
-
-On a physical computer, the BIOS reads sector 0, and a chain of boot
-loaders finds and loads a kernel.  Normally this comes from the root
-filesystem.  With Xen domUs, the process is totally different.  The
-normal path is for the domU kernel to be a file in the dom0's
-filesystem.  At the request of the dom0, Xen loads that kernel into a
-new domU instance and starts execution.  While domU kernels can be
-anyplace, reasonable places to store domU kernels on the dom0 are in /
-(so they are near the dom0 kernel), in /usr/pkg/etc/xen (near the
-config files), or in /u0/xen (where the vdisks are).
-
-See the VPS section near the end for discussion of alternate ways to
-obtain domU kernels.
-
-Config files
-------------
-
-The following is an example domain configuration file
-"/usr/pkg/etc/xen/foo", lightly sanitized from a known working on Xen
-4.1 (NetBSD 5 amd64 dom0 and NetBSD 6 i386 domU):
-
-        # -*- mode: python; -*-
-
-        kernel = "/netbsd-XEN3PAE_DOMU-i386-foo.gz"
-        memory = 1024
-        #cpu = -1
-        vif = [ 'mac=aa:00:00:d1:00:09,bridge=bridge0' ]
-        disk = [ 'file:/n0/xen/foo-wd0,0x1,w',
-                 'file:/n0/xen/foo-wd1,0x2,w' ]
-        root = "xbd0"
-        autorestart = True
-

(Diff truncated)
clean up example config
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.46
retrieving revision 1.47
diff -u -r1.46 -r1.47
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 16:43:51 -0000	1.46
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 18:35:45 -0000	1.47
@@ -519,34 +519,26 @@
 Config files
 ------------
 
-The following is an example domain configuration file, lightly
-sanitized from a known working on Xen 4.1 (NetBSD 5 amd64 dom0 and
-NetBSD 6 i386 domU):
+The following is an example domain configuration file
+"/usr/pkg/etc/xen/foo", lightly sanitized from a known working on Xen
+4.1 (NetBSD 5 amd64 dom0 and NetBSD 6 i386 domU):
 
         # -*- mode: python; -*-
 
         kernel = "/netbsd-XEN3PAE_DOMU-i386-foo.gz"
-
         memory = 1024
-
-        name = "foo"
-
         #cpu = -1
-
         vif = [ 'mac=aa:00:00:d1:00:09,bridge=bridge0' ]
-
         disk = [ 'file:/n0/xen/foo-wd0,0x1,w',
                  'file:/n0/xen/foo-wd1,0x2,w' ]
-
         root = "xbd0"
-
         autorestart = True
 
-The kernel has the host/domU name in it, so that on the dom0 one can
-update the various domUs independently.  The vif line causes an
-interface to be provided, with a specific mac address (do not reuse
-MAC addresses!), in bridge mode.  Two disks are provided, and they are
-writable.
+The domain will have the same name as the file.  The kernel has the
+host/domU name in it, so that on the dom0 one can update the various
+domUs independently.  The vif line causes an interface to be provided,
+with a specific mac address (do not reuse MAC addresses!), in bridge
+mode.  Two disks are provided, and they are writable.
 
 TODO: explain if the root line is really necessary.
 TODO: explain or remove autorestart.
@@ -697,7 +689,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.46 2014/12/26 16:43:51 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.47 2014/12/26 18:35:45 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

explain networking
add a domU example config
Members: 
	ports/xen/howto.mdwn:1.45->1.46 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -r1.45 -r1.46
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 16:17:25 -0000	1.45
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 16:43:51 -0000	1.46
@@ -465,19 +465,29 @@
 Virtual Networking
 ------------------
 
-TODO: explain xvif concept, and that it's general.
-
-There are two normal styles: bridging and NAT.
+Xen provides virtual ethernets, each of which connects the dom0 and a
+domU.  For each virtual network, there is an interface "xvifN.M" in
+the dom0, and in domU index N, a matching interface xennetM (NetBSD
+name).  The interfaces behave as if there is an Ethernet with two
+adaptors connected.  From this primitive, one can construct various
+configurations.  We focus on two common and useful cases for which
+there are existing scripts: bridging and NAT.
 
 With bridging, the domU perceives itself to be on the same network as
-the dom0.  For server virtualization, this is usually best.
+the dom0.  For server virtualization, this is usually best.  Bridging
+is accomplished by creating a bridge(4) device and adding the dom0's
+physical interface and the various xvifN.0 interfaces to the bridge.
+One specifies "bridge=bridge0" in the domU config file.  The bridge
+must be set up already in the dom0; an example /etc/ifconfig.bridge0
+is:
+
+        create
+        up
+        !brconfig bridge0 add wm0
 
 With NAT, the domU perceives itself to be behind a NAT running on the
 dom0.  This is often appropriate when running Xen on a workstation.
 
-One can construct arbitrary other configurations, but there is no
-script support.
-
 Sizing domains
 --------------
 
@@ -509,9 +519,41 @@
 Config files
 ------------
 
-TODO: give example config files.   Use both lvm and vnd.
+The following is an example domain configuration file, lightly
+sanitized from a known working on Xen 4.1 (NetBSD 5 amd64 dom0 and
+NetBSD 6 i386 domU):
+
+        # -*- mode: python; -*-
+
+        kernel = "/netbsd-XEN3PAE_DOMU-i386-foo.gz"
+
+        memory = 1024
+
+        name = "foo"
+
+        #cpu = -1
+
+        vif = [ 'mac=aa:00:00:d1:00:09,bridge=bridge0' ]
+
+        disk = [ 'file:/n0/xen/foo-wd0,0x1,w',
+                 'file:/n0/xen/foo-wd1,0x2,w' ]
+
+        root = "xbd0"
+
+        autorestart = True
+
+The kernel has the host/domU name in it, so that on the dom0 one can
+update the various domUs independently.  The vif line causes an
+interface to be provided, with a specific mac address (do not reuse
+MAC addresses!), in bridge mode.  Two disks are provided, and they are
+writable.
+
+TODO: explain if the root line is really necessary.
+TODO: explain or remove autorestart.
+
+TODO: Add an example with lvm
 
-TODO: explain the mess with 3 arguments for disks and how to cope (0x1).
+TODO: explain, someplace the mess with 3 arguments for disks and how to cope (0x1).
 
 Starting domains
 ----------------
@@ -655,7 +697,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.45 2014/12/26 16:17:25 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.46 2014/12/26 16:43:51 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

note that small-memory machines can be used for experimentation.
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.44
retrieving revision 1.45
diff -u -r1.44 -r1.45
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 14:20:27 -0000	1.44
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 16:17:25 -0000	1.45
@@ -181,6 +181,10 @@
 NetBSD install to a dom0 install by just changing the kernel and boot
 configuration.
 
+For experimenting with Xen, a machine with as little as 1G of RAM and
+100G of disk can work.  For running many domUs in productions, far
+more will be needed.
+
 Styles of dom0 operation
 ------------------------
 
@@ -651,7 +655,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.44 2014/12/26 14:20:27 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.45 2014/12/26 16:17:25 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

Add TODO entry about npf on domU
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.43
retrieving revision 1.44
diff -u -r1.43 -r1.44
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 13:15:32 -0000	1.43
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 14:20:27 -0000	1.44
@@ -651,7 +651,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.43 2014/12/26 13:15:32 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.44 2014/12/26 14:20:27 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #
@@ -1041,3 +1041,12 @@
 
 TODO: Somewhere, discuss pvgrub and py-grub to load the domU kernel
 from the domU filesystem.
+
+Using npf
+---------
+
+In standard kernels, npf is a module, and thus cannot be loadeed in a
+DOMU kernel.
+
+TODO: explain how to compile npf into a custom kernel, answering:
+http://mail-index.netbsd.org/netbsd-users/2014/12/26/msg015576.html

hoist some notes from netbsd domU to dom0 setup
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -r1.42 -r1.43
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 13:10:00 -0000	1.42
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 13:15:32 -0000	1.43
@@ -301,6 +301,11 @@
 only be used if you plan on using "xm".  Do NOT enable xend if you
 plan on using "xl" as it will cause problems.
 
+The installation of NetBSD should already have created devices for xen
+(xencons, xenevt), but if they are not present, create them:
+
+        cd /dev && sh MAKEDEV xen
+
 TODO: Give 3.1 advice (or remove it from pkgsrc).
 
 For 3.3 (and thus xm), add to rc.conf (but note that you should have
@@ -329,13 +334,17 @@
 
 TODO: Recommend for/against xen-watchdog.
 
-After you have configured the daemons and eitehr started them or
+After you have configured the daemons and either started them or
 rebooted, run the following (or use xl) to inspect Xen's boot
 messages, available resources, and running domains:
 
-        xm dmesg
-        xm info
-        xm list
+        # xm dmesg
+	[xen's boot info]
+        # xm info
+	[available memory, etc.]
+        # xm list
+        Name              Id  Mem(MB)  CPU  State  Time(s)  Console
+        Domain-0           0       64    0  r----     58.1
 
 anita (for testing NetBSD)
 --------------------------
@@ -513,27 +522,12 @@
 
 Creating domUs is almost entirely independent of operating system.  We
 first explain NetBSD, and then differences for Linux and Solaris.
+Note that you must have already completed the dom0 setup so that "xm
+list" (or "xl list") works.
 
 Creating an unprivileged NetBSD domain (domU)
 ---------------------------------------------
 
-Once you have *domain0* running, you need to start the xen tool daemon
-(`/usr/pkg/share/examples/rc.d/xend start`) and the xen backend daemon
-(`/usr/pkg/share/examples/rc.d/xenbackendd start` for Xen3\*,
-`/usr/pkg/share/examples/rc.d/xencommons start` for Xen4.\*). Make sure
-that `/dev/xencons` and `/dev/xenevt` exist before starting `xend`. You
-can create them with this command:
-
-    # cd /dev && sh MAKEDEV xen
-
-xend will write logs to `/var/log/xend.log` and
-`/var/log/xend-debug.log`. You can then control xen with the xm tool.
-'xm list' will show something like:
-
-    # xm list
-    Name              Id  Mem(MB)  CPU  State  Time(s)  Console
-    Domain-0           0       64    0  r----     58.1
-
 'xm create' allows you to create a new domain. It uses a config file in
 PKG\_SYSCONFDIR for its parameters. By default, this file will be in
 `/usr/pkg/etc/xen/`. On creation, a kernel has to be specified, which
@@ -657,7 +651,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.42 2014/12/26 13:10:00 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.43 2014/12/26 13:15:32 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

clarify start/reboot after enabling dom0 daemons
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.41
retrieving revision 1.42
diff -u -r1.41 -r1.42
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 13:04:31 -0000	1.41
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 13:10:00 -0000	1.42
@@ -329,9 +329,9 @@
 
 TODO: Recommend for/against xen-watchdog.
 
-After you have configured the daemons and rebooted, run the following
-(or use xl) to inspect Xen's boot messages, available resources, and
-running domains:
+After you have configured the daemons and eitehr started them or
+rebooted, run the following (or use xl) to inspect Xen's boot
+messages, available resources, and running domains:
 
         xm dmesg
         xm info
@@ -657,7 +657,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.41 2014/12/26 13:04:31 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.42 2014/12/26 13:10:00 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

add notes about anita
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -r1.40 -r1.41
--- wikisrc/ports/xen/howto.mdwn	26 Dec 2014 13:00:23 -0000	1.40
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 13:04:31 -0000	1.41
@@ -337,6 +337,18 @@
         xm info
         xm list
 
+anita (for testing NetBSD)
+--------------------------
+
+With the setup so far, one should be able to run anita (see
+pkgsrc/sysutils/py-anita) to test NetBSD releases, by doing (as root,
+because anita must create a domU):
+
+        anita --vmm=xm test file:///usr/obj/i386/
+
+Alternatively, one can use --vmm=xl to use xl-based domU creation instead.
+TODO: check this.
+
 Xen-specific NetBSD issues
 --------------------------
 
@@ -645,7 +657,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.40 2014/12/26 13:00:23 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.41 2014/12/26 13:04:31 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

mention modules issues
mention GENERIC != XEN3_DOMU in terms of options
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.39
retrieving revision 1.40
diff -u -r1.39 -r1.40
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 16:13:59 -0000	1.39
+++ wikisrc/ports/xen/howto.mdwn	26 Dec 2014 13:00:23 -0000	1.40
@@ -337,6 +337,24 @@
         xm info
         xm list
 
+Xen-specific NetBSD issues
+--------------------------
+
+There are (at least) two additional things different about NetBSD as a
+dom0 kernel compared to hardware.
+
+One is that modules are not usable in DOM0 kernels, so one must
+compile in what's needed.  It's not really that modules cannot work,
+but that modules must be built for XEN3_DOM0 because some of the
+defines change and the normal module builds don't do this.  Basically,
+enabling Xen changes the kernel ABI, and the module build system
+doesn't cope with this.
+
+The other difference is that XEN3_DOM0 does not have exactly the same
+options as GENERIC.  While it is debatable whether or not this is a
+bug, users should be aware of this and can simply add missing config
+items if desired.
+
 Updating NetBSD in a dom0
 -------------------------
 
@@ -627,7 +645,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.39 2014/12/24 16:13:59 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.40 2014/12/26 13:00:23 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

give dd example for disk
explain where domU kernels come from
Members: 
	ports/xen/howto.mdwn:1.38->1.39 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -r1.38 -r1.39
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 16:07:32 -0000	1.38
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 16:13:59 -0000	1.39
@@ -411,7 +411,10 @@
 failed to work.  TODO: give working/notworking NetBSD versions for
 sparse vnd.  Note that the use of file/vnd for Xen is not really
 different than creating a file-backed virtual disk for some other
-purpose, except that xentools handles the vnconfig commands.
+purpose, except that xentools handles the vnconfig commands.  To
+create an empty 4G virtual disk, simply do
+
+        dd if=/dev/zero of=foo-xbd0 bs=1m count=4096
 
 With the lvm style, one creates logical devices.  They are then used
 similarly to vnds.
@@ -444,6 +447,22 @@
 just like updating physical disks, but without having to be there and
 without those pesky connectors.
 
+domU kernels
+------------
+
+On a physical computer, the BIOS reads sector 0, and a chain of boot
+loaders finds and loads a kernel.  Normally this comes from the root
+filesystem.  With Xen domUs, the process is totally different.  The
+normal path is for the domU kernel to be a file in the dom0's
+filesystem.  At the request of the dom0, Xen loads that kernel into a
+new domU instance and starts execution.  While domU kernels can be
+anyplace, reasonable places to store domU kernels on the dom0 are in /
+(so they are near the dom0 kernel), in /usr/pkg/etc/xen (near the
+config files), or in /u0/xen (where the vdisks are).
+
+See the VPS section near the end for discussion of alternate ways to
+obtain domU kernels.
+
 Config files
 ------------
 
@@ -608,7 +627,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.38 2014/12/24 16:07:32 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.39 2014/12/24 16:13:59 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

note that xm dmesg can use xl
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.37
retrieving revision 1.38
diff -u -r1.37 -r1.38
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 16:06:38 -0000	1.37
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 16:07:32 -0000	1.38
@@ -330,8 +330,8 @@
 TODO: Recommend for/against xen-watchdog.
 
 After you have configured the daemons and rebooted, run the following
-to inspect Xen's boot messages, available resources, and running
-domains:
+(or use xl) to inspect Xen's boot messages, available resources, and
+running domains:
 
         xm dmesg
         xm info
@@ -608,7 +608,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.37 2014/12/24 16:06:38 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.38 2014/12/24 16:07:32 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

Add suggestion to limit vcpu and pin for dom0, from jnemeth@.
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -r1.36 -r1.37
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 16:02:49 -0000	1.36
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 16:06:38 -0000	1.37
@@ -269,10 +269,16 @@
 
 See boot.cfg(5) for an example.  The basic line is
 
-"menu=Xen:load /netbsd-XEN3_DOM0.gz console=pc;multiboot /xen.gz dom0_mem=256M"
+        menu=Xen:load /netbsd-XEN3_DOM0.gz console=pc;multiboot /xen.gz dom0_mem=256M
 
 which specifies that the dom0 should have 256M, leaving the rest to be
-allocated for domUs.
+allocated for domUs.  In an attempt to add performance, one can also
+add
+
+        dom0_max_vcpus=1 dom0_vcpus_pin
+
+to force only one vcpu to be provided (since NetBSD dom0 can't use
+more) and to pin that vcpu to a physical cpu.  TODO: benchmark this.
 
 As with non-Xen systems, you should have a line to boot /netbsd (a
 kernel that works without Xen) and fallback versions of the non-Xen
@@ -602,7 +608,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.36 2014/12/24 16:02:49 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.37 2014/12/24 16:06:38 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

Add section on build problems.
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -r1.35 -r1.36
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:56:04 -0000	1.35
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 16:02:49 -0000	1.36
@@ -152,6 +152,24 @@
 xl, the NetBSD 6 stable branch, and to use an amd64 kernel as the
 dom0.  Either the i386 or amd64 of NetBSD may be used as domUs.
 
+Build problems
+--------------
+
+Ideally, all versions of Xen in pkgsrc would build on all versions of
+NetBSD on both i386 and amd64.  However, that isn't the case.  Besides
+aging code and aging compilers, qemu (included in xentools for HVM
+support) is difficult to build.  The following are known to fail:
+
+        xenkernel3 netbsd-6 i386
+        xentools42 netbsd-6 i386 
+
+The following are known to work:
+
+        xenkernel41 netbsd-5 amd64
+        xentools41 netbsd-5 amd64
+        xenkernel41 netbsd-6 i386
+        xentools41 netbsd-6 i386
+
 NetBSD as a dom0
 ================
 
@@ -584,7 +602,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.35 2014/12/24 15:56:04 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.36 2014/12/24 16:02:49 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

Detabify verbatim block.
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -r1.34 -r1.35
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:55:32 -0000	1.34
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:56:04 -0000	1.35
@@ -310,8 +310,8 @@
 domains:
 
         xm dmesg
-	xm info
-	xm list
+        xm info
+        xm list
 
 Updating NetBSD in a dom0
 -------------------------
@@ -584,7 +584,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.34 2014/12/24 15:55:32 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.35 2014/12/24 15:56:04 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

Add blank line before verbatim block.
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -r1.33 -r1.34
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:54:50 -0000	1.33
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:55:32 -0000	1.34
@@ -308,6 +308,7 @@
 After you have configured the daemons and rebooted, run the following
 to inspect Xen's boot messages, available resources, and running
 domains:
+
         xm dmesg
 	xm info
 	xm list
@@ -583,7 +584,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.33 2014/12/24 15:54:50 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.34 2014/12/24 15:55:32 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

Tweak which-daemons advice.
Fill out resources to domU section.
Explain virtual disks.
Explain virtual disks.

Members: 
	ports/xen/howto.mdwn:1.32->1.33 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -r1.32 -r1.33
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:31:36 -0000	1.32
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:54:50 -0000	1.33
@@ -285,20 +285,33 @@
         xend=YES
         xenbackendd=YES
 
-For 4.1 (and thus xm), add to rc.conf:
+For 4.1 (and thus xm; xl is believed not to work well), add to rc.conf:
 
         xend=YES
         xencommons=YES
 
 TODO: Explain why if xm is preferred on 4.1, rc.d/xendomains has xl.
+Or fix the package.
 
-For 4.2 with xl, add to rc.conf:
+For 4.2 with xm, add to rc.conf
+
+        xend=YES
+        xencommons=YES
+
+For 4.2 with xl (preferred), add to rc.conf:
 
         TODO: explain if there is a xend replacement
         xencommons=YES
 
 TODO: Recommend for/against xen-watchdog.
 
+After you have configured the daemons and rebooted, run the following
+to inspect Xen's boot messages, available resources, and running
+domains:
+        xm dmesg
+	xm info
+	xm list
+
 Updating NetBSD in a dom0
 -------------------------
 
@@ -332,19 +345,51 @@
 ===========================
 
 This section describes general concepts about domUs.  It does not
-address specific domU operating systems or how to install them.
-
-Provided Resources for PV domains
----------------------------------
-
-TODO: Explain that domUs get cpu, memory, disk and network.
-Explain that randomness can be an issue.
+address specific domU operating systems or how to install them.  The
+config files for domUs are typically in /usr/pkg/etc/xen, and are
+typically named so that the file anme, domU name and the domU's host
+name match.
+
+The domU is provided with cpu and memory by Xen, configured by the
+dom0.  The domU is provided with disk and network by the dom0,
+mediated by Xen, and configured in the dom0.
+
+Entropy in domUs can be an issue; physical disks and network are on
+the dom0.  NetBSD's /dev/random system works, but is often challenged.
+
+CPU and memory
+--------------
+
+A domain is provided with some number of vcpus, less than the
+number of cpus seen by the hypervisor.  For a dom0, this is controlled
+by the boot argument "dom0_max_vcpus=1".  For a domU, it is controlled
+from the config file.
+
+A domain is provided with memory, In the straightforward case, the sum
+of the the memory allocated to the dom0 and all domUs must be less
+than the available memory.
+
+Xen also provides a "balloon" driver, which can be used to let domains
+use more memory temporarily.  TODO: Explain better, and explain how
+well it works with NetBSD.
 
 Virtual disks
 -------------
 
-TODO: Explain how to set up files for vnd and that one should write all zeros to preallocate.
-TODO: Explain in what NetBSD versions sparse vnd files do and don't work.
+With the file/vnd style, typically one creates a directory,
+e.g. /u0/xen, on a disk large enough to hold virtual disks for all
+domUs.  Then, for each domU disk, one writes zeros to a file that then
+serves to hold the virtual disk's bits; a suggested name is foo-xbd0
+for the first virtual disk for the domU called foo.  Writing zeros to
+the file serves two purposes.  One is that preallocating the contents
+improves performance.  The other is that vnd on sparse files has
+failed to work.  TODO: give working/notworking NetBSD versions for
+sparse vnd.  Note that the use of file/vnd for Xen is not really
+different than creating a file-backed virtual disk for some other
+purpose, except that xentools handles the vnconfig commands.
+
+With the lvm style, one creates logical devices.  They are then used
+similarly to vnds.
 
 Virtual Networking
 ------------------
@@ -362,6 +407,18 @@
 One can construct arbitrary other configurations, but there is no
 script support.
 
+Sizing domains
+--------------
+
+Modern x86 hardware has vast amounts of resources.  However, many
+virtual servers can function just fine on far less.  A system with
+256M of RAM and a 4G disk can be a reasonable choice.  Note that it is
+far easier to adjust virtual resources than physical ones.  For
+memory, it's just a config file edit and a reboot.  For disk, one can
+create a new file and vnconfig it (or lvm), and then dump/restore,
+just like updating physical disks, but without having to be there and
+without those pesky connectors.
+
 Config files
 ------------
 
@@ -526,7 +583,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.32 2014/12/24 15:31:36 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.33 2014/12/24 15:54:50 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

fix spacing in verbatim
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -r1.31 -r1.32
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:30:45 -0000	1.31
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:31:36 -0000	1.32
@@ -282,8 +282,8 @@
 For 3.3 (and thus xm), add to rc.conf (but note that you should have
 installed 4.1 or 4.2):
 
-	xend=YES
-	xenbackendd=YES
+        xend=YES
+        xenbackendd=YES
 
 For 4.1 (and thus xm), add to rc.conf:
 
@@ -526,7 +526,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.31 2014/12/24 15:30:45 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.32 2014/12/24 15:31:36 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

attempt to fix formatting of rc.d examples.
Split by xen version, and sprinkle TODOs.
Members: 
	ports/xen/howto.mdwn:1.30->1.31 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.30
retrieving revision 1.31
diff -u -r1.30 -r1.31
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:21:41 -0000	1.30
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:30:45 -0000	1.31
@@ -271,20 +271,33 @@
 
 Now, you have a system that will boot Xen and the dom0 kernel, and
 just run the dom0 kernel.  There will be no domUs, and none can be
-started because you still have to configure the dom0 tools.
+started because you still have to configure the dom0 tools.  The
+daemons which should be run vary with Xen version and with whether one
+is using xm or xl.  Note that xend is for supporting "xm", and should
+only be used if you plan on using "xm".  Do NOT enable xend if you
+plan on using "xl" as it will cause problems.
 
-For 3.3 (and probably 3.1), add to rc.conf (but note that you should
-have installed 4.2):
-  xend=YES
-  xenbackendd=YES
-
-For 4.1 and 4.2, add to rc.conf:
-  xend=YES
-  xencommons=YES
-
-Note that xend is for supporting "xm", and should only be used if
-you plan on using "xm".  Do NOT enable xend if you plan on using
-"xl" as it will cause problems.
+TODO: Give 3.1 advice (or remove it from pkgsrc).
+
+For 3.3 (and thus xm), add to rc.conf (but note that you should have
+installed 4.1 or 4.2):
+
+	xend=YES
+	xenbackendd=YES
+
+For 4.1 (and thus xm), add to rc.conf:
+
+        xend=YES
+        xencommons=YES
+
+TODO: Explain why if xm is preferred on 4.1, rc.d/xendomains has xl.
+
+For 4.2 with xl, add to rc.conf:
+
+        TODO: explain if there is a xend replacement
+        xencommons=YES
+
+TODO: Recommend for/against xen-watchdog.
 
 Updating NetBSD in a dom0
 -------------------------
@@ -513,7 +526,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.30 2014/12/24 15:21:41 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.31 2014/12/24 15:30:45 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

clarify that amd64 dom0 is about NetBSD kernel
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -r1.29 -r1.30
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:17:25 -0000	1.29
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:21:41 -0000	1.30
@@ -149,8 +149,8 @@
 --------------
 
 Therefore, this HOWTO recommends running xenkernel42 (and xentools42),
-xl, the NetBSD 6 stable branch, and to use amd64 as the dom0.  Either
-the i386 or amd64 of NetBSD may be used as domUs.
+xl, the NetBSD 6 stable branch, and to use an amd64 kernel as the
+dom0.  Either the i386 or amd64 of NetBSD may be used as domUs.
 
 NetBSD as a dom0
 ================
@@ -513,7 +513,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.29 2014/12/24 15:17:25 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.30 2014/12/24 15:21:41 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

Strengthen hint to use amd64 hardware.
Move 4.2-last-i386 bit, and add TODO to clarify.
Note that 3.1 supports non-PAE on i386.
Suggest netbsd-7 for those wanting to learn vs run production systems.
Note that 3.1 supports non-PAE on i386.

Suggest netbsd-7 for those wanting to learn vs run production systems.

Members: 
	ports/xen/howto.mdwn:1.28->1.29 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -r1.28 -r1.29
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 14:35:23 -0000	1.28
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 15:17:25 -0000	1.29
@@ -27,11 +27,12 @@
 Attempts to access hardware registers are trapped and emulated.  This
 style is less efficient but can run unmodified guests.
 
-Generally any amd64 machine will work with Xen and PV guests.  For
-HVM guests, the VT or VMX cpu feature (Intel) or SVM/HVM/VT (amd64)
-is needed; "cpuctl identify 0" will show this.  Xen 4.2 is the last
-version for support for using i386 as a host.  TODO: Clean up and
-check the above features.
+Generally any amd64 machine will work with Xen and PV guests.  In
+theory i386 computers without amd64 support can be used for Xen <=
+4.2, but we have no recent reports of this working (this is a hint).
+For HVM guests, the VT or VMX cpu feature (Intel) or SVM/HVM/VT
+(amd64) is needed; "cpuctl identify 0" will show this.  TODO: Clean up
+and check the above features.
 
 At boot, the dom0 kernel is loaded as a module with Xen as the kernel.
 The dom0 can start one or more domUs.  (Booting is explained in detail
@@ -89,7 +90,7 @@
 
 xenkernel3 and xenkernel33 provide Xen 3.1 and 3.3.  These no longer
 receive security patches and should not be used.  Xen 3.1 supports PCI
-passthrough.
+passthrough.  Xen 3.1 supports non-PAE on i386.
 
 xenkernel41 provides Xen 4.1.  This is no longer maintained by Xen,
 but as of 2014-12 receives backported security patches.  It is a
@@ -117,7 +118,9 @@
 The netbsd-5, netbsd-6, netbsd-7, and -current branches are all
 reasonable choices, with more or less the same considerations for
 non-Xen use.  Therefore, netbsd-6 is recommended as the stable version
-of the most recent release.
+of the most recent release for production use.  For those wanting to
+learn Xen or without production stability concerns, netbsd-7 is likely
+most appropriate.
 
 As of NetBSD 6, a NetBSD domU will support multiple vcpus.  There is
 no SMP support for NetBSD as dom0.  (The dom0 itself doesn't really
@@ -127,13 +130,20 @@
 Architecture
 ------------
 
-Xen is basically amd64 only at this point.  One can either run i386
-domains or amd64 domains.  If running i386, PAE versions are required,
-for both dom0 and domU.  These versions are built by default in NetBSD
-releases.  While i386 dom0 works fine, amd64 is recommended as more
-normal.  (Note that emacs (at least) fails if run on i386 with PAE when
-built without, and vice versa, presumably due to bugs in the undump
-code.)
+Xen itself can run on i386 or amd64 machines.  (Practically, almost
+any computer where one would want to run Xen supports amd64.)  If
+using an i386 NetBSD kernel for the dom0, PAE is required (PAE
+versions are built by default).  While i386 dom0 works fine, amd64 is
+recommended as more normal.
+
+Xen 4.2 is the last version to support i386 as a host.  TODO: Clarify
+if this is about the CPU having to be amd64, or about the dom0 kernel
+having to be amd64.
+
+One can then run i386 domUs and amd64 domUs, in any combination.  If
+running an i386 NetBSD kernel as a domU, the PAE version is required.
+(Note that emacs (at least) fails if run on i386 with PAE when built
+without, and vice versa, presumably due to bugs in the undump code.)
 
 Recommendation
 --------------
@@ -503,7 +513,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.28 2014/12/24 14:35:23 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.29 2014/12/24 15:17:25 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

Add skeleton for generic domU section.
Add section about VPS domU, where you don't control dom0.
Merge link section.
Merge link section.

Members: 
	ports/xen/howto.mdwn:1.27->1.28 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -r1.27 -r1.28
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 08:32:49 -0000	1.27
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 14:35:23 -0000	1.28
@@ -250,6 +250,12 @@
 kernel that works without Xen) and fallback versions of the non-Xen
 kernel, Xen, and the dom0 kernel.
 
+The [HowTo on Installing into
+RAID-1](http://mail-index.NetBSD.org/port-xen/2006/03/01/0010.html)
+explains how to set up booting a dom0 with Xen using grub with
+NetBSD's RAIDframe.  (This is obsolete with the use of NetBSD's native
+boot.)
+
 Configuring Xen
 ---------------
 
@@ -298,8 +304,58 @@
 correct set of daemons.  Ensure that the domU config files are valid
 for the new version.
 
-Creating unprivileged domains (domU)
-====================================
+
+Unprivileged domains (domU)
+===========================
+
+This section describes general concepts about domUs.  It does not
+address specific domU operating systems or how to install them.
+
+Provided Resources for PV domains
+---------------------------------
+
+TODO: Explain that domUs get cpu, memory, disk and network.
+Explain that randomness can be an issue.
+
+Virtual disks
+-------------
+
+TODO: Explain how to set up files for vnd and that one should write all zeros to preallocate.
+TODO: Explain in what NetBSD versions sparse vnd files do and don't work.
+
+Virtual Networking
+------------------
+
+TODO: explain xvif concept, and that it's general.
+
+There are two normal styles: bridging and NAT.
+
+With bridging, the domU perceives itself to be on the same network as
+the dom0.  For server virtualization, this is usually best.
+
+With NAT, the domU perceives itself to be behind a NAT running on the
+dom0.  This is often appropriate when running Xen on a workstation.
+
+One can construct arbitrary other configurations, but there is no
+script support.
+
+Config files
+------------
+
+TODO: give example config files.   Use both lvm and vnd.
+
+TODO: explain the mess with 3 arguments for disks and how to cope (0x1).
+
+Starting domains
+----------------
+
+TODO: Explain "xm start" and "xl start".  Explain rc.d/xendomains.
+
+TODO: Explain why 4.1 rc.d/xendomains has xl, when one should use xm
+on 4.1.
+
+Creating specific unprivileged domains (domU)
+=============================================
 
 Creating domUs is almost entirely independent of operating system.  We
 first explain NetBSD, and then differences for Linux and Solaris.
@@ -447,7 +503,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.27 2014/12/24 08:32:49 jnemeth Exp $
+    # $NetBSD: howto.mdwn,v 1.28 2014/12/24 14:35:23 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #
@@ -824,13 +880,16 @@
     sd*     at scsibus? target ? lun ?      # SCSI disk drives
     cd*     at scsibus? target ? lun ?      # SCSI CD-ROM drives
 
-Links and further information
-=============================
 
--   The [HowTo on Installing into RAID-1](http://mail-index.NetBSD.org/port-xen/2006/03/01/0010.html)
-    explains how to set up booting a dom0 with Xen using grub 
-    with NetBSD's RAIDframe.  (This is obsolete with the use of
-    NetBSD's native boot.)
--   An example of how to use NetBSD's native bootloader to load
-    NetBSD/Xen instead of Grub can be found in the i386/amd64 boot(8)
-    and boot.cfg(5) manpages.
+NetBSD as a domU in a VPS
+=========================
+
+The bulk of the HOWTO is about using NetBSD as a dom0 on your own
+hardware.  This section explains how to deal with Xen in a domU as a
+virtual private server where you do not control or have access to the
+dom0.
+
+TODO: Perhaps reference panix, prmgr, amazon as interesting examples.
+
+TODO: Somewhere, discuss pvgrub and py-grub to load the domU kernel
+from the domU filesystem.

Added a comment: Links need the hostname corrected.
--- /dev/null	2014-12-24 10:00:00.000000000 +0000
+++ wikisrc/ports/sparc64/comment_1_8e627205f2a9e9ad382fb255a1ae9113._comment	2014-12-24 10:08:27.000000000 +0000
@@ -0,0 +1,22 @@
+[[!comment format=mdwn
+ username="https://me.yahoo.com/a/IZ9XO3Ax1NDlkznVSToDf1sLgfiB1eOm#332d2"
+ nickname="Gareth"
+ subject="Links need the hostname corrected."
+ date="2014-12-24T10:08:18Z"
+ content="""
+Some of the links in the \"Additional Info\" section refer to wiki.netbsd.org, whereas they should refer to www.netbsd.org.
+
+For example:
+/ports/sparc64/faq.html
+is a broken link.
+
+But changing wiki to www works:
+http://www.netbsd.org/ports/sparc64/faq.html
+
+
+Links I've noticed that need correcting include:
+NetBSD/sparc64 FAQ
+Notes on System Models
+NetBSD/sparc64 History
+
+"""]]

- mention that Xen 4.2 is the last version to support i386 as a host
- grammar, spelling
- xen.org -> xenproject.org
- fix links
- note that installation concepts are independent of both Xen version
and NetBSD version
- correct last version for xm
- add link to the Guide page for LVM
- note that the xend rc.d script should only be used when using xm
- make manpage references look nicer
- these should be fixed up to be links like they were in htdocs
XXX The example domU configs still need work.
Members: 
	ports/xen/howto.mdwn:1.26->1.27 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -r1.26 -r1.27
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:38:26 -0000	1.26
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 08:32:49 -0000	1.27
@@ -27,14 +27,13 @@
 Attempts to access hardware registers are trapped and emulated.  This
 style is less efficient but can run unmodified guests.
 
-Generally any amd64 machine will work with Xen and PV guests.  For HVM
-guests, the VT or VMX cpu feature (Intel) or SVM/HVM/VT (amd64) is
-needed; "cpuctl identify 0" will show this.  TODO: Clean up and check
-the above features.  TODO: Explain if i386 (non-amd64) machines can
-still be used --- I think that the requirement to use PAE kernels is
-about the hypervisor being amd64 only.
+Generally any amd64 machine will work with Xen and PV guests.  For
+HVM guests, the VT or VMX cpu feature (Intel) or SVM/HVM/VT (amd64)
+is needed; "cpuctl identify 0" will show this.  Xen 4.2 is the last
+version for support for using i386 as a host.  TODO: Clean up and
+check the above features.
 
-At boot, the dom0 kernel is loaded as module with Xen as the kernel.
+At boot, the dom0 kernel is loaded as a module with Xen as the kernel.
 The dom0 can start one or more domUs.  (Booting is explained in detail
 in the dom0 section.)
 
@@ -61,7 +60,7 @@
 This HOWTO presumes a basic familiarity with the Xen system
 architecture.  This HOWTO presumes familiarity with installing NetBSD
 on i386/amd64 hardware and installing software from pkgsrc.
-See also the [Xen website](http://www.xen.org/).
+See also the [Xen website](http://www.xenproject.org/).
 
 History
 -------
@@ -70,15 +69,15 @@
 
 Before NetBSD's native bootloader could support Xen, the use of
 grub was recommended.  If necessary, see the
-[old grub information](/xen/howto-grub/).
+[old grub information](/ports/xen/howto-grub/).
 
 Versions of Xen and NetBSD
 ==========================
 
-Most of the installation concepts and instructions are independent of
-Xen version.  This section gives advice on which version to choose.
-Versions not in pkgsrc and older unsupported versions of NetBSD are
-intentionally ignored.
+Most of the installation concepts and instructions are independent
+of Xen version and NetBSD version.  This section gives advice on
+which version to choose.  Versions not in pkgsrc and older unsupported
+versions of NetBSD are intentionally ignored.
 
 Xen
 ---
@@ -109,7 +108,8 @@
 
 Early Xen used a program called "xm" to manipulate the system from the
 dom0.  Starting in 4.1, a replacement program with similar behavior
-called "xl" is provided.  In 4.2, "xm" is no longer available.
+called "xl" is provided.  In 4.2 and later, "xl" is preferred.  4.4 is
+the last version that has "xm".
 
 NetBSD
 ------
@@ -178,7 +178,7 @@
 ----------------------
 
 First,
-[install NetBSD/amd64](../../docs/guide/en/chap-inst.html)
+[install NetBSD/amd64](/guide/inst/)
 just as you would if you were not using Xen.
 However, the partitioning approach is very important.
 
@@ -196,9 +196,10 @@
 how domU usage will evolve, please add an explanation to the HOWTO.
 Seriously, needs tend to change over time.)
 
-One can use lvm(8) to create logical devices to use for domU disks.
-This is almost as efficient sa raw disk partitions and more flexible.
-Hence raw disk partitions should typically not be used.
+One can use [lvm(8)](/guide/lvm/) to create logical devices to use
+for domU disks.  This is almost as efficient as raw disk partitions
+and more flexible.  Hence raw disk partitions should typically not
+be used.
 
 One can use files in the dom0 filesystem, typically created by dd'ing
 /dev/zero to create a specific size.  This is somewhat less efficient,
@@ -265,6 +266,10 @@
   xend=YES
   xencommons=YES
 
+Note that xend is for supporting "xm", and should only be used if
+you plan on using "xm".  Do NOT enable xend if you plan on using
+"xl" as it will cause problems.
+
 Updating NetBSD in a dom0
 -------------------------
 
@@ -325,7 +330,7 @@
 will be executed in the new domain (this kernel is in the *domain0* file
 system, not on the new domain virtual disk; but please note, you should
 install the same kernel into *domainU* as `/netbsd` in order to make
-your system tools, like MAN.SAVECORE.8, work). A suitable kernel is
+your system tools, like savecore(8), work). A suitable kernel is
 provided as part of the i386 and amd64 binary sets: XEN3\_DOMU.
 
 Here is an /usr/pkg/etc/xen/nbsd example config file:
@@ -435,14 +440,14 @@
     !brconfig $int add ex0 up
 
 (replace `ex0` with the name of your physical interface). Then bridge0
-will be created on boot. See the MAN.BRIDGE.4 man page for details.
+will be created on boot. See the bridge(4) man page for details.
 
 So, here is a suitable `/usr/pkg/etc/xen/vif-bridge` for xvif?.? (a
 working vif-bridge is also provided with xentools20) configuring:
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.26 2014/12/24 01:38:26 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.27 2014/12/24 08:32:49 jnemeth Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

- mention ARM
- Xen website has moved to http://www.xenproject.org/
Index: wikisrc/ports/xen.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen.mdwn,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- wikisrc/ports/xen.mdwn	23 Dec 2014 23:23:47 -0000	1.12
+++ wikisrc/ports/xen.mdwn	24 Dec 2014 05:35:43 -0000	1.13
@@ -8,7 +8,8 @@
 NetBSD/xen is a port of NetBSD to the Xen virtual machine monitor. It was
 first brought to NetBSD by Christian Limpach and committed to the source tree
 on March 11th, 2004.  It is not quite a port in its own right, but an
-extension to the i386 and amd64 ports.
+extension to the i386 and amd64 ports.  Current versions of Xen also support
+ARM, but NetBSD has no support for that as of yet.
 
 Xen is a virtual machine monitor for x86 that supports execution of multiple
 guest operating systems with unprecedented levels of performance and resource
@@ -16,7 +17,8 @@
 
 For instructions on how to install Xen with NetBSD, see the [[Xen Howto|/ports/xen/howto]].
 
-See [http://www.xen.org/](http://www.xen.org/) for more details on Xen.
+See [http://www.xenproject.org/](http://www.xenproject.org/) for
+more details on Xen.
 
 The current maintainer of NetBSD/xen is Manuel Bouyer.
 

whitespace
Index: wikisrc/ports/amd64.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/amd64.mdwn,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- wikisrc/ports/amd64.mdwn	6 Oct 2014 21:41:28 -0000	1.11
+++ wikisrc/ports/amd64.mdwn	24 Dec 2014 05:28:50 -0000	1.12
@@ -15,7 +15,7 @@
 <a href="http://netbsd.gw.com/cgi-bin/man-cgi?compat_netbsd32+8+NetBSD-5.1+i386">compat_netbsd32(8)</a>.
 
 The port was first committed to the NetBSD source tree as NetBSD/x86_64
-on June 19th, 2001 and  renamed to NetBSD/amd64 on April 26th, 2003.
+on June 19th, 2001 and renamed to NetBSD/amd64 on April 26th, 2003.
 
 The original work to do this port was done by Frank van der Linden at
 <a class="ulink" href="http://www.wasabisystems.com/" target="_top">Wasabi Systems</a>, assisted by

Index: wikisrc/ports/mac68k.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/mac68k.mdwn,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- wikisrc/ports/mac68k.mdwn	6 Oct 2014 21:41:29 -0000	1.8
+++ wikisrc/ports/mac68k.mdwn	24 Dec 2014 05:06:10 -0000	1.9
@@ -66,9 +66,7 @@
 supported](http://www.macbsd.org/macbsd/LC040-and-BSD.html).
 """
 additional="""
-* [NetBSD/mac68k FAQ](http://www.NetBSD.org/ports/mac68k/faq/)
 * [NetBSD/mac68k Meta-FAQ](http://www.NetBSD.org/ports/mac68k/meta-faq.html)
-* [NetBSD/mac68k Info Sheet](http://www.NetBSD.org/ports/mac68k/info/)
 * [BSD/mac68k Booter Manual](http://www.NetBSD.org/ports/mac68k/booter-manual/)
 * [NetBSD/mac68k Supported hardware](http://www.NetBSD.org/ports/mac68k/hardware.html)
 * [History of NetBSD/mac68k](http://www.NetBSD.org/ports/mac68k/history.html)

grammar nit
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -r1.25 -r1.26
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:37:30 -0000	1.25
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:38:26 -0000	1.26
@@ -101,8 +101,8 @@
 
 Ideally newer versions of Xen will be added to pkgsrc.
 
-Note that NetBSD support is called XEN3; it works with 3.1 through
-4.2, because the hypercall interface has been stable.
+Note that NetBSD support is called XEN3.  It works with 3.1 through
+4.2 because the hypercall interface has been stable.
 
 Xen command program
 -------------------
@@ -442,7 +442,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.25 2014/12/24 01:37:30 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.26 2014/12/24 01:38:26 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

speling
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -r1.24 -r1.25
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:35:40 -0000	1.24
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:37:30 -0000	1.25
@@ -78,7 +78,7 @@
 Most of the installation concepts and instructions are independent of
 Xen version.  This section gives advice on which version to choose.
 Versions not in pkgsrc and older unsupported versions of NetBSD are
-inentionally ignored.
+intentionally ignored.
 
 Xen
 ---
@@ -442,7 +442,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.24 2014/12/24 01:35:40 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.25 2014/12/24 01:37:30 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

clarify dom0/domU scope vs VPS
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:34:47 -0000	1.23
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:35:40 -0000	1.24
@@ -41,7 +41,8 @@
 NetBSD supports Xen in that it can serve as dom0, be used as a domU,
 and that Xen kernels and tools are available in pkgsrc.  This HOWTO
 attempts to address both the case of running a NetBSD dom0 on hardware
-and running NetBSD as a domU in a VPS.
+and running domUs under it (NetBSD and other), and also running NetBSD
+as a domU in a VPS.
 
 Some versions of Xen support "PCI passthrough", which means that
 specific PCI devices can be made available to a specific domU instead
@@ -441,7 +442,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.23 2014/12/24 01:34:47 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.24 2014/12/24 01:35:40 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

typos
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -r1.22 -r1.23
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:27:36 -0000	1.22
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:34:47 -0000	1.23
@@ -31,7 +31,7 @@
 guests, the VT or VMX cpu feature (Intel) or SVM/HVM/VT (amd64) is
 needed; "cpuctl identify 0" will show this.  TODO: Clean up and check
 the above features.  TODO: Explain if i386 (non-amd64) machines can
-still be used - I think that witthe requirement to use PAE kernels is
+still be used --- I think that the requirement to use PAE kernels is
 about the hypervisor being amd64 only.
 
 At boot, the dom0 kernel is loaded as module with Xen as the kernel.
@@ -441,7 +441,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.22 2014/12/24 01:27:36 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.23 2014/12/24 01:34:47 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

Clarify RAID1 booting.
Explain how to convert from grub to /boot.
Members: 
	ports/xen/howto.mdwn:1.21->1.22 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -r1.21 -r1.22
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:12:49 -0000	1.21
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:27:36 -0000	1.22
@@ -183,7 +183,9 @@
 
 If you want to use RAIDframe for the dom0, there are no special issues
 for Xen.  Typically one provides RAID storage for the dom0, and the
-domU systems are unaware of RAID.
+domU systems are unaware of RAID.  The 2nd-stage loader bootxx_* skips
+over a RAID1 header to find /boot from a filesystem within a RAID
+partition; this is no different when booting Xen.
 
 There are 4 styles of providing backing storage for the virtual disks
 used by domUs: raw partitions, LVM, file-backed vnd(4), and SAN,
@@ -273,6 +275,11 @@
 Note that one must update both the non-Xen kernel typically used for
 rescue purposes and the DOM0 kernel used with Xen.
 
+To convert from grub to /boot, install an mbr bootblock with fdisk,
+bootxx_ with installboot, /boot and /boot.cfg.  This really should be
+no different than completely reinstalling boot blocks on a non-Xen
+system.
+
 Updating Xen versions
 ---------------------
 
@@ -434,7 +441,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.21 2014/12/24 01:12:49 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.22 2014/12/24 01:27:36 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

rc.conf for 3.3, 4.1 and 4.2
Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:06:43 -0000	1.20
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:12:49 -0000	1.21
@@ -246,6 +246,22 @@
 kernel that works without Xen) and fallback versions of the non-Xen
 kernel, Xen, and the dom0 kernel.
 
+Configuring Xen
+---------------
+
+Now, you have a system that will boot Xen and the dom0 kernel, and
+just run the dom0 kernel.  There will be no domUs, and none can be
+started because you still have to configure the dom0 tools.
+
+For 3.3 (and probably 3.1), add to rc.conf (but note that you should
+have installed 4.2):
+  xend=YES
+  xenbackendd=YES
+
+For 4.1 and 4.2, add to rc.conf:
+  xend=YES
+  xencommons=YES
+
 Updating NetBSD in a dom0
 -------------------------
 
@@ -260,7 +276,14 @@
 Updating Xen versions
 ---------------------
 
-TODO: write
+Updating Xen is conceptually not difficult, but can run into all the
+issues found when installing Xen.  Assuming migration from 4.1 to 4.2,
+remove the xenkernel41 and xentools41 packages and install the
+xenkernel42 and xentools42 packages.  Copy the 4.2 xen.gz to /.
+
+Ensure that the contents of /etc/rc.d/xen* are correct.  Enable the
+correct set of daemons.  Ensure that the domU config files are valid
+for the new version.
 
 Creating unprivileged domains (domU)
 ====================================
@@ -411,7 +434,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.20 2014/12/24 01:06:43 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.21 2014/12/24 01:12:49 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

Trim installation.
Don't open-code "install amd64" or pkgsrc.
Demote grub text to howto-grub.
Explain PCI passthrough early on.
Recommend only /boot (but grub has a pointer in the history section).
Demote grub text to howto-grub.

Explain PCI passthrough early on.

Recommend only /boot (but grub has a pointer in the history section).

Members: 
	ports/xen/howto.mdwn:1.19->1.20 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -r1.19 -r1.20
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 00:41:04 -0000	1.19
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 01:06:43 -0000	1.20
@@ -28,10 +28,11 @@
 style is less efficient but can run unmodified guests.
 
 Generally any amd64 machine will work with Xen and PV guests.  For HVM
-guests, the VMX cpu feature (Intel) or VT?? (amd64) is needed.  TODO:
-Explain if i386 (non-amd64) machines can still be used - I think that
-witthe requirement to use PAE kernels is about the hypervisor being
-amd64 only.
+guests, the VT or VMX cpu feature (Intel) or SVM/HVM/VT (amd64) is
+needed; "cpuctl identify 0" will show this.  TODO: Clean up and check
+the above features.  TODO: Explain if i386 (non-amd64) machines can
+still be used - I think that witthe requirement to use PAE kernels is
+about the hypervisor being amd64 only.
 
 At boot, the dom0 kernel is loaded as module with Xen as the kernel.
 The dom0 can start one or more domUs.  (Booting is explained in detail
@@ -42,6 +43,11 @@
 attempts to address both the case of running a NetBSD dom0 on hardware
 and running NetBSD as a domU in a VPS.
 
+Some versions of Xen support "PCI passthrough", which means that
+specific PCI devices can be made available to a specific domU instead
+of the dom0.  This can be useful to let a domU run X11, or access some
+network interface or other peripheral.
+
 Prerequisites
 -------------
 
@@ -82,7 +88,8 @@
 matching versions.
 
 xenkernel3 and xenkernel33 provide Xen 3.1 and 3.3.  These no longer
-receive security patches and should not be used.
+receive security patches and should not be used.  Xen 3.1 supports PCI
+passthrough.
 
 xenkernel41 provides Xen 4.1.  This is no longer maintained by Xen,
 but as of 2014-12 receives backported security patches.  It is a
@@ -93,6 +100,9 @@
 
 Ideally newer versions of Xen will be added to pkgsrc.
 
+Note that NetBSD support is called XEN3; it works with 3.1 through
+4.2, because the hypercall interface has been stable.
+
 Xen command program
 -------------------
 
@@ -199,144 +209,42 @@
 Installation of Xen
 -------------------
 
-Next step is to install the Xen packages via pkgsrc or from binary
-packages. See [the pkgsrc
-documentation](http://www.NetBSD.org/docs/pkgsrc/) if you are unfamiliar
-with pkgsrc and/or handling of binary packages. Xen 3.1, 3.3, 4.1 and
-4.2 are available. 3.1 supports PCI pass-through while other versions do
-not. You'll need either `sysutils/xentools3` and `sysutils/xenkernel3`
-for Xen 3.1, `sysutils/xentools33` and `sysutils/xenkernel33` for Xen
-3.3, `sysutils/xentools41` and `sysutils/xenkernel41` for Xen 4.1. or
-`sysutils/xentools42` and `sysutils/xenkernel42` for Xen 4.2. You'll
-also need `sysutils/grub` if you plan do use the grub boot loader. If
-using Xen 3.1, you may also want to install `sysutils/xentools3-hvm`
-which contains the utilities to run unmodified guests OSes using the
-*HVM* support (for later versions this is included in
-`sysutils/xentools`). Note that your CPU needs to support this. Intel
-CPUs must have the 'VT' instruction, AMD CPUs the 'SVM' instruction. You
-can easily find out if your CPU support HVM by using NetBSD's cpuctl
-command:
-
-    # cpuctl identify 0
-    cpu0: Intel Core 2 (Merom) (686-class), id 0x6f6
-    cpu0: features 0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR>
-    cpu0: features 0xbfebfbff<PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX>
-    cpu0: features 0xbfebfbff<FXSR,SSE,SSE2,SS,HTT,TM,SBF>
-    cpu0: features2 0x4e33d<SSE3,DTES64,MONITOR,DS-CPL,,TM2,SSSE3,CX16,xTPR,PDCM,DCA>
-    cpu0: features3 0x20100800<SYSCALL/SYSRET,XD,EM64T>
-    cpu0: "Intel(R) Xeon(R) CPU            5130  @ 2.00GHz"
-    cpu0: I-cache 32KB 64B/line 8-way, D-cache 32KB 64B/line 8-way
-    cpu0: L2 cache 4MB 64B/line 16-way
-    cpu0: ITLB 128 4KB entries 4-way
-    cpu0: DTLB 256 4KB entries 4-way, 32 4MB entries 4-way
-    cpu0: Initial APIC ID 0
-    cpu0: Cluster/Package ID 0
-    cpu0: Core ID 0
-    cpu0: family 06 model 0f extfamily 00 extmodel 00
-
-Depending on your CPU, the feature you are looking for is called HVM,
-SVM or VMX.
-
-Next you need to copy the selected Xen kernel itself. pkgsrc installed
-them under `/usr/pkg/xen*-kernel/`. The file you're looking for is
-`xen.gz`. Copy it to your root file system. `xen-debug.gz` is a kernel
-with more consistency checks and more details printed on the serial
-console. It is useful for debugging crashing guests if you use a serial
-console. It is not useful with a VGA console.
-
-You'll then need a NetBSD/Xen kernel for *domain0* on your root file
-system. The XEN3PAE\_DOM0 kernel or XEN3\_DOM0 provided as part of the
-i386 or amd64 binaries is suitable for this, but you may want to
-customize it. Keep your native kernel around, as it can be useful for
-recovery. *Note:* the *domain0* kernel must support KERNFS and `/kern`
-must be mounted because *xend* needs access to `/kern/xen/privcmd`.
-
-Next you need to get a bootloader to load the `xen.gz` kernel, and the
-NetBSD *domain0* kernel as a module. This can be `grub` or NetBSD's boot
-loader. Below is a detailled example for grub, see the boot.cfg(5)
-manual page for an example using the latter.
-
-This is also where you'll specify the memory allocated to *domain0*, the
-console to use, etc ...
-
-Here is a commented `/grub/menu.lst` file:
-
-    #Grub config file for NetBSD/xen. Copy as /grub/menu.lst and run
-    # grub-install /dev/rwd0d (assuming your boot device is wd0).
-    #
-    # The default entry to load will be the first one
-    default=0
-
-    # boot the default entry after 10s if the user didn't hit keyboard
-    timeout=10
-
-    # Configure serial port to use as console. Ignore if you'll use VGA only
-    serial --unit=0 --speed=115200 --word=8 --parity=no --stop=1
-
-    # Let the user select which console to use (serial or VGA), default
-    # to serial after 10s
-    terminal --timeout=10 serial console
-
-    # An entry for NetBSD/xen, using /netbsd as the domain0 kernel, and serial
-    # console. Domain0 will have 64MB RAM allocated.
-    # Assume NetBSD is installed in the first MBR partition.
-    title Xen 3 / NetBSD (hda0, serial)
-      root(hd0,0)
-      kernel (hd0,a)/xen.gz dom0_mem=65536 com1=115200,8n1
-      module (hd0,a)/netbsd bootdev=wd0a ro console=ttyS0
-
-    # Same as above, but using VGA console
-    # We can use console=tty0 (Linux syntax) or console=pc (NetBSD syntax)
-    title Xen 3 / NetBSD (hda0, vga)
-      root(hd0,0)
-      kernel (hd0,a)/xen.gz dom0_mem=65536
-      module (hd0,a)/netbsd bootdev=wd0a ro console=tty0
-
-    # NetBSD/xen using a backup domain0 kernel (in case you installed a
-    # nonworking kernel as /netbsd
-    title Xen 3 / NetBSD (hda0, backup, serial)
-      root(hd0,0)
-      kernel (hd0,a)/xen.gz dom0_mem=65536 com1=115200,8n1
-      module (hd0,a)/netbsd.backup bootdev=wd0a ro console=ttyS0
-    title Xen 3 / NetBSD (hda0, backup, VGA)
-      root(hd0,0)
-      kernel (hd0,a)/xen.gz dom0_mem=65536
-      module (hd0,a)/netbsd.backup bootdev=wd0a ro console=tty0
-
-    #Load a regular NetBSD/i386 kernel. Can be useful if you end up with a
-    #nonworking /xen.gz
-    title NetBSD 5.1
-      root (hd0,a)
-      kernel --type=netbsd /netbsd-GENERIC
-
-    #Load the NetBSD bootloader, letting it load the NetBSD/i386 kernel.
-    #May be better than the above, as grub can't pass all required infos
-    #to the NetBSD/i386 kernel (e.g. console, root device, ...)
-    title NetBSD chain
-      root        (hd0,0)
-      chainloader +1
-
-    ## end of grub config file.
-          
-
-Install grub with the following command:
-
-    # grub --no-floppy
-
-    grub> root (hd0,a)
-     Filesystem type is ffs, partition type 0xa9
-
-    grub> setup (hd0)
-     Checking if "/boot/grub/stage1" exists... no
-     Checking if "/grub/stage1" exists... yes
-     Checking if "/grub/stage2" exists... yes

(Diff truncated)
park more grub text
Index: wikisrc/ports/xen/howto-grub.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto-grub.mdwn,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- wikisrc/ports/xen/howto-grub.mdwn	24 Dec 2014 00:34:40 -0000	1.1
+++ wikisrc/ports/xen/howto-grub.mdwn	24 Dec 2014 01:05:19 -0000	1.2
@@ -2,8 +2,9 @@
 ================
 
 Now, the use of NetBSD's normal boot code is recommended.  This file
-exists to save stray text about grub.
-
+exists to save stray text about grub.  Note that it is far far easier
+to use the native boot code, and that you probably should not be
+reading this.
 
 Install
 -------
@@ -13,3 +14,85 @@
 as FFSv1 with 8k block/1k fragments. If the partition is larger than
 this, uses FFSv2 or has different block/fragment sizes, grub may fail
 to load some files.
+
+You'll also need `sysutils/grub` from pkgsrc.
+
+Grub config
+-----------
+
+
+    #Grub config file for NetBSD/xen. Copy as /grub/menu.lst and run
+    # grub-install /dev/rwd0d (assuming your boot device is wd0).
+    #
+    # The default entry to load will be the first one
+    default=0
+
+    # boot the default entry after 10s if the user didn't hit keyboard
+    timeout=10
+
+    # Configure serial port to use as console. Ignore if you'll use VGA only
+    serial --unit=0 --speed=115200 --word=8 --parity=no --stop=1
+
+    # Let the user select which console to use (serial or VGA), default
+    # to serial after 10s
+    terminal --timeout=10 serial console
+
+    # An entry for NetBSD/xen, using /netbsd as the domain0 kernel, and serial
+    # console. Domain0 will have 64MB RAM allocated.
+    # Assume NetBSD is installed in the first MBR partition.
+    title Xen 3 / NetBSD (hda0, serial)
+      root(hd0,0)
+      kernel (hd0,a)/xen.gz dom0_mem=65536 com1=115200,8n1
+      module (hd0,a)/netbsd bootdev=wd0a ro console=ttyS0
+
+    # Same as above, but using VGA console
+    # We can use console=tty0 (Linux syntax) or console=pc (NetBSD syntax)
+    title Xen 3 / NetBSD (hda0, vga)
+      root(hd0,0)
+      kernel (hd0,a)/xen.gz dom0_mem=65536
+      module (hd0,a)/netbsd bootdev=wd0a ro console=tty0
+
+    # NetBSD/xen using a backup domain0 kernel (in case you installed a
+    # nonworking kernel as /netbsd
+    title Xen 3 / NetBSD (hda0, backup, serial)
+      root(hd0,0)
+      kernel (hd0,a)/xen.gz dom0_mem=65536 com1=115200,8n1
+      module (hd0,a)/netbsd.backup bootdev=wd0a ro console=ttyS0
+    title Xen 3 / NetBSD (hda0, backup, VGA)
+      root(hd0,0)
+      kernel (hd0,a)/xen.gz dom0_mem=65536
+      module (hd0,a)/netbsd.backup bootdev=wd0a ro console=tty0
+
+    #Load a regular NetBSD/i386 kernel. Can be useful if you end up with a
+    #nonworking /xen.gz
+    title NetBSD 5.1
+      root (hd0,a)
+      kernel --type=netbsd /netbsd-GENERIC
+
+    #Load the NetBSD bootloader, letting it load the NetBSD/i386 kernel.
+    #May be better than the above, as grub can't pass all required infos
+    #to the NetBSD/i386 kernel (e.g. console, root device, ...)
+    title NetBSD chain
+      root        (hd0,0)
+      chainloader +1
+
+    ## end of grub config file.
+          
+
+Install grub with the following command:
+
+    # grub --no-floppy
+
+    grub> root (hd0,a)
+     Filesystem type is ffs, partition type 0xa9
+
+    grub> setup (hd0)
+     Checking if "/boot/grub/stage1" exists... no
+     Checking if "/grub/stage1" exists... yes
+     Checking if "/grub/stage2" exists... yes
+     Checking if "/grub/ffs_stage1_5" exists... yes
+     Running "embed /grub/ffs_stage1_5 (hd0)"...  14 sectors are embedded.
+    succeeded
+     Running "install /grub/stage1 (hd0) (hd0)1+14 p (hd0,0,a)/grub/stage2 /grub/menu.lst"...
+     succeeded
+    Done.

explain history.
explain xm/xl
redo installation
redo installation

Members: 
	ports/xen/howto.mdwn:1.18->1.19 

Index: wikisrc/ports/xen/howto.mdwn
===================================================================
RCS file: /cvsroot/wikisrc/ports/xen/howto.mdwn,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- wikisrc/ports/xen/howto.mdwn	24 Dec 2014 00:11:15 -0000	1.18
+++ wikisrc/ports/xen/howto.mdwn	24 Dec 2014 00:41:04 -0000	1.19
@@ -27,6 +27,12 @@
 Attempts to access hardware registers are trapped and emulated.  This
 style is less efficient but can run unmodified guests.
 
+Generally any amd64 machine will work with Xen and PV guests.  For HVM
+guests, the VMX cpu feature (Intel) or VT?? (amd64) is needed.  TODO:
+Explain if i386 (non-amd64) machines can still be used - I think that
+witthe requirement to use PAE kernels is about the hypervisor being
+amd64 only.
+
 At boot, the dom0 kernel is loaded as module with Xen as the kernel.
 The dom0 can start one or more domUs.  (Booting is explained in detail
 in the dom0 section.)
@@ -50,6 +56,15 @@
 on i386/amd64 hardware and installing software from pkgsrc.
 See also the [Xen website](http://www.xen.org/).
 
+History
+-------
+
+NetBSD used to support Xen2; this has been removed.
+
+Before NetBSD's native bootloader could support Xen, the use of
+grub was recommended.  If necessary, see the
+[old grub information](/xen/howto-grub/).
+
 Versions of Xen and NetBSD
 ==========================
 
@@ -78,6 +93,13 @@
 
 Ideally newer versions of Xen will be added to pkgsrc.
 
+Xen command program
+-------------------
+
+Early Xen used a program called "xm" to manipulate the system from the
+dom0.  Starting in 4.1, a replacement program with similar behavior
+called "xl" is provided.  In 4.2, "xm" is no longer available.
+
 NetBSD
 ------
 
@@ -106,14 +128,19 @@
 --------------
 
 Therefore, this HOWTO recommends running xenkernel42 (and xentools42),
-the NetBSD 6 stable branch, and to use amd64 as the dom0.  Either the
-i386 or amd64 of NetBSD may be used as domUs.
+xl, the NetBSD 6 stable branch, and to use amd64 as the dom0.  Either
+the i386 or amd64 of NetBSD may be used as domUs.
 
 NetBSD as a dom0
 ================
 
 NetBSD can be used as a dom0 and works very well.  The following
 sections address installation, updating NetBSD, and updating Xen.
+Note that it doesn't make sense to talk about installing a dom0 OS
+without also installing Xen itself.  We first address installing
+NetBSD, which is not yet a dom0, and then adding Xen, pivoting the
+NetBSD install to a dom0 install by just changing the kernel and boot
+configuration.
 
 Styles of dom0 operation
 ------------------------
@@ -136,26 +163,41 @@
 Note that NetBSD as dom0 does not support multiple CPUs.  This will
 limit the performance of the Xen/dom0 workstation approach.
 
-Installation of NetBSD and Xen
-------------------------------
+Installation of NetBSD
+----------------------
 
-Note that it doesn't make sense to talk about installing a dom0 OS
-without also installing Xen itself.
+First,
+[install NetBSD/amd64](../../docs/guide/en/chap-inst.html)
+just as you would if you were not using Xen.
+However, the partitioning approach is very important.
+
+If you want to use RAIDframe for the dom0, there are no special issues
+for Xen.  Typically one provides RAID storage for the dom0, and the
+domU systems are unaware of RAID.
+
+There are 4 styles of providing backing storage for the virtual disks
+used by domUs: raw partitions, LVM, file-backed vnd(4), and SAN,
+
+With raw partitions, one has a disklabel (or gpt) partition sized for
+each virtual disk to be used by the domU.  (If you are able to predict
+how domU usage will evolve, please add an explanation to the HOWTO.
+Seriously, needs tend to change over time.)
+
+One can use lvm(8) to create logical devices to use for domU disks.
+This is almost as efficient sa raw disk partitions and more flexible.
+Hence raw disk partitions should typically not be used.
+
+One can use files in the dom0 filesystem, typically created by dd'ing
+/dev/zero to create a specific size.  This is somewhat less efficient,
+but very convenient, as one can cp the files for backup, or move them
+between dom0 hosts.
+
+Finally, in theory one can place the files backing the domU disks in a
+SAN.  (This is an invitation for someone who has done this to add a
+HOWTO page.)
 
-First do a NetBSD/i386 or NetBSD/amd64
-[installation](../../docs/guide/en/chap-inst.html) of the 5.1 release
-(or newer) as you usually do on x86 hardware. The binary releases are
-available from [](ftp://ftp.NetBSD.org/pub/NetBSD/). Binary snapshots
-for current and the stable branches are available on daily autobuilds.
-If you plan to use the `grub` boot loader, when partitioning the disk
-you have to make the root partition smaller than 512Mb, and formatted as
-FFSv1 with 8k block/1k fragments. If the partition is larger than this,
-uses FFSv2 or has different block/fragment sizes, grub may fail to load
-some files. Also keep in mind that you'll probably want to provide
-virtual disks to other domains, so reserve some partitions for these
-virtual disks. Alternatively, you can create large files in the file
-system, map them to vnd(4) devices and export theses vnd devices to
-other domains.
+Installation of Xen
+-------------------
 
 Next step is to install the Xen packages via pkgsrc or from binary
 packages. See [the pkgsrc
@@ -461,7 +503,7 @@
 
     #!/bin/sh
     #============================================================================
-    # $NetBSD: howto.mdwn,v 1.18 2014/12/24 00:11:15 gdt Exp $
+    # $NetBSD: howto.mdwn,v 1.19 2014/12/24 00:41:04 gdt Exp $
     #
     # /usr/pkg/etc/xen/vif-bridge
     #

park some grub text
--- /dev/null	2014-12-24 00:33:43.000000000 +0000
+++ wikisrc/ports/xen/howto-grub.mdwn	2014-12-24 00:34:43.000000000 +0000
@@ -0,0 +1,15 @@
+Stray Grub notes
+================
+
+Now, the use of NetBSD's normal boot code is recommended.  This file
+exists to save stray text about grub.
+
+
+Install
+-------
+
+If you plan to use the `grub` boot loader, when partitioning the disk
+you have to make the root partition smaller than 512Mb, and formatted
+as FFSv1 with 8k block/1k fragments. If the partition is larger than
+this, uses FFSv2 or has different block/fragment sizes, grub may fail
+to load some files.

Add a comment