/[gxemul]/trunk/doc/guestoses.html
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Contents of /trunk/doc/guestoses.html

Parent Directory Parent Directory | Revision Log Revision Log


Revision 42 - (show annotations)
Mon Oct 8 16:22:32 2007 UTC (16 years, 6 months ago) by dpavlin
File MIME type: text/html
File size: 102143 byte(s)
++ trunk/HISTORY	(local)
$Id: HISTORY,v 1.1613 2007/06/15 20:11:26 debug Exp $
20070501	Continuing a little on m88k disassembly (control registers,
		more instructions).
		Adding a dummy mvme88k machine mode.
20070502	Re-adding MIPS load/store alignment exceptions.
20070503	Implementing more of the M88K disassembly code.
20070504	Adding disassembly of some more M88K load/store instructions.
		Implementing some relatively simple M88K instructions (br.n,
		xor[.u] imm, and[.u] imm).
20070505	Implementing M88K three-register and, or, xor, and jmp[.n],
		bsr[.n] including function call trace stuff.
		Applying a patch from Bruce M. Simpson which implements the
		SYSCON_BOARD_CPU_CLOCK_FREQ_ID object of the syscon call in
		the yamon PROM emulation.
20070506	Implementing M88K bb0[.n] and bb1[.n], and skeletons for
		ldcr and stcr (although no control regs are implemented yet).
20070509	Found and fixed the bug which caused Linux for QEMU_MIPS to
		stop working in 0.4.5.1: It was a faulty change to the MIPS
		'sc' and 'scd' instructions I made while going through gcc -W
		warnings on 20070428.
20070510	Updating the Linux/QEMU_MIPS section in guestoses.html to
		use mips-test-0.2.tar.gz instead of 0.1.
		A big thank you to Miod Vallat for sending me M88K manuals.
		Implementing more M88K instructions (addu, subu, div[u], mulu,
		ext[u], clr, set, cmp).
20070511	Fixing bugs in the M88K "and" and "and.u" instructions (found
		by comparing against the manual).
		Implementing more M88K instructions (mask[.u], mak, bcnd (auto-
		generated)) and some more control register details.
		Cleanup: Removing the experimental AVR emulation mode and
		corresponding devices; AVR emulation wasn't really meaningful.
		Implementing autogeneration of most M88K loads/stores. The
		rectangle drawing demo (with -O0) for M88K runs :-)
		Beginning on M88K exception handling.
		More M88K instructions: tb0, tb1, rte, sub, jsr[.n].
		Adding some skeleton MVME PROM ("BUG") emulation.
20070512	Fixing a bug in the M88K cmp instruction.
		Adding the M88K lda (scaled register) instruction.
		Fixing bugs in 64-bit (32-bit pairs) M88K loads/stores.
		Removing the unused tick_hz stuff from the machine struct.
		Implementing the M88K xmem instruction. OpenBSD/mvme88k gets
		far enough to display the Copyright banner :-)
		Implementing subu.co (guess), addu.co, addu.ci, ff0, and ff1.
		Adding a dev_mvme187, for MVME187-specific devices/registers.
		OpenBSD/mvme88k prints more boot messages. :)
20070515	Continuing on MVME187 emulation (adding more devices, beginning
		on the CMMUs, etc).
		Adding the M88K and.c, xor.c, and or.c instructions, and making
		sure that mul, div, etc cause exceptions if executed when SFD1
		is disabled.
20070517	Continuing on M88K and MVME187 emulation in general; moving
		the CMMU registers to the CPU struct, separating dev_pcc2 from
		dev_mvme187, and beginning on memory_m88k.c (BATC and PATC).
		Fixing a bug in 64-bit (32-bit pairs) M88K fast stores.
		Implementing the clock part of dev_mk48txx.
		Implementing the M88K fstcr and xcr instructions.
		Implementing m88k_cpu_tlbdump().
		Beginning on the implementation of a separate address space
		for M88K .usr loads/stores.
20070520	Removing the non-working (skeleton) Sandpoint, SonyNEWS, SHARK
		Dnard, and Zaurus machine modes.
		Experimenting with dyntrans to_be_translated read-ahead. It
		seems to give a very small performance increase for MIPS
		emulation, but a large performance degradation for SuperH. Hm.
20070522	Disabling correct SuperH ITLB emulation; it does not seem to be
		necessary in order to let SH4 guest OSes run, and it slows down
		userspace code.
		Implementing "samepage" branches for SuperH emulation, and some
		other minor speed hacks.
20070525	Continuing on M88K memory-related stuff: exceptions, memory
		transaction register contents, etc.
		Implementing the M88K subu.ci instruction.
		Removing the non-working (skeleton) Iyonix machine mode.
		OpenBSD/mvme88k reaches userland :-), starts executing
		/sbin/init's instructions, and issues a few syscalls, before
		crashing.
20070526	Fixing bugs in dev_mk48txx, so that OpenBSD/mvme88k detects
		the correct time-of-day.
		Implementing a generic IRQ controller for the test machines
		(dev_irqc), similar to a proposed patch from Petr Stepan.
		Experimenting some more with translation read-ahead.
		Adding an "expect" script for automated OpenBSD/landisk
		install regression/performance tests.
20070527	Adding a dummy mmEye (SH3) machine mode skeleton.
		FINALLY found the strange M88K bug I have been hunting: I had
		not emulated the SNIP value for exceptions occurring in
		branch delay slots correctly.
		Implementing correct exceptions for 64-bit M88K loads/stores.
		Address to symbol lookups are now disabled when M88K is
		running in usermode (because usermode addresses don't have
		anything to do with supervisor addresses).
20070531	Removing the mmEye machine mode skeleton.
20070604	Some minor code cleanup.
20070605	Moving src/useremul.c into a subdir (src/useremul/), and
		cleaning up some more legacy constructs.
		Adding -Wstrict-aliasing and -fstrict-aliasing detection to
		the configure script.
20070606	Adding a check for broken GCC on Solaris to the configure
		script. (GCC 3.4.3 on Solaris cannot handle static variables
		which are initialized to 0 or NULL. :-/)
		Removing the old (non-working) ARC emulation modes: NEC RD94,
		R94, R96, and R98, and the last traces of Olivetti M700 and
		Deskstation Tyne.
		Removing the non-working skeleton WDSC device (dev_wdsc).
20070607	Thinking about how to use the host's cc + ld at runtime to
		generate native code. (See experiments/native_cc_ld_test.i
		for an example.)
20070608	Adding a program counter sampling timer, which could be useful
		for native code generation experiments.
		The KN02_CSR_NRMMOD bit in the DECstation 5000/200 (KN02) CSR
		should always be set, to allow a 5000/200 PROM to boot.
20070609	Moving out breakpoint details from the machine struct into
		a helper struct, and removing the limit on max nr of
		breakpoints.
20070610	Moving out tick functions into a helper struct as well (which
		also gets rid of the max limit).
20070612	FINALLY figured out why Debian/DECstation stopped working when
		translation read-ahead was enabled: in src/memory_rw.c, the
		call to invalidate_code_translation was made also if the
		memory access was an instruction load (if the page was mapped
		as writable); it shouldn't be called in that case.
20070613	Implementing some more MIPS32/64 revision 2 instructions: di,
		ei, ext, dext, dextm, dextu, and ins.
20070614	Implementing an instruction combination for the NetBSD/arm
		idle loop (making the host not use any cpu if NetBSD/arm
		inside the emulator is not using any cpu).
		Increasing the nr of ARM VPH entries from 128 to 384.
20070615	Removing the ENABLE_arch stuff from the configure script, so
		that all included architectures are included in both release
		and development builds.
		Moving memory related helper functions from misc.c to memory.c.
		Adding preliminary instructions for netbooting NetBSD/pmppc to
		guestoses.html; it doesn't work yet, there are weird timeouts.
		Beginning a total rewrite of the userland emulation modes
		(removing all emulation modes, beginning from scratch with
		NetBSD/MIPS and FreeBSD/Alpha only).
20070616	After fixing a bug in the DEC21143 NIC (the TDSTAT_OWN bit was
		only cleared for the last segment when transmitting, not all
		segments), NetBSD/pmppc boots with root-on-nfs without the
		timeouts. Updating guestoses.html.
		Removing the skeleton PSP (Playstation Portable) mode.
		Moving X11-related stuff in the machine struct into a helper
		struct.
		Cleanup of out-of-memory checks, to use a new CHECK_ALLOCATION
		macro (which prints a meaningful error message).
		Adding a COMMENT to each machine and device (for automagic
		.index comment generation).
		Doing regression testing for the next release.

==============  RELEASE 0.4.6  ==============


1 <html><head><title>Gavare's eXperimental Emulator:&nbsp;&nbsp;&nbsp;Installing and running "guest OSes"</title>
2 <meta name="robots" content="noarchive,nofollow,noindex"></head>
3 <body bgcolor="#f8f8f8" text="#000000" link="#4040f0" vlink="#404040" alink="#ff0000">
4 <table border=0 width=100% bgcolor="#d0d0d0"><tr>
5 <td width=100% align=center valign=center><table border=0 width=100%><tr>
6 <td align="left" valign=center bgcolor="#d0efff"><font color="#6060e0" size="6">
7 <b>Gavare's eXperimental Emulator:</b></font><br>
8 <font color="#000000" size="6"><b>Installing and running "guest OSes"</b>
9 </font></td></tr></table></td></tr></table><p>
10
11 <!--
12
13 $Id: guestoses.html,v 1.226 2007/06/15 06:26:19 debug Exp $
14
15 Copyright (C) 2003-2007 Anders Gavare. All rights reserved.
16
17 Redistribution and use in source and binary forms, with or without
18 modification, are permitted provided that the following conditions are met:
19
20 1. Redistributions of source code must retain the above copyright
21 notice, this list of conditions and the following disclaimer.
22 2. Redistributions in binary form must reproduce the above copyright
23 notice, this list of conditions and the following disclaimer in the
24 documentation and/or other materials provided with the distribution.
25 3. The name of the author may not be used to endorse or promote products
26 derived from this software without specific prior written permission.
27
28 THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
29 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
30 IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
31 ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
32 FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
33 DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
34 OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
35 HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
36 LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
37 OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
38 SUCH DAMAGE.
39
40 -->
41
42
43 <a href="./">Back to the index</a>
44
45 <p><br>
46 <h2>Installing and running "guest OSes"</h2>
47
48 <p>
49 <ul>
50 <li><a href="#generalnotes">General notes on running "guest OSes"</a>
51 <li><a href="#netbsdpmaxinstall">NetBSD/pmax 3.1 or 1.6.2</a>
52 <li><a href="#netbsdarcinstall">NetBSD/arc 1.6.2</a>
53 <li><a href="#netbsdhpcmipsinstall">NetBSD/hpcmips 3.1</a>
54 <li><a href="#netbsdcobaltinstall">NetBSD/cobalt 3.1</a>
55 <li><a href="#netbsdevbmipsinstall">NetBSD/evbmips 3.1</a>
56 <li><a href="#netbsdalgorinstall">NetBSD/algor 3.1</a>
57 <li><a href="#netbsdsgimips">NetBSD/sgimips 3.1</a>
58 <li><a href="#netbsdcatsinstall">NetBSD/cats 3.1</a>
59 <li><a href="#netbsdevbarminstall">NetBSD/evbarm 2.1</a>
60 <li><a href="#netbsdnetwinderinstall">NetBSD/netwinder 3.1</a>
61 <li><a href="#netbsdprepinstall">NetBSD/prep 2.1</a>
62 <li><a href="#netbsdmacppcinstall">NetBSD/macppc 3.1</a>
63 <li><a href="#netbsdpmppc">NetBSD/pmppc 3.1</a>
64 <li><a href="dreamcast.html#netbsd_generic_md">NetBSD/dreamcast 3.1</a>
65 <li><a href="dreamcast.html#linux_live_cd">Linux/dreamcast</a>
66 <li><a href="#openbsdpmaxinstall">OpenBSD/pmax 2.8-BETA</a>
67 <li><a href="#openbsdcatsinstall">OpenBSD/cats 4.0</a>
68 <li><a href="#openbsdlandiskinstall">OpenBSD/landisk 4.1</a>
69 <li><a href="#ultrixinstall">Ultrix/RISC 4.5</a>
70 <li><a href="#sprite">Sprite for DECstation</a>
71 <li><a href="#declinux">Debian GNU/Linux for DECstation</a>
72 </ul>
73
74
75
76
77
78
79 <p><br>
80 <a name="generalnotes"></a>
81 <h3>General notes on running "guest OSes":</h3>
82
83 The emulator works well enough to run complete operating systems. These
84 are often refered to as <i>guest</i> operating systems, in contrast to the
85 <i>host</i> operating system which the emulator is running under.
86
87 <p>Although it is possible to let a guest OS access real hardware, such as
88 harddisks, it is much more flexible and attractive to simulate harddisks
89 using files residing in the host's filesystem. On Unix-like systems, files
90 may contain holes, which makes this really simple. To the guest operating
91 system, the harddisk image looks and acts like a real disk.
92
93 <p>The version numbers of the various operating systems were the latest
94 versions that worked satisfactory with GXemul at the time this page was
95 updated; if new versions have been released since then, they might work as
96 well.
97
98 <p>In addition to the "working" guest operating systems listed above,
99 you might find the following information interesting:
100
101 <ul>
102 <li><a href="#mach">Mach/PMAX</a>
103 <li><a href="#declinuxredhat">Redhat Linux for DECstation</a>
104 <li><a href="#openbsdsgiinstall">OpenBSD/sgi</a>
105 <li><a href="#openbsdarcinstall">OpenBSD/arc 2.3</a>
106 <li><a href="#debiancats">Debian GNU/Linux for CATS</a>
107 <!-- <li><a href="#linux_malta">Linux/Malta</a> -->
108 <li><a href="#linux_qemu_mips">Linux/QEMU_MIPS</a>
109 <li><a href="#windows_nt_mips">Windows NT/MIPS</a>
110 <li><a href="#netbsdbeboxinstall">NetBSD/bebox 19981119</a>
111 <li><a href="#netbsdlandiskinstall">NetBSD/landisk</a>
112 </ul>
113
114 <p><b><font color="#ff0000">NOTE:</b>
115 Some of these sections may not be relevant to this
116 specific release of GXemul,</font> for example some of these
117 modes may be legacy modes that worked before but not any longer,
118 or are not yet working but could be in the future.
119
120 <p>Some operating systems are listed with a version number <i>less</i>
121 than what was available at the time of this GXemul release (e.g.
122 NetBSD/prep). The reasons for this is because of incompleteness in
123 GXemul's machine, device, and/or processor implementations.
124
125
126
127
128
129
130
131 <p><br>
132 <a name="netbsdpmaxinstall"></a>
133 <h3>NetBSD/pmax:</h3>
134
135 <p><a href="http://www.netbsd.org/ports/pmax/">NetBSD/pmax</a> was the
136 first guest OS that could be
137 <a href="http://mail-index.netbsd.org/port-pmax/2004/04/18/0000.html">installed</a>
138 onto a disk image in GXemul. The device emulation of the DECstation
139 5000/200 is reasonably complete; it should be enough to emulate a
140 networked X-windows-capable workstation.
141
142 <p>NetBSD/pmax 1.6.2 works perfectly with X out-of-the-box. Unfortunately,
143 newer NetBSD releases have changed slightly, and X does not work straight
144 away with NetBSD 2.x and 3.x. It seems that this has to do with NetBSD
145 switching console system to "WSCONS" somewhere between 1.6.2 and 2.0.
146
147 <p>What this means is that if you want to use emulated X11, then you need
148 to run NetBSD 1.6.2. At the time of writing this, 4.0_BETA snapshots work
149 fine too, but 4.0 isn't released yet. If you feel that you only need
150 serial-console emulation, then choose 3.1.
151
152 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
153 <a href="20050317-example.png"><img src="20050317-example_small.png"></a>
154
155 <p>To install NetBSD/pmax onto a harddisk image in the emulator,
156 follow these instructions:
157
158 <p><ol>
159 <li>Create an empty harddisk image, which will be the root disk
160 that NetBSD installs itself onto:<pre>
161 <b>dd if=/dev/zero of=nbsd_pmax.img bs=1024 count=1 seek=3000000</b>
162
163 </pre>
164 <li>Download a NetBSD CD-ROM iso image:<pre>
165 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-archive/iso/1.6.2/pmaxcd.iso">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-archive/iso/1.6.2/pmaxcd.iso</a>
166 or
167 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/pmaxcd-3.1.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/pmaxcd-3.1.iso</a>
168
169 </pre>
170 <li>Start the emulator like this:<pre>
171 <b>gxemul -e 3max -d nbsd_pmax.img -d b:pmaxcd-3.1.iso</b>
172 (or <b>pmaxcd.iso</b>)
173 </pre>
174 and proceed like you would do if you were installing NetBSD on a real
175 DECstation. Remember to choose <tt>vt100</tt> as your terminal
176 type, and not <tt>rcons</tt>.
177 </ol>
178
179 <p>If you prefer to do an ftp install (usually much slower), you can
180 follow these instructions instead:
181
182 <p>
183 <ol>
184 <li>Create an empty harddisk image, which will be the root disk
185 that NetBSD installs itself onto:<pre>
186 <b>dd if=/dev/zero of=nbsd_pmax.img bs=1024 count=1 seek=3000000</b>
187
188 </pre>
189 <li>Download a NetBSD pmax INSTALL kernel:<pre>
190 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-archive/NetBSD-1.6.2/pmax/binary/kernel/netbsd-INSTALL.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-archive/NetBSD-1.6.2/pmax/binary/kernel/netbsd-INSTALL.gz</a>
191 or
192 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/pmax/binary/kernel/netbsd-INSTALL.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/pmax/binary/kernel/netbsd-INSTALL.gz</a>
193
194 </pre>
195 <li>Start the emulator like this:<pre>
196 <b>gxemul -e 3max -d nbsd_pmax.img -O netbsd-INSTALL.gz</b>
197 </pre>
198 and proceed like you would do if you were installing NetBSD on a real
199 DECstation. Remember to choose <tt>vt100</tt> as your terminal
200 type, and not <tt>rcons</tt>. Suitable networking parameters are as
201 follows:<pre>
202 Which device shall I use? [le0]: <b>le0</b>
203 ..
204 Your DNS domain: <b>mydomain.com</b>
205 Your host name: <b>foo</b>
206 Your IPv4 number: <b>10.0.0.1</b>
207 IPv4 Netmask [0xff000000]: <b>0xff000000</b>
208 IPv4 gateway: <b>10.0.0.254</b>
209 IPv4 name server: <b>10.0.0.254</b>
210 </pre>
211 (If using 10.0.0.254 as the nameserver fails, then try entering the
212 IP number of a real-world nameserver instead.)
213 <p>
214 Note that NetBSD 1.6.2 is nowadays located at
215 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-archive/NetBSD-1.6.2">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-archive/NetBSD-1.6.2</a>
216 (note <tt>NetBSD-archive</tt> part).
217 </ol>
218
219 <p>If you want to use a graphical framebuffer during the install, you can
220 add <b><tt>-X -Y2</tt></b> to the command line, and choose <tt>rcons</tt>
221 instead of <tt>vt100</tt> when prompted with which terminal type to use.
222 (By just using <tt><b>-X</b></tt>, you will get a full-size framebuffer
223 window.)
224
225 <p>When the installation is finished, the following command should start
226 NetBSD from the harddisk image:<pre>
227 <b>gxemul -e 3max -d nbsd_pmax.img</b>
228 </pre>
229
230 <p>If you installed NetBSD/pmax 1.6.2, or 4.0_BETA, then try the
231 following to start with a framebuffer:<pre>
232 <b>gxemul -X -e 3max -d nbsd_pmax.img</b>
233 </pre>
234 and log in as <tt>root</tt> and type <tt>startx</tt> to start X windows.
235
236
237
238
239
240
241
242
243 <p><br>
244 <a name="netbsdarcinstall"></a>
245 <h3>NetBSD/arc:</h3>
246
247 It is possible to install and run an old version of <a
248 href="http://www.netbsd.org/ports/arc/">NetBSD/arc</a>
249 on an emulated Acer PICA-61 in the emulator.
250
251 <p>
252 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
253 <a href="20041024-netbsd-arc-installed.gif"><img src="20041024-netbsd-arc-installed_small.gif"></a>
254
255 <p>
256 To install NetBSD/arc 1.6.2 from a CDROM image onto an emulated
257 harddisk image, follow these instructions:
258
259 <p>
260 <ol start="1">
261 <li>Create an empty harddisk image, which will be the root disk
262 that NetBSD installs itself onto:<pre>
263 <b>dd if=/dev/zero of=nbsd_arc.img bs=1024 count=1 seek=2000000</b>
264
265 </pre>
266 <li>Download a NetBSD/arc 1.6.2 CDROM image, and a generic NetBSD/arc
267 kernel:<pre>
268 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-archive/iso/1.6.2/arccd.iso">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-archive/iso/1.6.2/arccd.iso</a>
269 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-archive/NetBSD-1.6.2/arc/binary/kernel/netbsd-GENERIC.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-archive/NetBSD-1.6.2/arc/binary/kernel/netbsd-GENERIC.gz</a>
270
271 </pre>
272 <li>Start the emulator using this command line:<pre>
273 <b>gxemul -e pica -x -d nbsd_arc.img -d b:arccd.iso -j arc/binary/kernel/netbsd.RAMDISK.gz</b>
274
275 </pre>
276 (Try removing <tt>-x</tt> if you have problems with the xterm.)
277 <p>
278 <li>From now on, you have to use your imagination, as there is no
279 automatic installation program for NetBSD/arc 1.6.2. Here are
280 some tips and hints on how you can proceed with the install:
281 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
282 <b>mount /dev/cd0a /mnt2
283 disklabel -i -I sd0</b> (for example 'a', '4.2BSD', '1c',
284 '700M', 'b', 'swap', '701M', '$', 'P', 'W', 'y', and 'Q')
285 <b>newfs /dev/sd0a
286 mount /dev/sd0a /mnt
287 cd /mnt
288 for a in /mnt2/arc/binary/sets/*.tgz; do echo $a; tar xzpf $a; done
289 cd dev; sh MAKEDEV all
290 cd ../etc; echo "rc_configured=YES" &gt;&gt; rc.conf
291 cat > /mnt/etc/fstab
292 /dev/sd0a / ffs rw 1 1
293 /dev/sd0b none swap sw 0 0
294 </b>(press ctrl-d)
295 <b>cd /; umount /mnt; umount /mnt2
296 halt</b>
297 </pre></td></tr></table>
298 </ol>
299
300 <p>You can now use the generic NetBSD/arc kernel to boot from the harddisk
301 image, using the following command:<pre>
302 <b>gxemul -e pica -x -d nbsd_arc.img netbsd-GENERIC.gz</b>
303
304 </pre>
305
306 <p>When asked for "<tt>root device: </tt>", enter <b><tt>sd0</tt></b>.
307
308
309
310
311
312
313
314 <p><br>
315 <a name="netbsdhpcmipsinstall"></a>
316 <h3>NetBSD/hpcmips:</h3>
317
318 It is possible to install <a
319 href="http://www.netbsd.org/ports/hpcmips/">NetBSD/hpcmips</a> onto a disk
320 image, on an an emulated MobilePro 770 or 800. (MobilePro 780 and 880 might
321 work too, but I don't test those for every release of the emulator. They
322 have unaligned framebuffers, and run a bit slower.)
323
324 <p>
325 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
326 <a href="20050427-netbsd-hpcmips-1.png"><img src="20050427-netbsd-hpcmips-1_small.png"></a>
327 &nbsp;&nbsp;&nbsp;
328 <a href="20050427-netbsd-hpcmips-2.png"><img src="20050427-netbsd-hpcmips-2_small.png"></a>
329
330 <p>
331 These instructions show an example of how to install
332 NetBSD/hpcmips on an emulated MobilePro 770:
333
334 <p>
335 <ol start="1">
336 <li>Create an empty harddisk image, which will be the root disk
337 that you will install NetBSD/hpcmips onto:<pre>
338 <b>dd if=/dev/zero of=nbsd_hpcmips.img bs=1024 count=1 seek=3000000</b>
339
340 </pre>
341 <li>Download the NetBSD/hpcmips 3.1 ISO image, and a generic kernel:<pre>
342 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/">ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1</a>/<a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/hpcmipscd-3.1.iso">hpcmipscd-3.1.iso</a>
343 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/hpcmips/binary/kernel/">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/hpcmips/binary/kernel</a>/<a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/hpcmips/binary/kernel/netbsd-GENERIC.gz">netbsd-GENERIC.gz</a>
344
345 </pre>
346 <p>
347 <li>Start the installation like this:<pre>
348 <b>gxemul -e mobilepro770 -X -d nbsd_hpcmips.img -d b:hpcmipscd-3.1.iso -j hpcmips/installation/netbsd.gz</b>
349
350 </pre>
351 and proceed like you would do if you were installing NetBSD on a real
352 MobilePro 770. (Install onto wd0, choose "Use entire disk" when
353 doing the MBR partitioning, and choose to install from CD-ROM.)
354 </ol>
355
356 <p>
357 If everything worked, NetBSD should now be installed on the disk image.
358 Use the following command line to boot the emulated hpcmips machine:<pre>
359 <b>gxemul -e mobilepro770 -X -d nbsd_hpcmips.img netbsd-GENERIC.gz</b>
360
361 </pre>
362
363 <p>When you have logged in as <tt>root</tt>, you can use <tt>startx</tt> to
364 start X Windows, but there is no mouse support yet so only keyboard input
365 is available. This makes it a bit akward to use X.
366
367
368
369
370
371
372
373
374 <p><br>
375 <a name="netbsdcobaltinstall"></a>
376 <h3>NetBSD/cobalt:</h3>
377
378 <a href="http://www.netbsd.org/ports/cobalt/">NetBSD/cobalt</a> is tricky
379 to install, because the Cobalt machines were designed for Linux, and not
380 very flexible. There is no traditional INSTALL kernel for NetBSD/cobalt.
381 One way to install the NetBSD/cobalt distribution onto a disk image is to
382 do it from another (emulated) machine.
383
384 <p>
385 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
386 <a href="20060812-netbsd-cobalt-3.0.1.png"><img src="20060812-netbsd-cobalt-3.0.1_small.png"></a>
387
388 <p>
389 The following instructions will let you install NetBSD/cobalt onto a disk
390 image, from an emulated DECstation 3MAX machine:
391
392 <p>
393 <ol>
394 <li>Download a NetBSD/pmax (DECstation) install RAMDISK kernel:<pre>
395 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/pmax/binary/kernel/netbsd-INSTALL.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/pmax/binary/kernel/netbsd-INSTALL.gz</a>
396 </pre>
397 <p>
398 <li>Create an empty harddisk image, which will be the disk image
399 that you will install NetBSD/cobalt onto:<pre>
400 <b>dd if=/dev/zero of=nbsd_cobalt.img bs=1024 count=1 seek=700000</b>
401
402 </pre>
403 <li>Download the generic kernel for Cobalt and the 3.1 ISO image:<pre>
404 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/cobalt/binary/kernel/netbsd-GENERIC.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/cobalt/binary/kernel/netbsd-GENERIC.gz</a>
405 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/cobaltcd-3.1.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/cobaltcd-3.1.iso</a>
406
407 </pre>
408 <li>Start the emulated DECstation machine like this:<pre>
409 <b>gxemul -e 3max -d nbsd_cobalt.img -d cobaltcd-3.1.iso netbsd-INSTALL.gz</b>
410
411 </pre>
412 <li>At the <tt>Terminal type? [rcons]</tt> prompt, type <b>CTRL-B</b>
413 to simulate a CTRL-C sent to NetBSD/pmax. Then execute the following commands:
414 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
415 <b>newfs /dev/sd0c
416 mount /dev/cd0c /mnt
417 mkdir /mnt2; mount /dev/sd0c /mnt2
418 cd /mnt2; sh
419 for a in /mnt/*/binary/sets/[bcekmt]*.tgz; do echo $a; tar zxfp $a; done
420 exit
421 cd dev; sh ./MAKEDEV all; cd ../etc
422 echo rc_configured=YES >> rc.conf
423 echo "/dev/wd0d / ffs rw 1 1" > fstab
424 cd /; umount /mnt; umount /mnt2; halt</b>
425 </pre></td></tr></table>
426 </ol>
427
428 <p>
429 You should now be able to boot NetBSD/cobalt like this:<pre>
430 <b>gxemul -E cobalt -d nbsd_cobalt.img netbsd-GENERIC.gz</b>
431 </pre>
432
433 Note that the installation instructions above create a filesystem
434 <i>without</i> a disklabel, so there is only one ffs partition and no
435 swap. You will need to enter the following things when booting with the
436 generic kernel:<pre>
437 root device (default wd0a): <b>wd0d</b>
438 dump device (default wd0b): <b>none</b>
439 file system (default generic): <b>ffs</b>
440 init path (default /sbin/init): <i>(just press enter here)</i>
441 </pre>
442
443
444
445
446
447
448
449 <p><br>
450 <a name="netbsdevbmipsinstall"></a>
451 <h3>NetBSD/evbmips:</h3>
452
453 <a href="http://www.netbsd.org/ports/evbmips/">NetBSD/evbmips</a> can run
454 in GXemul on an emulated Malta evaluation board, with a 5Kc (MIPS64) or
455 4Kc (MIPS32) processor. 5Kc is the default.
456
457 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
458 <a href="20060812-netbsd-malta-3.0.1.png"><img src="20060812-netbsd-malta-3.0.1_small.png"></a>
459
460 <p>One way to install the NetBSD/evbmips distribution onto a disk
461 image is to install the files using another (emulated) machine.
462
463 <p>
464 The following instructions will let you install NetBSD/evbmips onto a disk
465 image, from an emulated DECstation 3MAX machine:
466
467 <p>
468 <ol>
469 <li>Download a NetBSD/pmax (DECstation) install RAMDISK kernel:<pre>
470 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/pmax/binary/kernel/netbsd-INSTALL.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/pmax/binary/kernel/netbsd-INSTALL.gz</a>
471 </pre>
472 <p>
473 <li>Create an empty harddisk image, which will be the disk image
474 that you will install NetBSD onto:<pre>
475 <b>dd if=/dev/zero of=nbsd_malta.img bs=1024 count=1 seek=700000</b>
476
477 </pre>
478 <li>Download the Malta kernel and the 3.1 ISO image:<pre>
479 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/evbmips-mipsel/binary/kernel/netbsd-MALTA.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/evbmips-mipsel/binary/kernel/netbsd-MALTA.gz</a>
480 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/evbmips-mipselcd-3.1.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/evbmips-mipselcd-3.1.iso</a>
481
482 </pre>
483 <p>
484 <li>Start the emulated DECstation machine like this:<pre>
485 <b>gxemul -e 3max -d nbsd_malta.img -d evbmips-mipselcd-3.1.iso netbsd-INSTALL.gz</b>
486
487 </pre>
488 <li>At the <tt>Terminal type? [rcons]</tt> prompt, type <b>CTRL-B</b>
489 to simulate a CTRL-C sent to NetBSD/pmax. Then execute the following commands:
490 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
491 <b>newfs /dev/sd0c
492 mount /dev/cd0c /mnt
493 mkdir /mnt2; mount /dev/sd0c /mnt2
494 cd /mnt2; sh
495 for a in /mnt/*/binary/sets/[bcemt]*.tgz; do echo $a; tar zxfp $a; done
496 exit
497 cd dev; sh ./MAKEDEV all; cd ../etc
498 echo rc_configured=YES >> rc.conf
499 echo "/dev/wd0c / ffs rw 1 1" > fstab
500 cd /; umount /mnt; umount /mnt2; halt</b>
501 </pre></td></tr></table>
502 </ol>
503
504 <p>You should now be able to boot NetBSD/evbmips using this command:<pre>
505 <b>gxemul -x -e malta -d nbsd_malta.img netbsd-MALTA.gz</b>
506 </pre>
507
508 <p>NOTE: To select a 4Kc (MIPS32) CPU instead of the default 5Kc
509 (MIPS64) CPU, add <tt><b>-C 4Kc</b></tt> to the command line. With NetBSD
510 3.1, however, there will be little or no difference in functionality, as
511 NetBSD still runs in 32-bit mode on 64-bit MIPS CPUs. There are two things
512 that differ:<ol>
513 <li>The dynamic translation core runs faster when emulating 32-bit
514 processors, so <tt><b>-C 4Kc</b></tt> might make things go faster.
515 <li>4Kc only has 16 TLB entries, whereas 5Kc has 48. This makes 4Kc
516 emulation slower in general, because there are more TLB misses.
517 </ol>
518
519 <p>The installation instructions above create a filesystem
520 <i>without</i> a disklabel, so there is only one ffs partition and no
521 swap. You will need to enter the following things when booting with the
522 generic kernel:<pre>
523 root device (default wd0a): <b>wd0c</b>
524 dump device (default wd0b): <i>(just press enter)</i>
525 file system (default generic): <i>(just press enter)</i>
526 init path (default /sbin/init): <i>(just press enter)</i>
527 </pre>
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542 <p><br>
543 <a name="netbsdalgorinstall"></a>
544 <h3>NetBSD/algor:</h3>
545
546 <a href="http://www.netbsd.org/ports/algor/">NetBSD/algor</a> can
547 run in GXemul on an emulated Algorithmics P5064 evaluation board.
548
549 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
550 <a href="20060814-netbsd-algor-3.0.1.png"><img src="20060814-netbsd-algor-3.0.1_small.png"></a>
551
552 <p>One way to install the NetBSD/algor distribution onto a disk
553 image is to install the files using another (emulated) machine.
554
555 <p>The following instructions will let you install NetBSD/algor onto a disk
556 image, from an emulated DECstation 3MAX machine:
557
558 <p>
559 <ol>
560 <li>Download a NetBSD/pmax (DECstation) install RAMDISK kernel:<pre>
561 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/pmax/binary/kernel/netbsd-INSTALL.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/pmax/binary/kernel/netbsd-INSTALL.gz</a>
562 </pre>
563 <p>
564 <li>Create an empty harddisk image, which will be the disk image
565 that you will install NetBSD/algor onto:<pre>
566 <b>dd if=/dev/zero of=nbsd_algor.img bs=1024 count=1 seek=700000</b>
567
568 </pre>
569 <li>Download the P5064 Algor kernel and the 3.1 ISO image:<pre>
570 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/algor/binary/kernel/netbsd-P5064.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/algor/binary/kernel/netbsd-P5064.gz</a>
571 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/algorcd-3.1.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/algorcd-3.1.iso</a>
572
573 </pre>
574 <p>
575 <li>Start the emulated DECstation machine like this:<pre>
576 <b>gxemul -e 3max -d nbsd_algor.img -d algorcd-3.1.iso netbsd-INSTALL.gz</b>
577
578 </pre>
579 <li>At the <tt>Terminal type? [rcons]</tt> prompt, type <b>CTRL-B</b>
580 to simulate a CTRL-C sent to NetBSD/pmax. Then execute the following commands:
581 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
582 <b>newfs /dev/sd0c
583 mount /dev/cd0c /mnt
584 mkdir /mnt2; mount /dev/sd0c /mnt2
585 cd /mnt2; sh
586 for a in /mnt/*/binary/sets/[bcekmt]*.tgz; do echo $a; tar zxfp $a; done
587 exit
588 cd dev; sh ./MAKEDEV all; cd ../etc
589 echo rc_configured=YES >> rc.conf
590 echo "/dev/wd0c / ffs rw 1 1" > fstab
591 cd /; umount /mnt; umount /mnt2; halt</b>
592 </pre></td></tr></table>
593 </ol>
594
595 <p>You should now be able to boot NetBSD/algor using this command:<pre>
596 <b>gxemul -x -e p5064 -d nbsd_algor.img netbsd-P5064.gz</b>
597 </pre>
598
599 <p>The installation instructions above create a filesystem
600 <i>without</i> a disklabel, so there is only one ffs partition and no
601 swap. You will need to enter the following things when booting with the
602 generic kernel:<pre>
603 root device (default wd0a): <b>wd0c</b>
604 dump device (default wd0b): <i>(just press enter)</i>
605 file system (default generic): <i>(just press enter)</i>
606 init path (default /sbin/init): <i>(just press enter)</i>
607 </pre>
608
609
610
611
612
613
614
615
616
617
618
619
620 <p><br>
621 <a name="netbsdsgimips"></a>
622 <h3>NetBSD/sgimips:</h3>
623
624 <p>
625 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
626 <a href="20060623-netbsd-sgimips-3.0.png"><img src="20060623-netbsd-sgimips-3.0_small.png"></a>
627
628 <p><a href="http://www.netbsd.org/ports/sgimips/">NetBSD/sgimips</a> can run
629 in GXemul on an emulated O2 (SGI-IP32). However, GXemul does not yet
630 emulate the AHC PCI SCSI controller in the O2. (I have mailed Adaptec
631 several times, asking for documentation, but never received any reply.)
632 NetBSD can still run in the emulator, as long as it doesn't use SCSI.
633
634 <p>For a simple test with the ramdisk/install kernel, try
635 dowloading<pre>
636 <a href="ftp://ftp.NetBSD.org/pub/NetBSD/NetBSD-3.1/sgimips/binary/kernel/netbsd-INSTALL32_IP3x.gz">ftp://ftp.NetBSD.org/pub/NetBSD/NetBSD-3.1/sgimips/binary/kernel/netbsd-INSTALL32_IP3x.gz</a>
637
638 </pre>and run&nbsp;&nbsp;<b><tt>gxemul -x -e o2 netbsd-INSTALL32_IP3x.gz</tt></b>.
639
640 <p>It is possible to set up an environment for netbooting the emulated SGI
641 machine off of another emulated machine. Performing this setup is quite
642 time consuming, but necessary:
643
644 <p>
645 <ol>
646 <li>First of all, the "<tt>nfs server</tt>" machine must be set up.
647 This needs to have a 750 MB <tt>/tftpboot</tt> partition.
648 <a href="#netbsdpmaxinstall">Install NetBSD/pmax 3.1 from CDROM</a>.
649 (Don't forget to add the extra partition!)
650 <p>
651 <li>Configure the nfs server machine to act as an nfs server.
652 Start up the emulated DECstation:<pre>
653 <b>gxemul -e 3max -d nbsd_pmax.img</b>
654 </pre>and enter the following commands as <tt>root</tt>
655 inside the emulator:
656 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
657 <b>echo hostname=server &gt;&gt; /etc/rc.conf
658 echo ifconfig_le0=\"inet 10.0.0.2\" &gt;&gt; /etc/rc.conf
659 echo nameserver 10.0.0.254 &gt;&gt; /etc/resolv.conf
660 echo 10.0.0.254 &gt; /etc/mygate
661 echo /tftpboot -maproot=root 10.0.0.1 &gt; /etc/exports
662 echo rpcbind=YES &gt;&gt; /etc/rc.conf
663 echo nfs_server=YES &gt;&gt; /etc/rc.conf
664 echo mountd=YES &gt;&gt; /etc/rc.conf
665 echo bootparamd=YES &gt;&gt; /etc/rc.conf
666 printf "client root=10.0.0.2:/tftpboot \\\n swap=10.0.0.2:/tftpboot/swap\n" &gt; /etc/bootparams
667 echo "bootps dgram udp wait root /usr/sbin/bootpd bootpd -d 4 -h 10.0.0.2" &gt;&gt; /etc/inetd.conf
668 cat &gt;&gt; /etc/bootptab
669 client:\
670 :ht=ether:\
671 :ha=102030000010:\
672 :sm=255.0.0.0:\
673 :lg=10.0.0.254:\
674 :ip=10.0.0.1:\
675 :rp=/tftpboot:
676 </b>(press CTRL-D)
677 <b>echo "10:20:30:00:00:10 client" &gt; /etc/ethers
678 echo 10.0.0.1 client &gt; /etc/hosts
679 reboot</b>
680 </pre></td></tr></table>
681 <p>
682 <li>Download the NetBSD/sgimips CD-ROM iso image, and the
683 GENERIC and INSTALL kernels:<pre>
684 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/sgimipscd-3.1.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/sgimipscd-3.1.iso</a>
685 <a href="ftp://ftp.NetBSD.org/pub/NetBSD/NetBSD-3.1/sgimips/binary/kernel/netbsd-GENERIC32_IP3x.gz">ftp://ftp.NetBSD.org/pub/NetBSD/NetBSD-3.1/sgimips/binary/kernel/netbsd-GENERIC32_IP3x.gz</a>
686 <a href="ftp://ftp.NetBSD.org/pub/NetBSD/NetBSD-3.1/sgimips/binary/kernel/netbsd-INSTALL32_IP3x.gz">ftp://ftp.NetBSD.org/pub/NetBSD/NetBSD-3.1/sgimips/binary/kernel/netbsd-INSTALL32_IP3x.gz</a>
687
688 </pre>
689 <li>Start the DECstation emulation again:<pre>
690 <b>gxemul -e 3max -d nbsd_pmax.img -d sgimipscd-3.1.iso</b>
691
692 </pre>and extract the files from the sgimips CD-ROM image to the
693 DECstation disk image:
694 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
695 <b>cd /tftpboot; mount /dev/cd0a /mnt
696 for a in /mnt/*/binary/sets/[bcegmt]*; do echo $a; tar zxfp $a; done
697 echo 10.0.0.2:/tftpboot / nfs rw 0 0 &gt; /tftpboot/etc/fstab
698 echo rc_configured=YES &gt;&gt; /tftpboot/etc/rc.conf
699 echo 10.0.0.254 &gt;&gt; /tftpboot/etc/mygate
700 echo nameserver 10.0.0.254 &gt;&gt; /tftpboot/etc/resolv.conf
701 echo rc_configured=YES &gt;&gt; /tftpboot/etc/rc.conf
702 dd if=/dev/zero of=swap bs=1024 count=65536
703 cd /; umount /mnt; halt</b>
704 </pre></td></tr></table>
705 <p>
706 <li>Create a configuration file called <tt>config_client</tt>:
707 <table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
708 <font color="#2020cf">! Configuration file for running NetBSD/sgimips diskless with
709 ! a NetBSD/pmax machine as the nfs server.</font>
710
711 <b>net(
712 add_remote("localhost:12444") </b>! the server<b>
713 local_port(12445) </b>! the client<b>
714 )
715
716 machine(
717 name("client machine")
718 serial_nr(1)
719
720 type("sgi")
721 subtype("o2")
722
723 load("netbsd-INSTALL32_IP3x.gz")</b>
724 ! load("netbsd-GENERIC32_IP3x.gz")<b>
725 )
726 </b>
727 </pre></td></tr></table>
728 ... and another configuration file for the server,
729 <tt>config_server</tt>:
730 <table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
731 <b>net(
732 local_port(12444) </b>! the server<b>
733 add_remote("localhost:12445") </b>! the client<b>
734 )
735
736 machine(
737 name("nfs server")
738 serial_nr(2)
739
740 type("dec")
741 subtype("5000/200")
742
743 disk("nbsd_pmax.img")
744 )
745 </b>
746 </pre></td></tr></table>
747 <li>Boot the "<tt>nfs server</tt>" and the NetBSD/sgimips
748 "<tt>client machine</tt>" as two separate emulator instances:<pre>
749 in one xterm:
750 <b>gxemul @config_server</b>
751
752 and then, in another xterm:
753 <b>gxemul @config_client</b>
754
755 </pre>
756 <li>In the NetBSD/sgimips window, choose "<tt>x: Exit Install System</tt>"
757 in the installer's main menu, and then type:<pre>
758 <b>ifconfig mec0 10.0.0.1; route add default 10.0.0.254</b>
759 <b>mount -v 10.0.0.2:/tftpboot /mnt</b>
760 <b>cd /mnt/dev; ./MAKEDEV all; cd /; umount /mnt</b>
761 <b>halt</b>
762 </pre>Then, once the client machine has halted, log in as <tt>root</tt>
763 on the server machine and type <tt><b>reboot</b></tt>.
764 <p>
765 <li>Once everything has been set up correctly, change
766 <tt>netbsd-INSTALL32_IP3x.gz</tt> in <tt>config_client</tt> to
767 <tt>netbsd-GENERIC32_IP3x.gz</tt> (the GENERIC kernel).
768 </ol>
769
770 <p>You might want to log in as <tt>root</tt> on the server machine, and
771 run <tt>tcpdump -lnvv</tt> or similar, to see that what the client machine
772 actually does on the network.
773
774 <p>It should now be possible to boot NetBSD/sgimips using the NetBSD/pmax
775 nfs server, using the following commands: (NOTE! Execute these two
776 commands in separate xterms!)<pre>
777 <b>gxemul @config_server</b>
778 <b>gxemul @config_client</b>
779 </pre>
780
781 <p>When asked for "<tt>root device:</tt>" etc. on the client machine, enter
782 the following values:<pre>
783 root device: <b>mec0</b>
784 dump device: <b>(leave blank)</b>
785 file system (default generic): <b>(leave blank)</b>
786 ..
787 init path (default /sbin/init): <b>(leave blank)</b>
788 Enter pathname of shell or RETURN for /bin/sh: <b>(leave blank)</b>
789 Terminal type? [unknown] <b>xterm</b>
790 ..
791 # <b>exit</b> (to leave the single-user shell)
792 </pre>
793
794 <p>Note: Netbooting like this is very slow, so you need a lot of patience.
795 For example, when NetBSD says "<tt>nfs_boot: trying DHCP/BOOTP</tt>",
796 there will be a long pause, even on a very fast host machine. The reason
797 for this is mostly because the emulator doesn't deal with timing issues
798 very well, but also because NetBSD tries IPv6 first, before falling back
799 to IPv4.
800
801
802
803
804
805
806 <p><br>
807 <a name="netbsdcatsinstall"></a>
808 <h3>NetBSD/cats:</h3>
809
810 It is possible to install and run
811 <a href="http://www.netbsd.org/ports/cats/">NetBSD/cats</a> in GXemul.
812
813 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
814 <a href="20051007-netbsd-cats-installed.png"><img src="20051007-netbsd-cats-installed_small.png"></a>
815
816 <p>
817 To install NetBSD/cats onto a disk image, follow these instructions:
818
819 <p>
820 <ol start="1">
821 <li>Create an empty harddisk image, which will be the root disk
822 that you will install NetBSD/cats onto:<pre>
823 <b>dd if=/dev/zero of=nbsd_cats.img bs=1024 count=1 seek=3000000</b>
824
825 </pre>
826 <li>Download the NetBSD/cats 3.1 ISO image and the generic and install kernels:<pre>
827 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/catscd-3.1.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/catscd-3.1.iso</a>
828 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/cats/binary/kernel/netbsd.aout-GENERIC.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/cats/binary/kernel/netbsd.aout-GENERIC.gz</a>
829 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/cats/binary/kernel/netbsd.aout-INSTALL.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/cats/binary/kernel/netbsd.aout-INSTALL.gz</a>
830
831 </pre>
832 <p>
833 <li>Start the installation like this:<pre>
834 <b>gxemul -XEcats -d nbsd_cats.img -d catscd-3.1.iso netbsd.aout-INSTALL.gz</b>
835
836 </pre>
837 and proceed like you would do if you were installing NetBSD on a real
838 CATS from CDROM.
839 </ol>
840
841 <p>Alternatively, to install from FTP, you can skip downloading the ISO,
842 and start the install without <tt>-d catscd-3.1.iso</tt>. Suitable network
843 settings are IP 10.0.0.1, gateway/default route 10.0.0.254, netmask
844 255.0.0.0, nameserver 10.0.0.254.
845
846 <p>If everything worked, NetBSD should now be installed on the disk image.
847 Use the following command line to boot the emulated CATS machine:<pre>
848 <b>gxemul -XEcats -d nbsd_cats.img netbsd.aout-GENERIC.gz</b>
849
850 </pre>
851
852
853
854
855
856
857
858 <p><br>
859 <a name="netbsdevbarminstall"></a>
860 <h3>NetBSD/evbarm:</h3>
861
862 <a href="http://www.netbsd.org/ports/evbarm/">NetBSD/evbarm</a> can
863 run in GXemul on an emulated IQ80321 evaluation board.
864
865 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
866 <a href="20060218-netbsd-evbarm.png"><img src="20060218-netbsd-evbarm_small.png"></a>
867
868 <p>It is tricky to install, because there is (as far as I know) no INSTALL
869 kernel. One way to install the NetBSD/evbarm distribution onto a disk
870 image is to install the files using another (emulated) machine.
871
872 <p>The following instructions will let you install NetBSD/evbarm onto a disk
873 image, from an emulated CATS machine:
874
875 <p>
876 <ol>
877 <li>Download a NetBSD/cats 3.1 ramdisk kernel:<pre>
878 <b>wget <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/cats/binary/kernel/netbsd.aout-INSTALL.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/cats/binary/kernel/netbsd.aout-INSTALL.gz</a></b>
879
880 </pre>
881 <li>Create an empty harddisk image, which will be the disk image
882 that you will install NetBSD/evbarm onto:<pre>
883 <b>dd if=/dev/zero of=nbsd_iq80321.img bs=1024 count=1 seek=999000</b>
884
885 </pre>
886 <li>Download an IQ80321 kernel with wdc support, and the 2.1 ISO image:<pre>
887 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-2.1/evbarm/binary/kernel/">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-2.1/evbarm/binary/kernel</a>/<a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-2.1/evbarm/binary/kernel/netbsd-wd0-IQ80321.gz">netbsd-wd0-IQ80321.gz</a>
888 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/2.1/evbarmcd.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/2.1/evbarmcd.iso</a>
889
890 </pre>
891 <p>
892 <li>Now let's extract the files from the CD-ROM image onto the IQ80321's disk image. Start the
893 CATS machine using the following command line:<pre>
894 <b>gxemul -XEcats -d nbsd_iq80321.img -d evbarmcd.iso netbsd.aout-INSTALL.gz</b>
895
896 </pre>Exit from the installer, and execute the following commands as <tt>root</tt>:
897 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
898
899 <b>disklabel -I -i wd0</b>
900 (enter suitable commands, e.g. <i>a, 4.2BSD, 1c, 750M, b,
901 swap, a, 200M, P, W, y, Q</i>)
902 <b>newfs /dev/wd0a; mount /dev/wd0a /mnt2; cd /mnt2
903 mount /dev/cd0a /mnt; sh
904 for a in /mnt/*/binary/sets/[bcegmt]*.tgz; do echo $a; tar zxfp $a; done
905 exit
906 cd dev; sh ./MAKEDEV all; cd ../etc
907 echo rc_configured=YES &gt;&gt; rc.conf
908 echo "/dev/wd0a / ffs rw 1 1" &gt; fstab
909 echo "/dev/wd0b none swap sw 0 0" &gt;&gt; fstab
910 cd /; umount /mnt; umount /mnt2; sync; halt</b>
911 </pre></td></tr></table>
912 </ol>
913
914 <p>You should now be able to boot NetBSD/evbarm using this command:<pre>
915 <b>gxemul -x -E iq80321 -d nbsd_iq80321.img netbsd-wd0-IQ80321.gz</b>
916 </pre>
917
918
919
920
921
922
923
924
925
926 <p><br>
927 <a name="netbsdnetwinderinstall"></a>
928 <h3>NetBSD/netwinder:</h3>
929
930 It is possible to run <a
931 href="http://www.netbsd.org/ports/netwinder/">NetBSD/netwinder</a>
932 in GXemul.
933
934 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
935 <a href="20060724-netbsd-netwinder-1.png"><img src="20060724-netbsd-netwinder-1_small.png"></a>
936 &nbsp;&nbsp;&nbsp;<a href="20060724-netbsd-netwinder-2.png"><img src="20060724-netbsd-netwinder-2_small.png"></a>
937
938 <p>There is no INSTALL ramdisk kernel, so one way to install the
939 NetBSD/netwinder distribution onto a disk image is to install the files
940 using another (emulated) machine. The following instructions will let you
941 install the NetBSD/netwinder distribution onto a disk image, from an
942 emulated DECstation 3MAX machine:
943
944 <p>
945 <ol>
946 <li>Download a NetBSD/pmax (DECstation) install RAMDISK kernel:<pre>
947 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/pmax/binary/kernel/netbsd-INSTALL.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/pmax/binary/kernel/netbsd-INSTALL.gz</a>
948 </pre>
949 <p>
950 <li>Create an empty harddisk image, which will be the disk image
951 that you will install NetBSD onto:<pre>
952 <b>dd if=/dev/zero of=nbsd_netwinder.img bs=1024 count=1 seek=999000</b>
953
954 </pre>
955 <li>Download the generic kernel and the 3.1 ISO image:<pre>
956 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/netwinder/binary/kernel/netbsd-GENERIC.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/netwinder/binary/kernel/netbsd-GENERIC.gz</a>
957 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/netwindercd-3.1.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/netwindercd-3.1.iso</a>
958
959 </pre>
960 <p>
961 <li>Start the emulated DECstation machine like this:<pre>
962 <b>gxemul -e 3max -d nbsd_netwinder.img -d netwindercd-3.1.iso netbsd-INSTALL.gz</b>
963
964 </pre>
965 <li>At the <tt>Terminal type? [rcons]</tt> prompt, type <b>CTRL-B</b>
966 to simulate a CTRL-C sent to NetBSD/pmax. Then execute the following commands:
967 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
968 <b>newfs /dev/sd0c
969 mount /dev/cd0c /mnt
970 mkdir /mnt2; mount /dev/sd0c /mnt2
971 cd /mnt2; sh
972 for a in /mnt/*/binary/sets/*.tgz; do echo $a; tar zxfp $a; done
973 exit
974 cd dev; sh ./MAKEDEV all; cd ../etc
975 echo rc_configured=YES >> rc.conf
976 echo "/dev/wd0c / ffs rw 1 1" > fstab
977 cd /; umount /mnt; umount /mnt2; halt</b>
978 </pre></td></tr></table>
979 </ol>
980
981 <p>NetBSD/netwinder is now installed on the disk image. The following command
982 line can be used to start NetBSD/netwinder:<pre>
983 <b>gxemul -X -E netwinder -d nbsd_netwinder.img netbsd-GENERIC.gz</b>
984 </pre>
985
986 <p>This will result in a 1024x768 framebuffer. Add <tt>-Y2</tt> to the
987 command line if you want to scale it down to 512x384.
988
989 <p>Note: The installation instructions above create a filesystem
990 <i>without</i> a disklabel, so there is only one ffs partition and no
991 swap. You will need to enter the following things when booting with the
992 generic kernel:<pre>
993 root device (default wd0a): <b>wd0c</b>
994 dump device (default wd0b): <i>(just press enter)</i>
995 file system (default generic): <i>(just press enter)</i>
996 init path (default /sbin/init): <i>(just press enter)</i>
997 </pre>
998
999 <p>Known bugs/problems:
1000
1001 <ul>
1002 <li>There is a long delay when starting up NetBSD/netwinder
1003 (several seconds even on a very fast host machine),
1004 so you need to be patient.
1005 <li>There is a minor bug in the keyboard device, so you need to
1006 press a key (any key) before typing wd0c.
1007 <li>When halting/rebooting NetBSD/netwinder, the emulator
1008 prints a message saying something about an internal
1009 error. This doesn't matter; ignore the message.
1010 </ul>
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023 <p><br>
1024 <a name="netbsdprepinstall"></a>
1025 <h3>NetBSD/prep:</h3>
1026
1027 It is possible to install and run <a
1028 href="http://www.netbsd.org/ports/prep/">NetBSD/prep</a> 2.1 in GXemul on
1029 an emulated IBM 6050 (PowerPC) machine. (Newer versions of NetBSD/prep use
1030 the wdc controller in a way which isn't implemented in GXemul yet, or
1031 there are bugs in GXemul's PowerPC CPU emulation.)
1032
1033 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1034 <a href="20051123-netbsd-prep.png"><img src="20051123-netbsd-prep_small.png"></a>
1035
1036 <p>To install NetBSD/prep onto a disk image, follow these instructions:
1037
1038 <p>
1039 <ol start="1">
1040 <li>Create an empty harddisk image, which will be the root disk
1041 that you will install NetBSD/prep onto:<pre>
1042 <b>dd if=/dev/zero of=nbsd_prep.img bs=1024 count=1 seek=1000000</b>
1043
1044 </pre>
1045 <li>Download the NetBSD/prep 2.1 ISO image and the generic kernel:<pre>
1046 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/2.1/prepcd.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/2.1/prepcd.iso</a>
1047 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-2.1/prep/binary/kernel/netbsd-GENERIC.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-2.1/prep/binary/kernel/netbsd-GENERIC.gz</a>
1048
1049 </pre>
1050 <p>
1051 <li>Start the installation like this:<pre>
1052 <b>gxemul -X -e ibm6050 -d nbsd_prep.img -d rdb:prepcd.iso -j prep/binary/kernel/netbsd-INSTALL.gz</b>
1053
1054 </pre>
1055 <p>
1056 <li>Installation is a bit unsmooth, possibly due to bugs in GXemul,
1057 possibly due to bugs in NetBSD itself; others have been having
1058 problems on real hardware: <a href="http://mail-index.NetBSD.org/port-prep/2005/11/25/0004.html">http://mail-index.NetBSD.org/port-prep/2005/11/25/0004.html</a>.
1059 Creating an MBR slice and a disklabel with sysinst bugs out, so
1060 some things have to be done manually:<p>
1061 At "<tt>(I)nstall, (S)hell, or (H)alt</tt>", choose
1062 <tt><b><u>s</u></b></tt>.
1063 <br><tt># <b><u>fdisk -u wd0</u></b></tt>
1064 <br><tt>Do you want to change our idea of what BIOS thinks? [n]</tt>
1065 (just press <b>ENTER</b>)
1066 <br><tt>Which partition do you want to change?: [none] <b><u>0</u></b></tt>
1067 <br><tt>sysid: ... </tt> (just press <B>ENTER</b>)
1068 <br><tt>start: ... <b><u>1cyl</u></b></tt>
1069 <br><tt>size: ... </tt> (just press <B>ENTER</b>)
1070 <br><tt>Which partition do you want to change?: [none]</tt> (press <b>ENTER</b>)
1071 <br><tt>Should we write new partition table? [n] <b><u>y</u></b></tt>
1072 <br><tt># <b><u>disklabel -I -i wd0</u></b></tt>
1073 <br><tt>partition&gt; <b><u>a</u></b></tt>
1074 <br><tt>Filesystem type [?] [unused]: <b><u>4.2BSD</u></b></tt>
1075 <br><tt>Start offset ('x' to start after partition 'x') [0c, 0s, 0M]: <b><u>1c</u></b></tt>
1076 <br><tt>Partition size ('$' for all remaining) [0c, 0s, 0M]: <b><u>900M</u></b></tt>
1077 <br><tt>partition&gt; <b><u>b</u></b></tt>
1078 <br><tt>Filesystem type [?] [unused]: <b><u>swap</u></b></tt>
1079 <br><tt>Start offset ('x' to start after partition 'x') [0c, 0s, 0M]: <b><u>a</u></b></tt>
1080 <br><tt>Partition size ('$' for all remaining) [0c, 0s, 0M]: <b><u>$</u></b></tt>
1081 <br><tt>partition&gt; <b><u>W</u></b></tt>
1082 <br><tt>Label disk [n]? <b><u>y</u></b></tt>
1083 <br><tt>partition&gt; <b><u>Q</u></b></tt>
1084 <br><tt># <b><u>newfs wd0a</u></b></tt>
1085 <br><tt># <b><u>sysinst</u></b></tt>
1086 <br>Choose to install onto <b>wd0</b>. Choose
1087 "<tt>a: Edit the MBR partition table</tt>"
1088 when presented with that option.
1089 <br>Choose the 'a' partition/slice,
1090 set the 'e' ("active") and 'f' ("install") fields to <b>Yes</b>,
1091 and then choose "<tt>x: Partition table OK</tt>".
1092 <br>Choose "<tt>b: Use existing partition sizes</tt>" in the next
1093 menu.
1094 <br>Select partition 'a' and press ENTER. Set field 'k' (mount point)
1095 to '<tt><b>/</b></tt>'.
1096 <br>Get out of the partitioner by selecting
1097 "<tt>x: Partition sizes ok</tt>" twice.
1098 <br>At "<tt>Write outside MBR partition? [n]:</tt>", just press
1099 <b>ENTER</b>.
1100 <br>Install from CD-ROM, device <b>wd1c</b>.
1101 </ol>
1102
1103 <p>If everything worked, NetBSD should now be installed on the disk image.
1104 Use the following command line to boot the emulated machine:<pre>
1105 <b>gxemul -X -e ibm6050 -d nbsd_prep.img netbsd-GENERIC.gz</b>
1106
1107 </pre>
1108
1109 <p>When asked which the root device is, type <tt><b>wd0</b></tt> and
1110 just press ENTER to select the default values for dump device, file
1111 system type, and init path.
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124 <p><br>
1125 <a name="netbsdmacppcinstall"></a>
1126 <h3>NetBSD/macppc:</h3>
1127
1128 It is possible to install and run <a
1129 href="http://www.netbsd.org/ports/macppc/">NetBSD/macppc</a> in GXemul on
1130 an emulated generic PowerPC machine. No specific Machintosh model is
1131 emulated, but it is enough to for NetBSD to recognize it.
1132
1133 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1134 <a href="20070318-netbsd-macppc.png"><img src="20070318-netbsd-macppc_small.png"></a>
1135
1136 <p>To install NetBSD/macppc onto a disk image, follow these instructions:
1137
1138 <p>
1139 <ol start="1">
1140 <li>Create an empty harddisk image, which will be the root disk
1141 that you will install NetBSD/macppc onto:<pre>
1142 <b>dd if=/dev/zero of=nbsd_macppc.img bs=1024 count=1 seek=3000000</b>
1143
1144 </pre>
1145 <li>Download the NetBSD/macppc 3.1 ISO image and a generic kernel:<pre>
1146 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/macppccd-3.1.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/macppccd-3.1.iso</a>
1147 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/macppc/binary/kernel/">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/macppc/binary/kernel</a>/<a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/macppc/binary/kernel/netbsd-GENERIC.MP.gz">netbsd-GENERIC.MP.gz</a>
1148
1149 </pre>
1150 <p>
1151 <li>Start the installation like this:<pre>
1152 <b>gxemul -x -e g4 -d nbsd_macppc.img -d b:macppccd-3.1.iso -j macppc/binary/kernel/netbsd-INSTALL.gz</b>
1153
1154 </pre>
1155 and continue as you would do when installing NetBSD on a real
1156 machine.
1157 <p>
1158 <li>Before turning the emulated machine off, quit the NetBSD installer
1159 and execute the following commands:<pre>
1160 <b>cd /; mount /dev/wd0a /mnt
1161 echo 'console "/usr/libexec/getty std.38400" vt100 on secure' > /mnt/etc/ttys
1162 echo 'rc_configured=YES' >> /mnt/etc/rc.conf
1163 umount /mnt; sync
1164 reboot</b>
1165
1166 </pre>
1167 </ol>
1168
1169 <p>If everything worked, NetBSD/macppc should now be installed on
1170 the disk image.
1171
1172 <p>Use the following command line to boot the emulated machine:<pre>
1173 <b>gxemul -x -e g4 -d nbsd_macppc.img netbsd-GENERIC.MP.gz</b>
1174
1175 </pre>
1176
1177 <p>If asked about <tt>root device</tt>, enter <tt><b>wd0</b></tt>.
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189 <p><br>
1190 <a name="netbsdpmppc"></a>
1191 <h3>NetBSD/pmppc:</h3>
1192
1193 <p><a href="http://www.netbsd.org/ports/pmppc/">NetBSD/pmppc</a> can
1194 run in GXemul on an emulated Artesyn PM/PPC board. Currently, no SCSI or other
1195 disk controller is emulated for this machine type, but it is possible to run
1196 NetBSD with root-on-nfs.
1197
1198 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1199 <a href="20070616-netbsd-pmppc-diskless.png"><img src="20070616-netbsd-pmppc-diskless_small.png"></a>
1200
1201 <p>These setup steps will let you run NetBSD/pmppc with root-on-nfs:
1202
1203 <p>
1204 <ol>
1205 <li>First of all, the "<tt>nfs server</tt>" machine must be set up.
1206 This needs to have a 750 MB <tt>/tftpboot</tt> partition.
1207 <a href="#netbsdpmaxinstall">Install NetBSD/pmax 3.1 from CDROM</a>.
1208 (Don't forget to add the extra partition!)
1209 <p>
1210 <li>Configure the nfs server machine to act as an nfs server.
1211 Start up the emulated DECstation:<pre>
1212 <b>gxemul -e 3max -d nbsd_pmax.img</b>
1213 </pre>and enter the following commands as <tt>root</tt>
1214 inside the emulator:
1215 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
1216 <b>echo hostname=server &gt;&gt; /etc/rc.conf
1217 echo ifconfig_le0=\"inet 10.0.0.2\" &gt;&gt; /etc/rc.conf
1218 echo nameserver 10.0.0.254 &gt;&gt; /etc/resolv.conf
1219 echo 10.0.0.254 &gt; /etc/mygate
1220 echo /tftpboot -maproot=root 10.0.0.1 &gt; /etc/exports
1221 echo rpcbind=YES &gt;&gt; /etc/rc.conf
1222 echo nfs_server=YES &gt;&gt; /etc/rc.conf
1223 echo mountd=YES &gt;&gt; /etc/rc.conf
1224 echo bootparamd=YES &gt;&gt; /etc/rc.conf
1225 printf "client root=10.0.0.2:/tftpboot \\\n swap=10.0.0.2:/tftpboot/swap\n" &gt; /etc/bootparams
1226 echo "bootps dgram udp wait root /usr/sbin/bootpd bootpd -d 4 -h 10.0.0.2" &gt;&gt; /etc/inetd.conf
1227 cat &gt;&gt; /etc/bootptab
1228 client:\
1229 :ht=ether:\
1230 :ha=102030000010:\
1231 :sm=255.0.0.0:\
1232 :lg=10.0.0.254:\
1233 :ip=10.0.0.1:\
1234 :rp=/tftpboot:
1235 </b>(press CTRL-D)
1236 <b>echo "10:20:30:00:00:10 client" &gt; /etc/ethers
1237 echo 10.0.0.1 client &gt; /etc/hosts
1238 reboot</b>
1239 </pre></td></tr></table>
1240 <p>
1241 <li>Download the NetBSD/pmppc CD-ROM iso image, and the GENERIC kernel:<pre>
1242 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/pmppccd-3.1.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/3.1/pmppccd-3.1.iso</a>
1243 <a href="ftp://ftp.NetBSD.org/pub/NetBSD/NetBSD-3.1/pmppc/binary/kernel/netbsd-PMPPC.gz">ftp://ftp.NetBSD.org/pub/NetBSD/NetBSD-3.1/pmppc/binary/kernel/netbsd-PMPPC.gz</a>
1244
1245 </pre>
1246 <li>Start the DECstation emulation again:<pre>
1247 <b>gxemul -e 3max -d nbsd_pmax.img -d pmppccd-3.1.iso</b>
1248
1249 </pre>and extract the files from the PM/PPC CD-ROM image to the
1250 DECstation disk image:
1251 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
1252 <b>cd /tftpboot; mount /dev/cd0a /mnt
1253 for a in /mnt/*/binary/sets/[bcemt]*; do echo $a; tar zxfp $a; done
1254 echo 10.0.0.2:/tftpboot / nfs rw 0 0 &gt; /tftpboot/etc/fstab
1255 echo rc_configured=YES &gt;&gt; /tftpboot/etc/rc.conf
1256 echo 10.0.0.254 &gt;&gt; /tftpboot/etc/mygate
1257 echo nameserver 10.0.0.254 &gt;&gt; /tftpboot/etc/resolv.conf
1258 echo rc_configured=YES &gt;&gt; /tftpboot/etc/rc.conf
1259 dd if=/dev/zero of=swap bs=1024 count=65536
1260 cd /tftpboot/dev; sh MAKEDEV all
1261 cd /; umount /mnt; halt</b>
1262 </pre></td></tr></table>
1263 <p>
1264 <li>Create a configuration file called <tt>config_client</tt>:
1265 <table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
1266 <font color="#2020cf">! Configuration file for running NetBSD/pmppc diskless with
1267 ! a NetBSD/pmax machine as the nfs server.</font>
1268
1269 <b>net(
1270 add_remote("localhost:12444") </b>! the server<b>
1271 local_port(12445) </b>! the client<b>
1272 )
1273
1274 machine(
1275 name("client machine")
1276 serial_nr(1)
1277
1278 type("pmppc")
1279
1280 load("netbsd-PMPPC.gz")</b>
1281 )
1282 </b>
1283 </pre></td></tr></table>
1284 ... and another configuration file for the server,
1285 <tt>config_server</tt>:
1286 <table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
1287 <b>net(
1288 local_port(12444) </b>! the server<b>
1289 add_remote("localhost:12445") </b>! the client<b>
1290 )
1291
1292 machine(
1293 name("nfs server")
1294 serial_nr(2)
1295
1296 type("dec")
1297 subtype("5000/200")
1298
1299 disk("nbsd_pmax.img")
1300 )
1301 </b>
1302 </pre></td></tr></table>
1303 </ol>
1304
1305 <p>It should now be possible to boot NetBSD/pmppc using the NetBSD/pmax
1306 nfs server, using the following commands: (NOTE! Execute these two
1307 commands in separate xterms!)<pre>
1308 <b>gxemul @config_server</b>
1309 <b>gxemul @config_client</b>
1310 </pre>
1311
1312 <p>You might want to log in as <tt>root</tt> on the server machine, and
1313 run <tt>tcpdump -lnvv</tt> or similar, to see that what the client machine
1314 actually does on the network.
1315
1316 <p>When asked for "<tt>root device:</tt>" etc. on the client machine, enter
1317 the following values:<pre>
1318 root device: <b>tlp0</b>
1319 dump device: <b>(leave blank)</b>
1320 file system (default generic): <b>(leave blank)</b>
1321 ..
1322 init path (default /sbin/init): <b>(leave blank)</b>
1323 </pre>
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333 <p><br>
1334 <a name="netbsddreamcast"></a>
1335 <h3>NetBSD/dreamcast:</h3>
1336
1337 Moved <a href="dreamcast.html#netbsd_generic_md">here</a>.
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347 <p><br>
1348 <a name="openbsdpmaxinstall"></a>
1349 <h3>OpenBSD/pmax:</h3>
1350
1351 Installing <a href="http://www.openbsd.org/pmax.html">OpenBSD/pmax</a> is
1352 a bit harder than installing NetBSD/pmax. You should first read the <a
1353 href="#netbsdpmaxinstall">section above</a> on how to install NetBSD/pmax,
1354 before continuing here. If you have never installed OpenBSD on any
1355 architecture, then you need a great deal of patience to do this. If, on
1356 the other hand you are used to installing OpenBSD, then this should be no
1357 problem for you.
1358
1359 <p>
1360 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1361 <a href="20040710-openbsd-pmax.png"><img src="20040710-openbsd-pmax_small.png"></a>
1362 &nbsp;&nbsp;&nbsp;
1363 <a href="openbsd-pmax-20040710.png"><img src="openbsd-pmax-20040710_small.png"></a>
1364
1365 <p>
1366 OpenBSD/pmax died at release 2.8 of OpenBSD, so you should be
1367 aware of the fact that this will not give you an up-to-date OpenBSD
1368 system.
1369
1370 <p>
1371 Following these instructions <i>might</i> work. If not, then use
1372 common sense and imagination to modify them as you see fit.
1373
1374 <p>
1375 <ol>
1376 <li>Create an empty harddisk image, which will be the root disk
1377 that OpenBSD installs itself onto:<pre>
1378 <b>dd if=/dev/zero of=obsd_pmax.img bs=1 count=512 seek=900000000</b>
1379
1380 </pre>
1381 <li>Download the entire pmax directory from the ftp server: (approx. 99 MB)<pre>
1382 <b>wget -r <a href="ftp://ftp.se.openbsd.org/pub/OpenBSD/2.8/pmax/">ftp://ftp.se.openbsd.org/pub/OpenBSD/2.8/pmax/</a></b>
1383
1384 </pre>
1385
1386 <li>Execute the following commands:
1387 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
1388 <b>mv ftp.se.openbsd.org/pub/OpenBSD/2.8/pmax/simpleroot28.fs.gz .
1389 gunzip simpleroot28.fs.gz
1390 chmod +w simpleroot28.fs</b> &lt;--- make sure
1391 </pre></td></tr></table>
1392 <li>You now need to make an ISO image of the entire directory you downloaded.
1393 (I recommend using <tt>mkisofs</tt> for that purpose. If you don't
1394 already have <tt>mkisofs</tt> installed on your system, you need
1395 to install it in order to do this.)<pre>
1396 <b>mkisofs -o openbsd_pmax_2.8.iso ftp.se.openbsd.org/pub/OpenBSD/2.8/pmax</b>
1397 <b>rm -rf ftp.se.openbsd.org</b> <i>(this directory is not needed anymore)</i>
1398
1399 </pre>
1400 <li>Start the emulator with all three (!) disk images:<pre>
1401 <b>gxemul -e 3max -d obsd_pmax.img -d b:simpleroot28.fs -j bsd -d c:openbsd_pmax_2.8.iso</b>
1402
1403 </pre>
1404 (If you add <tt>-X</tt>, you will run with the graphical
1405 framebuffer. This is <i>REALLY</i> slow because the console has to
1406 scroll a lot during the install. I don't recommend it.)
1407 <p>
1408 <li>Go on with the installation as you would do if you were installing on a real machine.
1409 If you are not used to the OpenBSD installer, then this will most likely
1410 be a very uncomfortable experience. Some important things to keep in mind are:
1411 <ul>
1412 <li>rz0 is the rootdisk you wish to install onto.
1413 <li>rz1 is the simpleroot image.
1414 <li>rz2 is the CDROM containing the "install sets".
1415 <li>When asked for the "<b>root device?</b>", enter <b>rz1</b>.
1416 <li>At "<b>Enter pathname of shell or RETURN for sh:</b>", press enter.
1417 <li>At the # prompt, do the following:<pre>
1418 <b>fsck /dev/rz1a</b> (and mark the filesystem as clean)
1419 <b>mount /dev/rz1a /</b>
1420 <b>mkdir /kern</b>
1421 <b>mkdir /mnt2</b>
1422 <b>mount -t kernfs kern kern</b>
1423 <b>./install</b>
1424
1425 </pre>
1426 and proceed with the install. Good luck. :-)
1427 <li>Answer "<b>y</b>" when asked if you wish to configure the network.
1428 (See the section about installing NetBSD/pmax for suitable
1429 network settings.)
1430 <li>Install from "<b>c</b>" (cdrom), choose "<b>rz2</b>" as the cdrom device, and "<b>/</b>" as
1431 the directory containing the install sets.
1432 </ul>
1433 <p>
1434 <li>For some unknown reason, the install script does not set the root
1435 password! The first time you boot up OpenBSD after the install, you
1436 need to go into single user mode and run <b>passwd root</b> to set
1437 the root password, or you will not be able to log in at all!<pre>
1438 <b>gxemul -e 3max -d obsd_pmax.img -d 2c:openbsd_pmax_2.8.iso -j bsd -o '-s'</b>
1439 </pre>
1440 While you are at it, you might want to extract the X11 install sets
1441 as well, as the installer seems to ignore them too. (Perhaps due to a bug
1442 in the installer, perhaps because of the way I used mkisofs.)
1443 <p>
1444 Execute the following commands in the emulator:
1445 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
1446 <b>fsck /dev/rz0a
1447 mount /
1448 passwd root
1449
1450 cd /; mount -t cd9660 /dev/rz2c /mnt; sh
1451 for a in /mnt/[xX]*; do tar zxvf $a; done
1452 ln -s /usr/X11R6/bin/Xcfbpmax /usr/X11R6/bin/X
1453 ln -s /dev/fb0 /dev/mouse
1454 echo /usr/X11R6/lib &gt;&gt; /etc/ld.so.conf
1455 ldconfig
1456
1457 sync
1458 halt</b>
1459 </pre></td></tr></table>
1460 </ol>
1461
1462 <p>
1463 NOTE: It is also possible to install via ftp instead of using a CDROM image.
1464 This is not much less awkward, you still need the simpleroot filesystem
1465 image, and you still have to manually add the X11 install sets and set the
1466 root password, and so on.
1467
1468 <p>
1469 Once you have completed the installation procedure, the following command
1470 will let you boot from the new rootdisk image:
1471 <pre>
1472 <b>gxemul -e 3max -X -o '-aN' -d obsd_pmax.img -j bsd</b>
1473 </pre>
1474
1475 <p>
1476 (Normally, you would be asked about which root device to use (<tt>rz0</tt>),
1477 but using <b><tt>-o '-aN'</tt></b> supresses that.)
1478
1479 <p>
1480 When asked for which terminal type to use, when logging in as root,
1481 enter <b><tt>rcons</tt></b> if you are using the graphical framebuffer,
1482 <b><tt>vt100</tt></b> for text-mode.
1483 <br>Use <b><tt>startx</tt></b> to start X windows.
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493 <p><br>
1494 <a name="openbsdcatsinstall"></a>
1495 <h3>OpenBSD/cats:</h3>
1496
1497 It is possible to install and run
1498 <a href="http://www.openbsd.org/cats.html">OpenBSD/cats</a>
1499 in GXemul. Unfortunately, "The OpenBSD/cats port has been discontinued
1500 after the 4.0 release." according to
1501 <a href="http://www.openbsd.org/cats.html">http://www.openbsd.org/cats.html</a>,
1502 but 4.0 should run fine.
1503
1504 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1505 <a href="20051007-openbsd-cats-installed.png"><img src="20051007-openbsd-cats-installed_small.png"></a>
1506
1507 <p>To install OpenBSD/cats onto an emulated harddisk image,
1508 follow these instructions:
1509
1510 <p>
1511 <ol>
1512 <li>Create an empty harddisk image, which will be the root disk
1513 that OpenBSD installs itself onto:<pre>
1514 <b>dd if=/dev/zero of=obsd_cats.img bs=1024 count=1 seek=1900000</b>
1515
1516 </pre>
1517 <li>Download the entire cats directory from the ftp server:<pre>
1518 <b>wget -np -l 0 -r <a href="ftp://ftp.se.openbsd.org/pub/OpenBSD/4.0/cats/">ftp://ftp.se.openbsd.org/pub/OpenBSD/4.0/cats/</a></b>
1519 <b>cp ftp.se.openbsd.org/pub/OpenBSD/4.0/cats/bsd .</b>
1520 <b>cp ftp.se.openbsd.org/pub/OpenBSD/4.0/cats/bsd.rd .</b>
1521
1522 </pre>
1523 (Replace ftp.se.openbsd.org with a server closer to you, for
1524 increased download speed.)
1525 <p>
1526 <li>You now need to make an ISO image of the entire directory you downloaded.
1527 (I recommend using <tt>mkisofs</tt> for that purpose. If you don't
1528 already have <tt>mkisofs</tt> installed on your system, you need
1529 to install it in order to do this.)<pre>
1530 <b>mkisofs -allow-lowercase -o openbsd_cats_4.0.iso ftp.se.openbsd.org/pub/OpenBSD/</b>
1531 <b>rm -rf ftp.se.openbsd.org</b> <i>(this directory is not needed anymore)</i>
1532
1533 </pre>
1534 <li>Start the emulator using this command line:<pre>
1535 <b>gxemul -XEcats -d obsd_cats.img -d openbsd_cats_4.0.iso bsd.rd</b>
1536
1537 </pre>
1538 and proceed like you would do if you were installing OpenBSD
1539 on a real CATS. (Install onto <tt>wd0</tt>, don't configure the
1540 network, install from CD.)
1541 </ol>
1542
1543 <p>(Although it <i>is</i> possible to configure the network, IPv4 address
1544 10.0.0.1, netmask 255.0.0.0, gateway/default route 10.0.0.254, and
1545 nameserver 10.0.0.254, the userland NAT-like networking layer is not
1546 stable enough yet to support a full install via ftp.)
1547
1548 <p><b>NOTE:</b> Make sure that you <tt>sync</tt> and <tt>reboot</tt>
1549 correctly once the installation is finished, or the <tt>/dev</tt> nodes
1550 may not have been written correctly to disk.
1551
1552 <p>Once the install has finished, the following command should let you
1553 boot from the harddisk image:
1554
1555 <p><pre>
1556 <b>gxemul -XEcats -d obsd_cats.img bsd</b>
1557
1558 </pre>
1559
1560
1561
1562
1563
1564
1565
1566 <p><br>
1567 <a name="openbsdlandiskinstall"></a>
1568 <h3>OpenBSD/landisk:</h3>
1569
1570 It is possible to install and run
1571 <a href="http://www.openbsd.org/landisk.html">OpenBSD/landisk</a>
1572 in GXemul.
1573
1574 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1575 <a href="20070419-openbsd-landisk.png"><img src="20070419-openbsd-landisk_small.png"></a>
1576
1577 <p>To install OpenBSD/landisk onto an emulated harddisk image,
1578 follow these instructions:
1579
1580 <p>
1581 <ol>
1582 <li>Create an empty harddisk image, which will be the root disk
1583 that OpenBSD installs itself onto:<pre>
1584 <b>dd if=/dev/zero of=obsd_landisk.img bs=1024 count=1 seek=2000000</b>
1585
1586 </pre>
1587 <li>Download the entire landisk directory from the ftp server:<pre>
1588 <b>wget -np -l 0 -r <a href="ftp://ftp.se.openbsd.org/pub/OpenBSD/4.1/landisk/">ftp://ftp.se.openbsd.org/pub/OpenBSD/4.1/landisk/</a></b>
1589 <b>cp ftp.se.openbsd.org/pub/OpenBSD/4.1/landisk/bsd .</b>
1590 <b>cp ftp.se.openbsd.org/pub/OpenBSD/4.1/landisk/bsd.rd .</b>
1591
1592 </pre>
1593 (Replace ftp.se.openbsd.org with a server closer to you, for
1594 increased download speed.)
1595 <p>
1596 <li>You now need to make an ISO image of the entire directory you downloaded.
1597 (I recommend using <tt>mkisofs</tt> for that purpose. If you don't
1598 already have <tt>mkisofs</tt> installed on your system, you need
1599 to install it in order to do this.)<pre>
1600 <b>mkisofs -U -o openbsd_landisk_4.1.iso ftp.se.openbsd.org/pub/OpenBSD/</b>
1601 <b>rm -rf ftp.se.openbsd.org</b> <i>(this directory is not needed anymore)</i>
1602
1603 </pre>
1604 <li>Start the emulator using this command line:<pre>
1605 <b>gxemul -x -E landisk -d obsd_landisk.img -d d:openbsd_landisk_4.1.iso bsd.rd</b>
1606
1607 </pre>
1608 and proceed like you would do if you were installing OpenBSD
1609 on a real landisk. The following hints are useful to get you
1610 through the installation:
1611 <ul>
1612 <li>Terminal type = <b>xterm</b>
1613 <li>root disk = <b>wd0</b> (the disk to install onto)
1614 <li>Use the entire disk for OpenBSD = <b>yes</b>
1615 <li>Create one big root partition (a) and a small swap partition (b). c is the entire disk.
1616 <li>Do <b>not</b> configure the network. (The Realtek NIC
1617 found in the Landisk machine is not implemented yet
1618 in the emulator.)
1619 <li>Location of sets = <b>disk</b>
1620 <li>Is the disk partition already mounted = <b>no</b>
1621 <li>Disk containing the install media = <b>wd1</b>
1622 <li>Pathname to the sets = <b>4.1/landisk</b>
1623 </ul>
1624 </ol>
1625
1626 <p>Once the install has finished, the following command should let you
1627 boot from the disk image:
1628
1629 <p><pre>
1630 <b>gxemul -x -E landisk -d obsd_landisk.img bsd</b>
1631
1632 </pre>
1633
1634 <p>As with most emulation modes in GXemul, the NIC in this machine is
1635 not emulated yet. If you want to transfer files to/from the emulated
1636 landisk machine, see
1637 <a href="misc.html#filexfer">this chapter</a> in the documentation.
1638
1639
1640
1641
1642
1643
1644
1645 <p><br>
1646 <a name="ultrixinstall"></a>
1647 <h3>Ultrix/RISC:</h3>
1648
1649 Ultrix 4.x can run in GXemul on an emulated DECstation 5000/200.
1650 (Ultrix was the native OS for these machines, but
1651 <a href="#netbsdpmaxinstall">NetBSD/pmax</a> is also usable.)
1652
1653 <p>
1654 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1655 <a href="20040504-ultrix45-boot1.png"><img src="20040504-ultrix45-boot1_small.png"></a>
1656 &nbsp;&nbsp;&nbsp;
1657 <a href="ultrix4.5-20040706.png"><img src="ultrix4.5-20040706_small.png"></a>
1658
1659 <p>
1660 The following instructions should let you install Ultrix onto a disk image:
1661
1662 <ol>
1663 <li>Create an empty harddisk image, which will be the root disk
1664 that Ultrix installs itself onto:<pre>
1665 <b>dd if=/dev/zero of=rootdisk.img bs=1024 count=1 seek=800000</b>
1666
1667 </pre>
1668 <li>Place your Ultrix installation media in your CDROM drive.
1669 (On FreeBSD and similar systems, it is called <tt>/dev/cd0c</tt>.
1670 Replace that with the name of your CDROM drive, or the name of a
1671 .iso image file.) Then, start the emulator like this:<pre>
1672 <b>gxemul -X -e 3max -d rootdisk.img -d bc:/dev/cd0c -j vmunix</b>
1673
1674 </pre>
1675 <li>Once the first stage of the installation is done (restoring the root
1676 filesystem), you need to restart the emulator, booting from the
1677 new rootdisk, to continue the installation process.
1678 This is done by removing the bootflag ('<tt>b</tt>') from the second
1679 diskimage argument:<pre>
1680 <b>gxemul -X -e 3max -d rootdisk.img -d c:/dev/cd0c -j vmunix</b>
1681
1682 </pre>
1683 </ol>
1684
1685 <p>
1686 When the installation is completed, the following command should start
1687 Ultrix from the harddisk image:<pre>
1688 <b>gxemul -X -e 3max -j vmunix -d rootdisk.img</b>
1689 </pre>
1690
1691 <p>If you have a very fast host machine, you might experience a weird
1692 timer related bug, which makes it impossible to logon to the system. It is
1693 triggered when the emulation goes faster than any real DECstation machine
1694 was capable of running. A temporary workaround is to add
1695 <b><tt>-I33000000</tt></b> to fix the emulated clock speed to 33 million
1696 instructions per emulated second.
1697
1698 <p>If the workaround above doesn't work, you can also start up other
1699 processes on the host, apart from the emulator, so that the emulator runs
1700 more slowly. This is an ugly workaround, but seems to work. Once you have
1701 logged in into Ultrix, you can kill the extra processes.
1702
1703 <p>You can experiment with adding <b><tt>-Z2</tt></b> (for emulating a
1704 dual-headed workstation) or even <b><tt>-Z3</tt></b> (tripple-headed), and
1705 also the <b><tt>-Y2</tt></b> option for scaling down the framebuffer
1706 windows by a factor 2x2.
1707 There is also a <b><tt>-z</tt></b> option for supplying names of X11
1708 displays to use. The following example starts Ultrix on an emulated
1709 tripple-headed workstation, on three different displays (<tt>remote1:0.0</tt>,
1710 <tt>localhost:0.0</tt>, and <tt>remote2:0.0</tt>), using no scaledown:<pre>
1711 <b>gxemul -N -e 3max -jgenvmunix -d rootdisk.img \
1712 -XZ3 -z remote1:0.0 -z localhost:0.0 -z remote2:0.0</b>
1713 </pre>
1714
1715 <p>The photo below shows a single Ultrix session running tripple-headed in
1716 GXemul on an Alpha 21164PC, with displays on a Sun Ultra1 (to the left),
1717 on the Alpha itself (in the middle), and on an HP700/RX X-terminal (8-bit
1718 color depth, running off the Alpha) to the right.
1719
1720 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1721 <a href="20041209-ultrix-tripplehead.jpg"><img src="20041209-ultrix-tripplehead_small.jpg"></a>
1722
1723 <p>The X11 displays may differ in bit depth and endianness. Unfortunately,
1724 there is no way yet to set the scaledown factor on a per-window basis, so
1725 the scaledown factor affects all windows.
1726
1727 <p>(If you didn't use <tt><b>-Z<i>n</i></b></tt> during the installation, and
1728 compiled your own <tt>/vmunix</tt>, then it will not contain support for
1729 multiple graphics cards. To overcome this problem, use the generic kernel,
1730 <tt><b>-j genvmunix</b></tt>, whenever you are running the emulator with a
1731 different setup than the one you used when Ultrix was installed.)
1732
1733 <p>A note for the historically interested: OSF/1 for MIPS was quite similar
1734 to Ultrix, so that is possible to run as well. If you are unsuccessful
1735 in installing Ultrix or OSF/1 directly in the emulator, you can always
1736 install it on your real machine onto a real SCSI disk, and then copy the
1737 contents of that SCSI disk into a file (using <b><tt>dd(1)</tt></b>), and use
1738 that file as a disk image file in the emulator.
1739
1740
1741
1742
1743
1744
1745 <p><br>
1746 <a name="sprite"></a>
1747 <h3>Sprite for DECstation:</h3>
1748
1749 Sprite was a research operating system at the University of Berkeley.
1750 The Unix Heritage Society (TUHS, <a href="http://www.tuhs.org">www.tuhs.org</a>)
1751 has made available a copy of a Sprite harddisk image for a DECstation 5000/200.
1752 If you want to find out more about Sprite in general, read
1753 <a href="http://www.cs.berkeley.edu/projects/sprite/retrospective.html">
1754 http://www.cs.berkeley.edu/projects/sprite/retrospective.html</a>.
1755
1756 <p>
1757 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1758 <a href="20040711-sprite-1.png"><img src="20040711-sprite-1_small.png"></a>
1759 &nbsp;&nbsp;&nbsp;
1760 <a href="sprite-20040711.png"><img src="sprite-20040711_small.png"></a>
1761
1762 <p>
1763 The following instructions should let you run Sprite in the emulator:
1764
1765 <p>
1766 <ol>
1767 <li>Download the Sprite harddisk image:<pre>
1768 <a href="ftp://ftp.es.embnet.org/pub/misc/TUHS/other_os/Sprite/ds5000.bt">ftp://ftp.es.embnet.org/pub/misc/TUHS/other_os/Sprite/ds5000.bt</a>
1769 83973120 bytes, MD5 = ec84eeeb20fe77b758370d5e312e4a5e
1770
1771 </pre>
1772 <li>Start the emulator with the following command line:<pre>
1773 <b>gxemul -X -e 3max -M128 -d ds5000.bt -j vmsprite -o ''</b>
1774
1775 </pre>
1776 </ol>
1777
1778 <p>
1779 The first time you boot up with the disk image, you will be asked a number
1780 of questions regarding network settings. If you feel like entering correct
1781 values, then you should use the following:
1782 <p>
1783
1784 <pre>
1785 Your machine's Ethernet address: 10:20:30:00:00:10
1786 Your machine's IP: 10.0.0.1
1787 Subnet mask: 0xff000000
1788 Gateway's Ethernet address: 60:50:40:30:20:10
1789 Gateway's IP: 10.0.0.254
1790 </pre>
1791
1792 <p>
1793 Unfortunately, at the end of <a href="ftp://ftp.es.embnet.org/pub/misc/TUHS/other_os/Sprite/boot.txt">ftp://ftp.es.embnet.org/pub/misc/TUHS/other_os/Sprite/boot.txt</a>,
1794 the following sad statement can be found:
1795 <pre>
1796 The bootable Sprite image is meant to be a demonstration of Sprite, not
1797 a robust Sprite system. There are several missing things, such as
1798 floating point and network support.
1799 </pre>
1800
1801 <p>Once you are logged in as root, running <b><tt>xinit</tt></b> will
1802 start the X11 environment.
1803
1804
1805
1806
1807
1808
1809 <p><br>
1810 <a name="declinux"></a>
1811 <h3>Debian GNU/Linux for DECstation:</h3>
1812
1813 It is possible to run Debian GNU/Linux for DECstation in the emulator,
1814 on an emulated 5000/200 ("3max"). However, just choosing any
1815 Linux/DECstation kernel at random for the installation will not work.
1816
1817 <p><ul>
1818 <li>Linux 2.4/DECstation DZ serial console output doesn't work too well in
1819 GXemul. Linux oopses randomly, which may be due to bugs in GXemul,
1820 but may also be due to bugs in the serial controller code in Linux.
1821 (The speed at which serial interrupts are generated can be
1822 lowered with the <tt>-U</tt> command line option, but it only
1823 reduces the risk, it doesn't take away the oopses completely.)
1824 <li>The Linux 2.6/DECstation DZ serial console driver doesn't work at
1825 all in the emulator, and I'm not really sure it would work on a
1826 real 5000/200 either. Hopefully this will be fixed in Linux in
1827 the future.
1828 <li>To get around the serial console problem, the obvious solution is to
1829 use a graphical framebuffer instead. Old Debian install kernels
1830 supported the graphical framebuffer on the 3max, but not the
1831 keyboard. (This has been fixed now, it seems.)
1832 <li>For quite some time, the MIPS linux cvs tree has had support for the
1833 framebuffer and keyboard, but it did not include Debian's
1834 patches for networking, which made it unusable for network
1835 installs. (Possibly fixed now.)
1836 <li>The kernel has to be for 5000/200. This rules out using
1837 the default kernel on netinst ISO images provided by Debian.
1838 These ISO images boot directly into a kernel which is meant
1839 for a different DECstation model.
1840 <li>The kernel has to have an initrd which more or less matches the
1841 version of Debian that will be installed.
1842 </ul>
1843
1844 <p>Luckily, a precompiled install kernel has been made available by David
1845 Muse, for Debian for R3000 DECstations, which has support for framebuffer,
1846 keyboard, and networking, which works pretty well. Thanks David. :-)
1847
1848 <p>The following steps should let you install Debian GNU/Linux for
1849 DECstation onto a harddisk image in the emulator:
1850
1851 <p>
1852 <ol>
1853 <li>Create an empty harddisk image, which will be the root disk
1854 that Debian installs itself onto:<pre>
1855 <b>dd if=/dev/zero of=debian_pmax.img bs=1024 count=1 seek=6000000</b>
1856
1857 </pre>
1858 <li>Download David Muse' install kernel, and a Debian Netinstall CD-ROM:<pre>
1859 <a href="http://www.firstworks.com/mips-linux-2.4.31/vmlinux-2.4.31">http://www.firstworks.com/mips-linux-2.4.31/vmlinux-2.4.31</a>
1860 <a href="http://cdimage.debian.org/debian-cd/3.1_r0a/mipsel/iso-cd/debian-31r0a-mipsel-netinst.iso">http://cdimage.debian.org/debian-cd/3.1_r0a/mipsel/iso-cd/debian-31r0a-mipsel-netinst.iso</a>
1861
1862 </pre>
1863 <font color="#ff0000"><b>NOTE 2007-04-14:</b></font> It seems that the ISO image
1864 has been removed from the cdimage site. You may need to search
1865 for it elsewhere. Alternatively, you can follow Michel Lespinasse's instructions at
1866 <a href="http://people.zoy.org/~walken/gxemul-etch/HOWTO.html">http://people.zoy.org/~walken/gxemul-etch/HOWTO.html</a>.
1867
1868 <p><font color="#ff0000"><b>NOTE 2007-05-05:</b></font> John Reiser has been kind enough to
1869 place a copy of debian-31r0a-mipsel-netinst.iso <a href="http://bitwagon.com/ftp/debian-31r0a-mipsel-netinst.iso">here</a>.
1870 <p>
1871 <li>Start the installation like this:<pre>
1872 <b>gxemul -X -e3max -d debian_pmax.img -d debian-31r0a-mipsel-netinst.iso vmlinux-2.4.31</b>
1873 </pre>
1874
1875 <p>If everything goes well, you will see Linux' boot messages, and then
1876 arrive at the language chooser.
1877
1878 <p>
1879 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-1.png"><img src="debian-1-small.png"></a>
1880 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-2.png"><img src="debian-2-small.png"></a>
1881 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-3.png"><img src="debian-3-small.png"></a>
1882 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-4.png"><img src="debian-4-small.png"></a>
1883
1884 <p>There will be a warning about the keyboard
1885 layout. Don't mind this. Continue, and then select <b>Detect
1886 and mount CD-ROM</b> in the next menu.
1887
1888 <p>
1889 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-5.png"><img src="debian-5-small.png"></a>
1890 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-6.png"><img src="debian-6-small.png"></a>
1891 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-7.png"><img src="debian-7-small.png"></a>
1892 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-8.png"><img src="debian-8-small.png"></a>
1893
1894 <p>
1895 There will also be a warning about lack of loadable modules. Don't
1896 mind this either, continue anyway by choosing <b>Yes</b>.
1897 <p>
1898 When you reach the network configuration part of the install, choose
1899 <b>Configure network manually</b> and enter the following values:<pre>
1900 IP address: <b>10.0.0.1</b>
1901 Netmask: <b>255.0.0.0</b>
1902 Gateway: <b>10.0.0.254</b>
1903 Name server addresses: <b>10.0.0.254</b>
1904
1905 </pre>
1906 <p>Choose <b>Erase entire disk</b> in the partitioner.
1907
1908 <p>Wait for the base system to be installed. This takes almost forever,
1909 so you can go fetch several <a href="http://en.wikipedia.org/wiki/Jolt_Cola">Jolts</a>
1910 or cups of coffee in the meanwhile.
1911
1912 <p>
1913 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-9.png"><img src="debian-9-small.png"></a>
1914 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-10.png"><img src="debian-10-small.png"></a>
1915 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-11.png"><img src="debian-11-small.png"></a>
1916 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-12.png"><img src="debian-12-small.png"></a>
1917
1918 <p>Congratulations! The first phase of the installation is now completed.
1919 Reboot using the following command line:<pre>
1920 <b>gxemul -X -e3max -o 'root=/dev/sda1' -d debian_pmax.img vmlinux-2.4.31</b>
1921
1922 </pre>
1923 <p>The post-install step takes quite some time as well. A perfect opportunity
1924 for more coffee.
1925
1926 <p>When asked about whether the hardware clock is set to GMT or
1927 not, answer Yes.
1928
1929 <p>When asked about "Apt configuration", choose <b>http</b> as the method
1930 to use for accessing the Debian archive.
1931
1932 <p>
1933 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-13.png"><img src="debian-13-small.png"></a>
1934 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-14.png"><img src="debian-14-small.png"></a>
1935 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="debian-15.png"><img src="debian-15-small.png"></a>
1936
1937 <p>Downloading the packages takes almost forever. Be patient.
1938
1939 <p>Congratulations (again)! You are now fully done with the installation.
1940
1941 </ol>
1942
1943 <p><br>Debian GNU/Linux for DECstation is now installed and ready to be used.
1944 Use this command to boot from the installed disk image:<pre>
1945 <b>gxemul -X -e3max -o 'root=/dev/sda1' -d debian_pmax.img vmlinux-2.4.31</b>
1946
1947 </pre>
1948
1949
1950
1951
1952
1953
1954
1955 <p><br>
1956 <hr>
1957
1958
1959
1960
1961
1962
1963
1964 <p><br>
1965 <a name="mach"></a>
1966 <h3>Mach/PMAX:</h3>
1967
1968 Read the following link if you want to know more about Mach in general:
1969 <a href="http://www-2.cs.cmu.edu/afs/cs/project/mach/public/www/mach.html">
1970 http://www-2.cs.cmu.edu/afs/cs/project/mach/public/www/mach.html</a>
1971
1972 <p>
1973 <font color="#ff0000">NOTE: Mach for DECstation requires some files
1974 (called 'startup' and 'emulator') which I haven't been able to find
1975 on the web. Without these, Mach will not get very far. These
1976 installation instructions are preliminary.
1977 </font>
1978
1979 <p>
1980 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1981 <a href="20041018-mach_pmax.png"><img src="20041018-mach_pmax_small.png"></a>
1982
1983 <p>
1984 The following steps should let you experiment with running Mach
1985 for DECstation in the emulator:
1986
1987 <p>
1988 <ol>
1989 <li>Download the pmax binary distribution for Mach 3.0:<pre>
1990 <a href="http://lost-contact.mit.edu/afs/athena/user/d/a/daveg/Info/Links/Mach/src/release/pmax.tar.Z">http://lost-contact.mit.edu/afs/athena/user/d/a/</a>
1991 <a href="http://lost-contact.mit.edu/afs/athena/user/d/a/daveg/Info/Links/Mach/src/release/pmax.tar.Z">daveg/Info/Links/Mach/src/release/pmax.tar.Z</a>
1992 7263343 bytes, md5 = f9d76c240a6e169921a1df99ad560cc0
1993
1994 </pre>
1995 <li>Extract the Mach kernel:<pre>
1996 <b>tar xfvz pmax.tar.Z pmax_mach/special/mach.boot.MK83.STD+ANY</b>
1997
1998 </pre>
1999 <li>Create an empty disk image:<pre>
2000 <b>dd if=/dev/zero of=disk.img bs=1 count=512 seek=400000000</b>
2001
2002 </pre>
2003 <li>Load the contents of pmax.tar.Z onto the disk image. This is
2004 complicated, and should be described in more detail some time.
2005 For now, use your imagination. (For example using OpenBSD/pmax:
2006 <i>disklabel -E rz1; newfs -O /dev/rz1a;
2007 mount /dev/rz1a /mnt; cd /mnt; download pmax.tar.Z using ftp;
2008 tar xzvf pmax.tar.Z; mv pmax_mach/* .; rmdir pmax_mach;
2009 mkdir mach_servers;
2010 cd mach_servers;
2011 cp ../etc/mach_init .;
2012 cp ../tests/test_service startup;
2013 dd if=/dev/zero of=paging_file bs=65536 count=400;
2014 cd /; sync; umount /mnt</i>)
2015 <p>
2016 <li>Start the emulator with the following command:<pre>
2017 <b>gxemul -c 'put w 0x800990e0, 0' -c 'put w 0x80099144, 0' \
2018 -c 'put w 0x8004aae8, 0' -e 3max -X -d disk.img \
2019 pmax_mach/special/mach.boot.MK83.STD+ANY</b>
2020
2021 </pre>
2022 </ol>
2023
2024 <p>Earlier versions of GXemul had a configure option to enable better
2025 R3000 cache emulation, but since Mach was more or less the only thing that
2026 used it, I removed it. Today's version of GXemul can thus not boot
2027 mach.boot.MK83.STD+ANY straight off, it has to be patched to skip the
2028 cache detection.
2029
2030 <p>The -c commands above patch the kernel to get past the cache detection.
2031 Thanks to Artur Bujdoso for these values.
2032
2033 <p>TODO: Better instructions on how to create the old-style UFS disk
2034 image.
2035
2036
2037
2038
2039
2040
2041
2042 <p><br>
2043 <a name="declinuxredhat"></a>
2044 <h3>Redhat Linux for DECstation:</h3>
2045
2046
2047 <p>
2048 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
2049 <a href="20041129-redhat_mips.png"><img src="20041129-redhat_mips_small.png"></a>
2050
2051 <p>
2052 The following steps should let you run Redhat Linux for DECstation in GXemul:
2053
2054 <p>
2055 <ol>
2056 <li>Download a kernel. David Muse' Debian-install kernel works fine:<pre>
2057 <a href="http://www.firstworks.com/mips-linux-2.4.31/vmlinux-2.4.31">http://www.firstworks.com/mips-linux-2.4.31/vmlinux-2.4.31</a>
2058
2059 </pre>
2060 <li>Download a root filesystem tree:<pre>
2061 <a href="ftp://ftp.linux-mips.org/pub/linux/mips/mipsel-linux/root/mipsel-root-20011216.tgz">ftp://ftp.linux-mips.org/pub/linux/mips/mipsel-linux/root/mipsel-root-20011216.tgz</a>
2062 19486676 bytes, md5 = 5bcb725c90209479cd7ead8ad0c4a414
2063
2064 </pre>
2065 <li>Create a disk image which will contain the Redhat filesystem:<pre>
2066 <b>dd if=/dev/zero of=redhat_mips.img bs=1024 count=1 seek=2000000</b>
2067
2068 </pre>
2069 <!--
2070 dd if=/dev/zero of=/dev/stdout bs=1024 count=200 >> mipsel-root-20011216.tgz
2071 gxemul -XY2 -e3max -d redhat_mips.img -d mipsel-root-20011216.tgz vmlinux-2.4.31
2072 In the three dialogs, choose English, United States, and Continue.
2073 Then choose Execute a shell.
2074 tar xfvz /dev/scsi/host0/bus0/target1/lun0/disc sbin/mke2fs sbin/fdisk
2075 fdisk
2076 -->
2077 <li>This is the tricky part: on redhat_mips.img, you need to create an MS-DOS
2078 (!) partition table, and then an ext2 partition. This is what Linux
2079 will then see as /dev/sda1.
2080 <p>I recommend you run fdisk and mke2fs and untar the archive from within
2081 Debian/DECstation or <a href="#debiancats">Debian/CATS</a> running
2082 inside the emulator. (Alternatively, if you are on a Linux host,
2083 you could use a loopback mount, or similar. This might require
2084 root access. See e.g.
2085 <a href="http://www.mega-tokyo.com/osfaq2/index.php/Disk%20Images%20Under%20Linux">http://www.mega-tokyo.com/osfaq2/index.php/Disk%20Images%20Under%20Linux</a>.)
2086 <p>
2087 In order to actually boot the system you need to modify /etc/fstab.
2088 Change<pre>
2089 /dev/root / nfs defaults 1 1
2090 #/dev/sdc1 / ext2 defaults 1 1
2091 none /proc proc defaults 0 0
2092 none /dev/pts devpts mode=0622 0 0
2093
2094 </pre>to<pre>
2095 #/dev/root / nfs defaults 1 1
2096 /dev/sda1 / ext2 defaults 1 1
2097 none /proc proc defaults 0 0
2098 none /dev/pts devpts mode=0622 0 0
2099
2100 </pre>(Note sda1 instead of sdc1.)
2101 </ol>
2102
2103 <p>To boot Redhat linux from the disk image, use the following command line:<pre>
2104 <b>gxemul -X -e3max -o "root=/dev/sda1 ro" -d redhat_mips.img vmlinux-2.4.31</b>
2105
2106 </pre>
2107 If you need to boot into single user mode, change options to
2108 <tt><b>-o "root=/dev/sda1 rw init=/bin/sh"</b></tt>.
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119 <p><br>
2120 <a name="openbsdsgiinstall"></a>
2121 <h3>OpenBSD/sgi:</h3>
2122
2123 <a href="http://www.openbsd.org/sgi.html">OpenBSD/sgi</a>
2124 can (almost) run in GXemul on an emulated O2 (SGI-IP32) with root on nfs.
2125
2126 <p>
2127 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
2128 <a href="20050617-openbsd-sgi.png"><img src="20050617-openbsd-sgi_small.png"></a>
2129
2130 <p><font color="#ff0000">NOTE: I haven't succeeded all the way with
2131 this yet, and this shows/triggers many bugs in the emulator, but some of
2132 it works.</font>
2133
2134 <p>GXemul does not yet emulate the AHC PCI SCSI controller in the O2. (I have
2135 mailed Adaptec several times, asking for documentation, but never received
2136 any reply.) OpenBSD/sgi can still run in the emulator, as long as it doesn't
2137 use SCSI. For a simple test with the ramdisk (install) kernel, try dowloading<pre>
2138 <a href="ftp://ftp.se.openbsd.org/pub/OpenBSD/4.0/sgi/">ftp://ftp.se.openbsd.org/pub/OpenBSD/4.0/sgi</a>/<a href="ftp://ftp.se.openbsd.org/pub/OpenBSD/4.0/sgi/bsd.rd">bsd.rd</a>
2139
2140 </pre>and run <b><tt>gxemul -xeo2 bsd.rd</tt></b>.
2141
2142 <p>It might also be possible to netboot. Another emulated machine must
2143 then be used as the nfs root server, and the emulated O2 machine must boot
2144 as a <a href="http://www.openbsd.org/cgi-bin/man.cgi?query=diskless&amp;manpath=OpenBSD+Current&amp;format=html">diskless</a>
2145 client. Performing this setup is quite time consuming, but necessary:
2146
2147 <p>
2148 <ol>
2149 <li>First of all, the "<tt>nfs server</tt>" machine must be set up.
2150 This needs to have a 800 MB <tt>/tftpboot</tt> partition.
2151 <a href="#netbsdpmaxinstall">Install NetBSD/pmax 3.1 from CDROM</a>.
2152 (Don't forget to add the extra partition!)
2153 <p>
2154 <li>Configure the nfs server machine to act as an nfs server.
2155 Start up the emulated DECstation:<pre>
2156 <b>gxemul -e 3max -d nbsd_pmax.img</b>
2157 </pre>and enter the following commands as <tt>root</tt>
2158 inside the emulator:
2159 <table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
2160 <b>echo hostname=server &gt;&gt; /etc/rc.conf
2161 echo ifconfig_le0=\"inet 10.0.0.2\" &gt;&gt; /etc/rc.conf
2162 echo nameserver 10.0.0.254 &gt;&gt; /etc/resolv.conf
2163 echo 10.0.0.254 &gt; /etc/mygate
2164 echo /tftpboot -maproot=root 10.0.0.1 &gt; /etc/exports
2165 echo rpcbind=YES &gt;&gt; /etc/rc.conf
2166 echo nfs_server=YES &gt;&gt; /etc/rc.conf
2167 echo mountd=YES &gt;&gt; /etc/rc.conf
2168 echo bootparamd=YES &gt;&gt; /etc/rc.conf
2169 printf "client root=10.0.0.2:/tftpboot \\\n swap=10.0.0.2:/tftpboot/swap\n" &gt; /etc/bootparams
2170 echo "10:20:30:00:00:10 client" &gt; /etc/ethers
2171 echo 10.0.0.1 client &gt; /etc/hosts
2172 reboot</b>
2173 </pre></td></tr></table>
2174 <li>Start the DECstation emulation again, and enter the following
2175 commands to download the OpenBSD/sgi distribution:<br>(NOTE: This
2176 takes quite some time, even if you have a fast network connection.)
2177 <table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
2178 <b>cd /tftpboot; ftp -i ftp.se.openbsd.org</b>
2179 (log in as anonymous...)
2180 <b>cd pub/OpenBSD/4.0/sgi
2181 mget b*tgz c*tgz e* g* m*
2182 quit
2183 sh
2184 for a in *.tgz; do echo $a; tar zxfp $a; done
2185 echo 10.0.0.2:/tftpboot / nfs rw 0 0 &gt; /tftpboot/etc/fstab
2186 rm *.tgz
2187 dd if=/dev/zero of=swap bs=1024 count=32768
2188 halt</b>
2189 </pre></td></tr></table>
2190 <li>Download the OpenBSD/sgi GENERIC and RAMDISK kernels:<pre>
2191 <a href="ftp://ftp.se.openbsd.org/pub/OpenBSD/4.0/sgi/bsd">ftp://ftp.se.openbsd.org/pub/OpenBSD/4.0/sgi/bsd</a>
2192 <a href="ftp://ftp.se.openbsd.org/pub/OpenBSD/4.0/sgi/bsd.rd">ftp://ftp.se.openbsd.org/pub/OpenBSD/4.0/sgi/bsd.rd</a>
2193
2194 </pre>
2195 <li>Create a configuration file called <tt>config_client</tt>:
2196 <table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
2197 <font color="#2020cf">! Configuration file for running OpenBSD/sgi diskless with
2198 ! a NetBSD/pmax machine as the nfs server.
2199 !
2200 ! This config file is for the client.</font>
2201
2202 <b>net(
2203 add_remote("localhost:12444") </b>! the server<b>
2204 local_port(12445) </b>! the client<b>
2205 )
2206
2207 machine(
2208 name("client machine")
2209 serial_nr(1)
2210
2211 type("sgi")
2212 subtype("o2")
2213
2214 </b>! load("bsd")<b>
2215 load("bsd.rd")
2216 )
2217 </b>
2218 </pre></td></tr></table>
2219 ... and another configuration file for the server,
2220 <tt>config_server</tt>:
2221 <table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
2222 <b>net(
2223 local_port(12444) </b>! the server<b>
2224 add_remote("localhost:12445") </b>! the client<b>
2225 )
2226
2227 machine(
2228 name("nfs server")
2229 serial_nr(2)
2230
2231 type("dec")
2232 subtype("5000/200")
2233
2234 disk("nbsd_pmax.img")
2235 )
2236 </b>
2237 </pre></td></tr></table>
2238 <li>Boot the "<tt>nfs server</tt>" and the OpenBSD/sgi
2239 "<tt>client machine</tt>" as two separate emulator instances:<pre>
2240 in one xterm:
2241 <b>gxemul @config_server</b>
2242
2243 and then, in another xterm:
2244 <b>gxemul @config_client</b>
2245
2246 </pre>
2247 <li>In the OpenBSD/sgi window, choose "<tt>s</tt>" (for Shell), and type:
2248 <table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
2249 <b>ifconfig mec0 10.0.0.1; route add default 10.0.0.254
2250 mount -v 10.0.0.2:/tftpboot /mnt
2251 cd /mnt/dev; ./MAKEDEV all; cd /; umount /mnt
2252 halt</b>
2253 </pre></td></tr></table>
2254 You might want to log in as <tt>root</tt> on the server machine, and
2255 run <tt>tcpdump -lnvv</tt> or similar, to see that what the client
2256 machine actually does on the network. The <tt>MAKEDEV</tt> script
2257 takes almost forever, so be patient.
2258 </ol>
2259
2260
2261 <p><font color="#ff0000">NOTE: Everything up to this point should work.
2262 However, the next step (in gray) doesn't actually work:</font>
2263
2264 <p><font color="#888888">Once everything has been set up correctly, change
2265 <tt>bsd.rd</tt> in <tt>config_client</tt> to just <tt>bsd</tt> (the GENERIC
2266 kernel). It should now be possible to boot OpenBSD/sgi using the NetBSD/pmax
2267 nfs server. (When asked for "<tt>root device :</tt>" on the OpenBSD machine,
2268 enter <tt><b>mec0</b></tt>.)</font>
2269
2270 <p><font color="#ff0000">But it doesn't work. Probably because GXemul's
2271 implementation of the mec (ethernet card used in the O2) is too much of
2272 a quick hack. For now, use the <tt>bsd.rd</tt> kernel, and (at every
2273 boot) type:</font><pre>
2274 <b>s</b> (for Shell)
2275 <b>ifconfig mec0 10.0.0.1; route add default 10.0.0.254</b>
2276 <b>mount -v 10.0.0.2:/tftpboot /mnt</b>
2277 <b>cd /mnt; usr/sbin/chroot .</b>
2278 <b>sh etc/rc</b>
2279 </pre>
2280
2281 <p><font color="#ff0000">This will not cause OpenBSD to be booted
2282 normally, but at least a few basic things will work.
2283 By the way, the emulator performs so poorly, that you will have time to
2284 fetch several cups of coffee for each of the steps above.</font>
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294 <p><br>
2295 <a name="openbsdarcinstall"></a>
2296 <h3>OpenBSD/arc:</h3>
2297
2298 It is (almost) possible to install and run OpenBSD/arc on an emulated Acer
2299 PICA-61 in the emulator.
2300
2301 <p><font color="#e00000">Earlier, I had this guest OS listed as
2302 officially working in the emulator, but for several reasons, it has
2303 been moved down here to the "informative-but-not-really-working"
2304 section.</font>
2305
2306 <p>
2307 <ul>
2308 <li>The last OpenBSD/arc release was 2.3. This means that it is very
2309 old, it would not give a fair picture of what OpenBSD is (if you
2310 are just looking to find out what it is like), and it is not
2311 worth experimenting with it. See
2312 <a href="http://www.openbsd.org/arc.html">http://www.openbsd.org/arc.html</a>
2313 for more information.
2314 <li>OpenBSD/arc was (if I understood things correctly) never really
2315 stable, even on real hardare. Problems with too small an interrupt
2316 stack. Bugs are triggered in the emulator that have to do with
2317 issues such as this.
2318 </ul>
2319
2320 <p>
2321 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
2322 <a href="20041024-openbsd-arc-installed.gif"><img src="20041024-openbsd-arc-installed_small.gif"></a>
2323
2324 <p>
2325 <font color="#e00000">Currently, I don't test for every release whether
2326 or not OpenBSD/arc can be installed. Releases prior to 0.3.7
2327 (but probably <i>not</i> 0.3.7) should work. Anyway, here are the
2328 old installation instructions:</font>
2329
2330 <p>To install OpenBSD/arc onto an emulated harddisk image, follow these
2331 instructions:
2332
2333 <p>
2334 <ol>
2335 <li>Create an empty harddisk image, which will be the root disk
2336 that OpenBSD installs itself onto:<pre>
2337 <b>dd if=/dev/zero of=obsd_arc.img bs=1024 count=1 seek=700000</b>
2338
2339 </pre>
2340 <li>Download the entire arc directory from the ftp server: (approx. 75 MB)<pre>
2341 <b>wget -np -l 0 -r <a href="ftp://ftp.se.openbsd.org/pub/OpenBSD/2.3/arc/">ftp://ftp.se.openbsd.org/pub/OpenBSD/2.3/arc/</a></b>
2342
2343 </pre>
2344
2345 <li>You now need to make an ISO image of the entire directory you downloaded.
2346 (I recommend using <tt>mkisofs</tt> for that purpose. If you don't
2347 already have <tt>mkisofs</tt> installed on your system, you need
2348 to install it in order to do this.)<pre>
2349 <b>mkisofs -o openbsd_arc_2.3.iso ftp.se.openbsd.org/pub/OpenBSD/</b>
2350
2351 </pre>
2352 <li>Start the emulator using this command line:<pre>
2353 <b>gxemul -e pica -X -d obsd_arc.img -d b:openbsd_arc_2.3.iso -j 2.3/arc/bsd.rd</b>
2354
2355 </pre>
2356 and proceed like you would do if you were installing OpenBSD
2357 on a real Acer PICA-61. (Answer 'no' when asked if you want to
2358 configure networking, and then install from CD-ROM.)
2359 </ol>
2360
2361 <p>
2362 Once the install has finished, the following command should let you
2363 boot from the harddisk image:
2364 <p>
2365 <pre>
2366 <b>gxemul -X -e pica -d obsd_arc.img ftp.se.openbsd.org/pub/OpenBSD/2.3/arc/bsd</b>
2367
2368 </pre>
2369
2370 The system is very sensitive to (I think) kernel stack overflow, so it
2371 crashes easily. If I remember correctly from mailing lists, this also
2372 happened on real hardware.
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384 <p><br>
2385 <a name="debiancats"></a>
2386 <h3>Debian GNU/Linux for CATS:</h3>
2387
2388 Debian GNU/Linux for CATS (ARM) could <i>theoretically</i> run in GXemul,
2389 however:
2390
2391 <ul>
2392 <li>The DEC 21143 NIC is not emulated well enough for Linux to accept it.
2393 <li>Development of Debian for CATS seems to have died? The latest
2394 install kernel is quite old.
2395 </ul>
2396
2397 <p><font color="#ff0000">IT DOES <b>NOT</b> WORK YET!</font>
2398
2399 <p>The following installation instructions would theoretically work:
2400
2401 <p>
2402 <ol>
2403 <li>Create an empty harddisk image, which will be the root disk
2404 that Debian installs itself onto:<pre>
2405 <b>dd if=/dev/zero of=debian_cats.img bs=1024 count=1 seek=3300000</b>
2406
2407 </pre>
2408 <li>Download the tftpboot install kernel:<pre>
2409 <a href="http://ftp.debian.org/debian/dists/oldstable/main/disks-arm/current/cats/tftpboot.img">http://ftp.debian.org/debian/dists/oldstable/main/disks-arm/current/cats/tftpboot.img</a>
2410
2411 </pre>
2412 <li>Start the installation using the following command line:<pre>
2413 <b>gxemul -XEcats -d debian_cats.img tftpboot.img</b>
2414
2415 </pre>
2416 </ol>
2417
2418 <p>It doesn't work, though, because the NIC isn't working well enough.
2419
2420 <p>The only use of Debian/CATS in the emulator right now is as a way to
2421 manipulate Linux disk images, if you are on a non-Linux host. By choosing
2422 "Execute a shell" in the installer's menu, you can have access to tools such as
2423 fdisk and mke2fs, which are useful for creating Linux paritions on disk images.
2424
2425
2426
2427
2428
2429
2430
2431 <!--
2432 <p><br>
2433 <a name="linux_malta"></a>
2434 <h3>Linux/Malta:</h3>
2435
2436 <p>The Malta emulation mode is best suited for running <a
2437 href="#netbsdevbmipsinstall">NetBSD/evbmips</a>, however, it is possible
2438 to experiment with Linux/Malta as well.
2439
2440 <p>The general idea behind Linux/Malta seems to be that the end user
2441 always compiles his/her own kernel, applies patches, downloads
2442 userland separately, etc. For that reason, Linux/Malta support in the
2443 emulator is not tested for every release (sometimes it works, sometimes it
2444 doesn't work), and these instructions are kind of "fuzzy".
2445
2446 <p><ol start="1">
2447 <li>Create an empty harddisk image, which will be the root disk
2448 that Linux/Malta will be installed onto:<pre>
2449 <b>dd if=/dev/zero of=linux.img bs=1024 count=1 seek=5000000</b>
2450
2451 </pre>
2452 <li>Download a MIPS root filesystem tree:<pre>
2453 <a href="ftp://ftp.linux-mips.org/pub/linux/mips/mipsel-linux/root/mipsel-root-20011216.tgz">ftp://ftp.linux-mips.org/pub/linux/mips/mipsel-linux/root/mipsel-root-20011216.tgz</a>
2454 19486676 bytes, md5 = 5bcb725c90209479cd7ead8ad0c4a414
2455
2456 </pre>
2457 This is an old Redhat tree from 2001, but it seems to almost work.
2458 <p>
2459 <li>Download one precompiled Malta kernel, with ramdisk,
2460 and one without ramdisk (which will be used later on
2461 when booting from disk):<pre>
2462 TODO
2463
2464 </pre>
2465 <li>Start the emulator with the ramdisk kernel, create a MS-DOS style
2466 MBR on the disk, create the filesystem, and extract the
2467 userland files:<pre>
2468 <b>gunzip vmlinux_2.*
2469 gunzip mipsel-root-20011216.tar
2470 gxemul -xemalta -d linux.img -d mipsel-root-20011216.tar vmlinux_2.4.33.2-ide-pci-ramdisk.elf</b>
2471 Inside GXemul: Log in as root and execute the following commands:
2472 <b>fdisk /dev/hda</b>
2473 (enter suitable commands, e.g. <b>n, p, 1, 1, 9921, w</b>)
2474 <b>mkfs /dev/hda1
2475 mount /dev/hda1 /mnt
2476 cd /mnt; tar -xf /dev/hdb; cd ..
2477 umount /mnt; sync; reboot</b>
2478
2479 </pre>
2480 </ol>
2481
2482 <p>It should now be possible to boot from the disk image, using the
2483 following command:
2484
2485 <p><pre>
2486 <b> gxemul -xemalta -d linux.img -o "root=/dev/hda1 rw" vmlinux_2.6.18-rc4-ide-pci-novty.elf</b>
2487 </pre>
2488
2489 <p>There's a slight problem with this specific Redhat tree, so when you
2490 see the message "Configuring kernel parameters: [ OK ]", press CTRL-C
2491 once.
2492 -->
2493
2494
2495
2496
2497
2498
2499 <p><br>
2500 <a name="linux_qemu_mips"></a>
2501 <h3>Linux/QEMU_MIPS:</h3>
2502
2503 I've added a machine mode which emulates the MIPS machine mode used
2504 in Fabrice Bellard's <a href="http://fabrice.bellard.free.fr/qemu/">QEMU</a>.
2505 Starting with QEMU 0.9.0, there are other MIPS modes in QEMU (i.e. Malta);
2506 the QEMU_MIPS mode in GXemul refers to the old QEMU-specific MIPS machine.
2507
2508 <p>The following steps should let you boot into the Linux/QEMU_MIPS
2509 kernel, in way similar to the <tt>run-qemu</tt> script:
2510
2511 <p>
2512 <ol>
2513 <li>Download the archive from
2514 <a href="http://fabrice.bellard.free.fr/qemu/download.html">http://fabrice.bellard.free.fr/qemu/download.html</a> and extract it:<pre>
2515 <b>wget <a href="http://fabrice.bellard.free.fr/qemu/mips-test-0.2.tar.gz">http://fabrice.bellard.free.fr/qemu/mips-test-0.2.tar.gz</a>
2516 tar zxvf mips-test-0.2.tar.gz</b>
2517
2518 </pre>
2519 <li>Start GXemul using the following command line:<pre>
2520 <b>gxemul -E qemu_mips -x -M 128 -o 'console=ttyS0
2521 rd_start=0x80800000 rd_size=10000000 init=/bin/sh'
2522 0x80800000:mips-test/initrd.gz mips-test/vmlinux-2.6.18-3-qemu</b>
2523
2524 </pre>
2525 </ol>
2526
2527
2528
2529
2530
2531
2532
2533
2534 <p><br>
2535 <a name="windows_nt_mips"></a>
2536 <h3>Windows NT/MIPS:</h3>
2537
2538 Old versions of Windows NT could run on MIPS hardware, e.g.
2539 the PICA 61. It is theoretically possible that the emulation provided by
2540 GXemul some day could be stable/complete enough to emulate
2541 such hardware well enough to fool Windows NT into thinking
2542 that it is running on a real machine.
2543 <font color="#ff0000">IT DOES <b>NOT</b> WORK YET!</font>
2544
2545 <p>Installation steps similar to these would be required to install
2546 Windows NT onto a disk image:
2547
2548 <ol>
2549 <li>Put a "Windows NT 4.0 for MIPS" CDROM (or similar) into
2550 your CDROM drive. (On FreeBSD systems, it is
2551 usually called <tt>/dev/cd0c</tt> or similar. Change
2552 that to whatever the CDROM is called on your system,
2553 or the name of a raw .iso image. I have tried this
2554 with the Swedish version, but it might work with
2555 other versions too.)
2556 <p>
2557 <li>Create an empty harddisk image, which will be the disk image
2558 that you will install Windows NT onto:<pre>
2559 <b><tt>dd if=/dev/zero of=winnt_test.img bs=1024 count=1 seek=999000</tt></b>
2560
2561 </pre>
2562 <li>Run the ARC installer, to partition the disk image:<pre>
2563 <b><tt>gxemul -X -e pica -d winnt_test.img -d bc6:/dev/cd0c -j MIPS\\ARCINST</tt></b>
2564 </pre>
2565 Note that <tt>ARCINST</tt> <i>almost</i> works, but not quite.
2566 <p>
2567 <li>Run the SETUP program:<pre>
2568 <b><tt>gxemul -X -e pica -d winnt_test.img -d bc6:/dev/cd0c -j MIPS\\SETUPLDR</tt></b>
2569 </pre>
2570 </ol>
2571
2572 <p><tt>SETUPLDR</tt> manages to load some drivers from the cdrom,
2573 but then it crashes because of incomplete emulation of some hardware devices.
2574
2575
2576
2577
2578
2579
2580
2581
2582 <p><br>
2583 <a name="netbsdbeboxinstall"></a>
2584 <h3>NetBSD/bebox:</h3>
2585
2586 There is an old snapshot of
2587 <a href="http://www.netbsd.org/ports/bebox/">NetBSD/bebox</a>
2588 from 1998-11-19 available at NetBSD's ftp server. NetBSD/bebox
2589 could theoretically run in GXemul.
2590 <font color="#ff0000">IT DOES <b>NOT</b> WORK RIGHT NOW!</font>
2591
2592 <p>The following instructions will let you install NetBSD/bebox onto a
2593 disk image, using a NetBSD/prep kernel temporarily during the install:
2594
2595 <p>
2596 <ol>
2597 <li>Download a NetBSD/prep 2.1 install ramdisk kernel:<pre>
2598 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-2.1/prep/binary/kernel/netbsd-INSTALL.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-2.1/prep/binary/kernel/netbsd-INSTALL.gz</a>
2599 </pre>
2600 <p>
2601 <li>Create an empty harddisk image, which will be the disk image
2602 that you will install NetBSD onto:<pre>
2603 <b>dd if=/dev/zero of=nbsd_bebox.img bs=1024 count=1 seek=999000</b>
2604 </pre>
2605 <p>
2606 <li>Download the NetBSD/bebox snapshot, and create a suitable .iso
2607 image of the files:
2608 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
2609 <b>wget -np -l 0 -r <a href="ftp://ftp.netbsd.org/pub/NetBSD/arch/bebox/snapshot/19981119/">ftp://ftp.netbsd.org/pub/NetBSD/arch/bebox/snapshot/19981119/</a>
2610 mv ftp.netbsd.org/pub/NetBSD/arch/bebox/snapshot/19981119/kern.tgz .
2611 tar zxvf kern.tgz
2612 rm -f kern.tgz
2613 mkisofs -o netbsd-bebox-19981119.iso ftp.netbsd.org/pub/NetBSD/arch/bebox/snapshot/19981119</b>
2614 </pre></td></tr></table>
2615 <p>
2616 <li>Now let's extract the files onto the Bebox disk image. Start NetBSD/prep
2617 with the following command line:<pre>
2618 <b>gxemul -x -e ibm6050 -d d:netbsd-bebox-19981119.iso -d nbsd_bebox.img netbsd-INSTALL.gz</b>
2619
2620 </pre>Choose (S) for Shell, and execute the following commands:
2621 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
2622 <b>disklabel -I -i wd1
2623 a
2624 4.2BSD
2625 1c
2626 750M
2627 b
2628 swap
2629 a
2630 200M
2631 W
2632 y
2633 Q
2634 newfs /dev/wd1a
2635 mount_cd9660 /dev/wd0c /mnt
2636 mount /dev/wd1a /mnt2
2637 cd mnt2
2638 for a in /mnt/*.tgz; do echo $a; tar zxfp $a; done
2639 cd dev; sh ./MAKEDEV all; cd ../etc
2640 echo rc_configured=YES &gt;&gt; rc.conf
2641 echo "/dev/wd0a / ffs rw 1 1" &gt; fstab
2642 echo "/dev/wd0b none swap sw 0 0" &gt;&gt; fstab
2643 cd /; umount /mnt; umount /mnt2
2644 sync; halt</b>
2645 </pre></td></tr></table>
2646 </ol>
2647
2648 <p>You should now be able to boot NetBSD/bebox using this command:<pre>
2649 <b>gxemul -X -E bebox -d nbsd_bebox.img netbsd</b>
2650 </pre>
2651
2652 <p>When asked for the root device, enter <b><tt>wd0a</tt></b>.
2653
2654 <p><font color="#ff0000">IT DOES <b>NOT</b> WORK YET</font>, there are
2655 errors while uncompressing the tgz files, and the machine crashes when
2656 trying to run /sbin/init.
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667 <p><br>
2668 <a name="netbsdlandiskinstall"></a>
2669 <h3>NetBSD/landisk:</h3>
2670
2671 <a href="http://www.netbsd.org/ports/landisk/">NetBSD/landisk</a> can
2672 run in GXemul.
2673
2674 <p><font color="#ff0000">NOTE: This is still too
2675 unstable to be considered really working! Snapshots from April 2007
2676 or so will probably not work, unless an #if 0 is changed to
2677 #if 1 in the implementation of the 'LDC Rm,SR' instruction
2678 (in src/cpus/cpu_sh_instr.c).</font>
2679
2680 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
2681 <a href="20070224-netbsd-landisk.png"><img src="20070224-netbsd-landisk_small.png"></a>
2682
2683 <p>At the time of writing this, there are not yet any formal releases
2684 of NetBSD/landisk, only daily snapshot builds.
2685
2686 <p>The NetBSD/landisk distribution does not include any INSTALL kernel,
2687 so it must be installed using another (emulated) machine.
2688
2689 <p>The following instructions will let you install NetBSD/landisk onto a disk
2690 image, using an emulated CATS machine:
2691
2692 <p>
2693 <ol>
2694 <li>Download a NetBSD/cats install kernel:<pre>
2695 <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/cats/binary/kernel/netbsd.aout-INSTALL.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-3.1/cats/binary/kernel/netbsd.aout-INSTALL.gz</a>
2696 </pre>
2697 <p>
2698 <li>Create an empty harddisk image, which will be the disk image
2699 that you will install NetBSD/landisk onto:<pre>
2700 <b>dd if=/dev/zero of=nbsd_landisk.img bs=1024 count=1 seek=900000</b>
2701
2702 </pre>
2703 <p>
2704 <li>Download the latest netbsd-4 (pre-release) snapshot, and make an iso image
2705 of it: (replace 200704110002Z with whatever is the latest one)<pre>
2706 <b>wget -np -l 0 -r <a href="ftp://ftp.netbsd.org/pub/NetBSD-daily/netbsd-4/">ftp://ftp.netbsd.org/pub/NetBSD-daily/netbsd-4/</a>200704110002Z/landisk
2707 mkisofs -U -o landisk.iso ftp.netbsd.org/pub/NetBSD-daily/netbsd-4/*</b>
2708 </pre>
2709
2710 <p>
2711 <li>Start the emulated CATS machine like this:<pre>
2712 <b>gxemul -XEcats -d nbsd_landisk.img -d landisk.iso netbsd.aout-INSTALL.gz</b>
2713
2714 </pre>
2715 <li>Exit the installer, then execute the following commands:
2716 <p><table border="0"><tr><td><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td><pre>
2717 <b>disklabel -i -I wd0</b> (for example 'a', '4.2BSD', '1c',
2718 '700M', 'b', 'swap', '701M', '$', 'P', 'W', 'y', and 'Q')
2719 <b>newfs /dev/wd0a
2720 mount /dev/cd0c /mnt
2721 mkdir /mnt2; mount /dev/wd0a /mnt2
2722 cd /mnt2; sh
2723 for a in /mnt/*/binary/sets/[bcekmt]*.tgz; do echo $a; tar zxfp $a; done
2724 exit
2725 cd dev; sh ./MAKEDEV all; cd ../etc
2726 echo rc_configured=YES >> rc.conf
2727 echo "/dev/wd0a / ffs rw 1 1" > fstab
2728 echo "/dev/wd0b none swap sw 0 0" >> fstab
2729 cd /; umount /mnt; umount /mnt2; halt</b>
2730 </pre></td></tr></table>
2731 </ol>
2732
2733 <p>You should now be able to boot NetBSD/landisk using this command:<pre>
2734 <b>gxemul -x -E landisk -d nbsd_landisk.img netbsd-GENERIC.gz</b>
2735 </pre>
2736
2737
2738
2739
2740
2741
2742
2743 </p>
2744
2745 </body>
2746 </html>

  ViewVC Help
Powered by ViewVC 1.1.26