/[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

Annotation of /trunk/doc/guestoses.html

Parent Directory Parent Directory | Revision Log Revision Log


Revision 8 - (hide annotations)
Mon Oct 8 16:18:19 2007 UTC (16 years, 6 months ago) by dpavlin
File MIME type: text/html
File size: 45728 byte(s)
++ trunk/HISTORY	(local)
$Id: HISTORY,v 1.777 2005/06/12 12:31:52 debug Exp $
==============  RELEASE 0.3.3.1  ==============

20050609	Adding simple MIPS IPIs (to dev_mp).
20050611	Adding an ugly hack to track down low-reference bugs
		(define TRACE_NULL_CRASHES, or configure --tracenull).
		Other minor updates.
20050612	Adding a dummy evbmips mode.

==============  RELEASE 0.3.3.2  ==============


1 dpavlin 2 <html>
2     <head><title>GXemul documentation: Installing and running "guest OSes"</title>
3 dpavlin 8 <meta name="robots" content="noarchive,nofollow,noindex">
4 dpavlin 2 </head>
5 dpavlin 4 <body bgcolor="#f8f8f8" text="#000000" link="#4040f0" vlink="#404040" alink="#ff0000">
6     <table border=0 width=100% bgcolor="#d0d0d0"><tr>
7     <td width=100% align=center valign=center><table border=0 width=100%><tr>
8     <td align="left" valign=center bgcolor="#d0efff"><font color="#6060e0" size="6">
9     <b>GXemul documentation:</b></font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
10     <font color="#000000" size="6"><b>Installing and running "guest OSes"</b>
11     </font></td></tr></table></td></tr></table><p>
12 dpavlin 2
13     <!--
14    
15 dpavlin 8 $Id: guestoses.html,v 1.50 2005/06/11 11:53:33 debug Exp $
16 dpavlin 2
17     Copyright (C) 2003-2005 Anders Gavare. All rights reserved.
18    
19     Redistribution and use in source and binary forms, with or without
20     modification, are permitted provided that the following conditions are met:
21    
22     1. Redistributions of source code must retain the above copyright
23     notice, this list of conditions and the following disclaimer.
24     2. Redistributions in binary form must reproduce the above copyright
25     notice, this list of conditions and the following disclaimer in the
26     documentation and/or other materials provided with the distribution.
27     3. The name of the author may not be used to endorse or promote products
28     derived from this software without specific prior written permission.
29    
30     THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
31     ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
32     IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
33     ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
34     FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
35     DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
36     OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
37     HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
38     LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
39     OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
40     SUCH DAMAGE.
41    
42     -->
43    
44     <a href="./">Back to the index</a>
45    
46     <p><br>
47     <h2>Installing and running "guest OSes"</h2>
48    
49     <p>
50     <ul>
51     <li><a href="#generalnotes">General notes on running "guest OSes"</a>
52 dpavlin 4 <li><a href="#netbsdinstall">Installing NetBSD/pmax in GXemul</a>
53     <li><a href="#netbsdarcinstall">Installing NetBSD/arc in GXemul</a>
54     <li><a href="#netbsdhpcmipsinstall">Installing NetBSD/hpcmips in GXemul</a>
55     <li><a href="#netbsdcobaltinstall">Installing NetBSD/cobalt in GXemul</a>
56 dpavlin 2 <!--
57 dpavlin 4 <li><a href="#netbsdsgimips">Running NetBSD/sgimips in GXemul</a>
58 dpavlin 2 -->
59 dpavlin 4 <li><a href="#openbsdinstall">Installing OpenBSD/pmax in GXemul</a>
60     <li><a href="#openbsdarcinstall">Installing OpenBSD/arc in GXemul</a>
61 dpavlin 2 <!--
62 dpavlin 4 <li><a href="#openbsdsgiinstall">Running OpenBSD/sgi in GXemul</a>
63 dpavlin 2 -->
64 dpavlin 4 <li><a href="#ultrixinstall">Installing Ultrix/RISC in GXemul</a>
65     <li><a href="#sprite">Running Sprite for DECstation in GXemul</a>
66     <li><a href="#declinux">Installing Debian GNU/Linux for DECstation in GXemul</a>
67     <li><a href="#declinuxredhat">Running Redhat Linux for DECstation in GXemul</a>
68     <li><a href="#mach">Running Mach/PMAX in GXemul</a>
69 dpavlin 2 </ul>
70    
71    
72    
73    
74    
75    
76     <p><br>
77     <a name="generalnotes"></a>
78     <h3>General notes on running "guest OSes":</h3>
79    
80     The emulator works well enough to run complete operating systems. These
81     are often refered to as "guest" operating systems.
82    
83     <p>
84     Although it is possible to let a guest OS access real hardware, such as
85     harddisks, it is much more flexible and attractive to simulate harddisks
86     using files residing in the host's filesystem. On Unix-like systems, files
87     may contain holes, which makes this really simple. To the guest operating
88     system, the harddisk image looks and acts like a real disk.
89    
90    
91    
92    
93    
94    
95    
96    
97     <p><br>
98     <a name="netbsdinstall"></a>
99 dpavlin 4 <h3>Installing NetBSD/pmax in GXemul:</h3>
100 dpavlin 2
101 dpavlin 4 <p>
102     &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
103 dpavlin 6 <a href="20050317-example.png"><img src="20050317-example_small.png"></a>
104 dpavlin 4
105     <p>
106 dpavlin 2 To install NetBSD/pmax onto a harddisk image in the emulator, follow these
107     instructions:
108    
109     <p>
110     <ol start="1">
111     <li>Create an empty harddisk image, which will be the root disk
112     that NetBSD installs itself onto:<pre>
113 dpavlin 4 $ <b>dd if=/dev/zero of=nbsd_pmax.img bs=1 count=512 seek=1900000000</b>
114 dpavlin 2
115     </pre>
116     </ol>
117 dpavlin 4
118 dpavlin 2 <p>
119     From this point, there are two separate ways to continue the installation.
120     You can either download a CD-ROM iso image (and let the installation
121     program copy files from the CD-ROM image to the harddisk image), or you
122     can install via ftp. For an installation from a CD-ROM image, follow these
123     steps:
124     <p>
125     <ol start="2">
126    
127     <li>Download a NetBSD CD-ROM iso image:<pre>
128     <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/1.6.2/pmaxcd.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/1.6.2/pmaxcd.iso</a>
129     or
130     <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/2.0/pmaxcd.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/2.0/pmaxcd.iso</a>
131    
132     </pre>
133     <li>Start the emulator like this:<pre>
134 dpavlin 4 $ <b>gxemul -X -b -E dec -e 3max -d nbsd_pmax.img -d bc:pmaxcd.iso</b>
135 dpavlin 2 </pre>
136     </ol>
137     <p>
138     For an ftp install, substitute steps 2 and 3 above with these:
139     <p>
140     <ol start="2">
141    
142     <li>Download a NetBSD pmax INSTALL kernel, and gunzip it:<pre>
143     <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-1.6.2/pmax/binary/kernel/netbsd-INSTALL.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-1.6.2/pmax/binary/kernel/netbsd-INSTALL.gz</a>
144     or
145     <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-2.0/pmax/binary/kernel/netbsd-INSTALL.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-2.0/pmax/binary/kernel/netbsd-INSTALL.gz</a>
146    
147     $ <b>gunzip netbsd-INSTALL.gz</b>
148    
149     </pre>
150     <li>Start the emulator like this:<pre>
151 dpavlin 4 $ <b>gxemul -X -b -E dec -e 3max -d nbsd_pmax.img -O netbsd-INSTALL</b>
152 dpavlin 2 </pre>
153     </ol>
154    
155     <p>
156     (If you don't want to use a graphical framebuffer during the install,
157     you can remove <b>-X</b> from the command line, but then make sure you
158     choose 'vt100' when prompted with which terminal type to use, and not
159     'rcons'.)
160    
161     <p>
162     Then proceed like you would do if you were installing NetBSD on a real
163     DECstation. If you are installing from the network, then suitable networking
164     parameters are as follows:<pre>
165     Which device shall I use? [le0]: <b>le0</b>
166     ..
167     Your DNS domain: <b>mydomain.com</b>
168     Your host name: <b>foo</b>
169     Your IPv4 number: <b>10.0.0.1</b>
170     IPv4 Netmask [0xff000000]: <b>0xff000000</b>
171     IPv4 gateway: <b>10.0.0.254</b>
172     IPv4 name server: <b>10.0.0.254</b>
173     </pre>
174    
175     <p>
176     (If using 10.0.0.254 as the nameserver fails, then try entering the
177     IP number of a real-world nameserver instead.)
178    
179     <p>
180     When the installation is completed, the following command should start
181     NetBSD from the harddisk image:<pre>
182 dpavlin 4 $ <b>gxemul -X -b -M64 -E dec -e 3max -d nbsd_pmax.img</b>
183 dpavlin 2 </pre>
184    
185     <p>
186     Use <b>startx</b> to start X windows.
187    
188     <p>
189     <font color="#ff0000">NOTE:</font> For some reason, NetBSD 2.0 doesn't
190     work with X out-of-the-box on pmax. It seems that this has to do with a
191     switch to WSCONS. For now, if you want X, then try NetBSD 1.6.2.
192    
193     <p>
194     If you want to run without the X framebuffer, use this instead:<pre>
195 dpavlin 4 $ <b>gxemul -E dec -e 3max -b -d nbsd_pmax.img</b>
196 dpavlin 2 </pre>
197    
198    
199    
200    
201    
202    
203    
204     <p><br>
205     <a name="netbsdarcinstall"></a>
206 dpavlin 4 <h3>Installing NetBSD/arc in GXemul:</h3>
207 dpavlin 2
208 dpavlin 4 It is possible to run NetBSD/arc on an emulated Acer PICA-61 in the emulator.
209 dpavlin 2
210     <p>
211 dpavlin 4 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
212     <a href="20041024-netbsd-arc-installed.gif"><img src="20041024-netbsd-arc-installed_small.gif"></a>
213    
214     <p>
215 dpavlin 2 To install NetBSD/arc from a CDROM image onto an emulated harddisk image,
216     follow these instructions:
217    
218     <p>
219     <ol start="1">
220     <li>Create an empty harddisk image, which will be the root disk
221     that NetBSD installs itself onto:<pre>
222     $ <b>dd if=/dev/zero of=nbsd_arc.img bs=1024 count=1 seek=900000</b>
223    
224     </pre>
225 dpavlin 6 <li>Download a NetBSD/arc 1.6.2 CDROM image from ftp:<pre>
226 dpavlin 2 <a href="ftp://ftp.netbsd.org/pub/NetBSD/iso/1.6.2/arccd.iso">ftp://ftp.netbsd.org/pub/NetBSD/iso/1.6.2/arccd.iso</a>
227    
228     </pre>
229     <li>Start the emulator using this command line:<pre>
230 dpavlin 6 $ <b>gxemul -E arc -e pica -x -b -d nbsd_arc.img -d bc:arccd.iso \
231     -j arc/binary/kernel/netbsd.RAMDISK.gz</b>
232 dpavlin 2
233     </pre>
234 dpavlin 6 (Try removing <tt>-x</tt> if you have problems with the xterm.)
235     <p>
236 dpavlin 2 <li>From now on, you have to use your imagination, as there is no
237     automatic installation program for NetBSD/arc. Here are some tips
238     and hints on how you can proceed with the install:<pre>
239     $ <b>mount /dev/cd0a /mnt2</b>
240     $ <b>disklabel -i -I sd0</b> (for example 'a', '4.2BSD', '1c',
241     '700M', 'b', 'swap', '701M', '$', 'P', 'W', 'y', and 'Q')
242     $ <b>newfs /dev/sd0a</b>
243     $ <b>mount /dev/sd0a /mnt</b>
244     $ <b>cd /mnt</b>
245 dpavlin 6 $ <b>for a in /mnt2/arc/binary/sets/*.tgz; do echo $a; tar xzpf $a; done</b>
246 dpavlin 2 $ <b>cd dev; sh MAKEDEV all</b>
247     $ <b>cd ../etc; echo "rc_configured=YES" &gt;&gt; rc.conf</b>
248     $ <b>cat > /mnt/etc/fstab</b>
249     /dev/sd0a / ffs rw 1 1
250     /dev/sd0b none swap sw 0 0
251     (ctrl-d)
252     $ <b>cd /; umount /mnt; umount /mnt2</b>
253     $ <b>halt</b>
254    
255     </pre>
256     <li>Download a generic NetBSD/arc kernel,
257     and gunzip it:<pre>
258     <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-1.6.2/arc/binary/kernel/netbsd-GENERIC.gz">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-1.6.2/arc/binary/kernel/netbsd-GENERIC.gz</a>
259    
260     </pre>
261     </ol>
262    
263     <p>
264     You can now use the generic NetBSD/arc kernel to boot from the harddisk
265     image, using the following command:
266     <p>
267     <pre>
268 dpavlin 6 $ <b>gxemul -E arc -e pica -xb -d nbsd_arc.img netbsd-GENERIC</b>
269 dpavlin 2
270     </pre>
271    
272    
273    
274    
275    
276    
277    
278    
279     <p><br>
280     <a name="netbsdhpcmipsinstall"></a>
281 dpavlin 4 <h3>Installing NetBSD/hpcmips in GXemul:</h3>
282 dpavlin 2
283     It is possible to install NetBSD/hpcmips onto a disk image, on an an
284     emulated MobilePro 770, 780, 800, or 880. The emulator treats the
285     different machine models as being almost identical; the most important
286     difference is regarding the framebuffer.
287    
288     <p>
289     <table border="0">
290     <tr>
291     <td width="80">&nbsp;</td>
292     <td><u>Model:</u></td>
293     <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
294     <td><u>Framebuffer size/depth:</u></td>
295     <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
296     <td><u>Framebuffer address:</u></td>
297     </tr>
298     <tr>
299     <td></td>
300     <td>MobilePro 770 (<super>*2</super>)</td>
301     <td></td>
302     <td>640 x 240, 16 bits</td>
303     <td></td>
304     <td>0xa000000</td>
305     </tr>
306     <tr>
307     <td></td>
308     <td>MobilePro 780</td>
309     <td></td>
310     <td>640 x 240, 16 bits</td>
311     <td></td>
312     <td>0xa180100 (<super>*</super>)</td>
313     </tr>
314     <tr>
315     <td></td>
316     <td>MobilePro 800</td>
317     <td></td>
318     <td>800 x 600, 16 bits</td>
319     <td></td>
320     <td>0xa000000</td>
321     </tr>
322     <tr>
323     <td></td>
324     <td>MobilePro 880</td>
325     <td></td>
326     <td>800 x 600, 16 bits</td>
327     <td></td>
328     <td>0xa0ea600 (<super>*</super>)</td>
329     </tr>
330     </table>
331    
332     <p>
333     (<super>*</super>) = not aligned at a 4 KB boundary, so it will not work
334     efficiently with the current bintrans system. Using this mode will still
335     work, but each load and store will be emulated much more slowly than is
336     possible with an aligned framebuffer.
337    
338     <p>
339     (<super>*2</super>) = The MobilePro 770's cursor keys work differently
340     than the other models, for some reason. (This is a known bug.)
341    
342     <p>
343 dpavlin 4 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
344     <a href="20050427-netbsd-hpcmips-1.png"><img src="20050427-netbsd-hpcmips-1_small.png"></a>
345     &nbsp;&nbsp;&nbsp;
346     <a href="20050427-netbsd-hpcmips-2.png"><img src="20050427-netbsd-hpcmips-2_small.png"></a>
347    
348     <p>
349 dpavlin 2 These instructions show an example of how to install
350     NetBSD/hpcmips on an emulated MobilePro 800:
351    
352     <p>
353     <ol start="1">
354     <li>Create an empty harddisk image, which will be the root disk
355     that you will install NetBSD/hpcmips onto:<pre>
356     $ <b>dd if=/dev/zero of=nbsd_hpcmips.img bs=1024 count=1 seek=1990000</b>
357    
358     </pre>
359 dpavlin 6 <li>Download the NetBSD 2.0 for hpcmips ISO image:<pre>
360 dpavlin 2 <a href="ftp://ftp.se.netbsd.org/pub/NetBSD/iso/2.0/">ftp://ftp.se.netbsd.org/pub/NetBSD/iso/2.0</a>/<a href="ftp://ftp.se.netbsd.org/pub/NetBSD/iso/2.0/hpcmipscd.iso">hpcmipscd.iso</a>
361    
362     </pre>(You may want to choose a mirror closer to you, if .se is slow.)
363     <p>
364     <li>Start the installation like this:<pre>
365 dpavlin 6 $ <b>gxemul -E hpc -e mobilepro800 -b -X -d nbsd_hpcmips.img \
366     -d b:hpcmipscd.iso -j hpcmips/installation/netbsd.gz</b>
367 dpavlin 2
368     </pre>
369     and proceed like you would do if you were installing NetBSD on a real
370     MobilePro 800. (Install onto wd0, choose "Use entire disk" when
371     doing the MBR partitioning, and choose wd1d (not cd0c) as the
372     CDROM device to install from.)
373     </ol>
374    
375     <p>
376     If everything worked, NetBSD should now be installed on the disk image.
377     GXemul does not (yet) support reading the kernel directly from the
378     disk image, so you need to download a generic kernel separately:<pre>
379     <a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-2.0/hpcmips/binary/kernel/">ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-2.0/hpcmips/binary/kernel</a>/<a href="ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-2.0/hpcmips/binary/kernel/netbsd-GENERIC.gz">netbsd-GENERIC.gz</a>
380    
381     </pre>
382    
383     <p>
384     Once you have gunziped the generic kernel, you can now use it to boot from
385     the harddisk image, using the following command:<pre>
386     $ <b>gxemul -E hpc -e mobilepro800 -b -X -d nbsd_hpcmips.img netbsd-GENERIC</b>
387    
388     </pre>
389    
390     <p>
391     When you have logged in as root, you can use <b>startx</b> to start X
392     Windows. (Note: There is no mouse support yet; you can only use
393     keyboard input.)
394    
395    
396    
397    
398    
399    
400 dpavlin 4
401    
402     <p><br>
403     <a name="netbsdcobaltinstall"></a>
404     <h3>Installing NetBSD/cobalt in GXemul:</h3>
405    
406     <a href="http://www.netbsd.org/Ports/cobalt/">NetBSD/cobalt</a> is tricky
407     to install, because the Cobalt machines were designed for Linux, and not
408     very flexible. There is no INSTALL kernel for NetBSD/cobalt. One way to
409     install the NetBSD/cobalt distribution onto a disk image is to do it from
410     another (emulated) machine.
411    
412     <p>
413     &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
414     <a href="20050413-netbsd-cobalt.png"><img src="20050413-netbsd-cobalt_small.png"></a>
415    
416     <p>
417     The following instructions will let you install NetBSD/cobalt onto a disk
418     image, from an emulated DECstation 3MAX machine:
419    
420     <p>
421     <ol>
422     <li>Create an empty harddisk image, which will be the disk image
423     that you will install NetBSD/cobalt onto:<pre>
424     $ <b>dd if=/dev/zero of=nbsd_cobalt.img bs=1024 count=1 seek=1999000</b>
425    
426     </pre>
427     <li>Download the generic kernel for Cobalt (and gunzip it) and
428     the 2.0 ISO image:<pre>
429     <a href="ftp://ftp.se.netbsd.org/pub/NetBSD/NetBSD-2.0/cobalt/binary/kernel/netbsd-GENERIC.gz">ftp://ftp.se.netbsd.org/pub/NetBSD/NetBSD-2.0/cobalt/binary/kernel/netbsd-GENERIC.gz</a>
430     <a href="ftp://ftp.se.netbsd.org/pub/NetBSD/iso/2.0/cobaltcd.iso">ftp://ftp.se.netbsd.org/pub/NetBSD/iso/2.0/cobaltcd.iso</a>
431    
432     </pre>(You may want to choose a mirror closer to you, if .se is slow.)
433     <p>
434 dpavlin 6 <li>Install NetBSD/pmax 2.0 according to instructions further up
435     on this page.
436     <p>
437 dpavlin 4 <li>Start NetBSD/pmax like this:<pre>
438     $ <b>gxemul -b -Edec -e3max -d nbsd_pmax.img -d cobaltcd.iso -d nbsd_cobalt.img</b>
439    
440     </pre>
441     <li>Log in as root (on the emulated 3MAX machine), and execute the
442     following commands: (adjust according to taste)<pre>
443     # <b>newfs /dev/sd1c</b>
444     # <b>mount /dev/cd0c /mnt</b>
445     # <b>mkdir /mnt2; mount /dev/sd1c /mnt2</b>
446     # <b>cd /mnt2; sh</b>
447     # <b>for a in /mnt/cobalt/binary/sets/*.tgz; do echo $a; tar zxfp $a; done</b>
448     # <b>exit</b>
449     # <b>cd dev; sh ./MAKEDEV all; cd ../etc</b>
450     # <b>echo rc_configured=YES >> rc.conf</b>
451     # <b>echo "/dev/wd0d / ffs rw 1 1" > fstab</b>
452     # <b>cd /; umount /mnt; umount /mnt2; halt</b>
453     </pre>
454     </ol>
455    
456     <p>
457     You should now be able to boot NetBSD/cobalt like this:<pre>
458     $ <b>gxemul -b -M128 -E cobalt -d nbsd_cobalt.img netbsd-GENERIC</b>
459     </pre>
460    
461     Note that the installation instructions above create a filesystem
462     <i>without</i> a disklabel, so there is only one ffs partition and no
463     swap. You will need to enter the following things when booting with the
464     generic kernel:<pre>
465     root device (default wd0a): <b>wd0d</b>
466     dump device (default wd0b): <b>none</b>
467     file system (default generic): <b>ffs</b>
468 dpavlin 6 init path (default /sbin/init): <i>(just press enter here)</i>
469 dpavlin 4 </pre>
470    
471    
472    
473    
474    
475    
476    
477 dpavlin 2 <!--
478    
479     <p><br>
480     <a name="netbsdsgimips"></a>
481 dpavlin 4 <h3>Running NetBSD/sgimips in GXemul:</h3>
482 dpavlin 2
483     <a href="http://www.netbsd.org/Ports/sgimips/">NetBSD/sgimips</a>
484     can theoretically run in GXemul on an emulated O2 (SGI-IP32) with root on nfs.
485    
486     <p>
487     <font color="#ff0000">NOTE: I haven't succeeded with this yet.</font>
488    
489     <p>
490     See the section on <a href="#openbsdsgiinstall">how to run OpenBSD/sgi</a>
491     for more information.
492    
493     <p>
494     TODO...
495    
496     <pre>
497 dpavlin 6 cd /tftpboot; ftp -i ftp.se.netbsd.org
498 dpavlin 2 ..
499     cd pub/NetBSD/NetBSD-2.0/sgimips/binary/sets
500     mget *.tgz
501     exit
502     sh
503     for a in etc.tgz base.tgz comp.tgz; do tar zxvfp $a; done
504    
505     </pre>
506    
507     -->
508    
509    
510    
511    
512    
513    
514    
515     <p><br>
516     <a name="openbsdinstall"></a>
517 dpavlin 4 <h3>Installing OpenBSD/pmax in GXemul:</h3>
518 dpavlin 2
519     Installing OpenBSD/pmax is a bit harder than installing NetBSD/pmax.
520     You should first read the section above on how to install NetBSD/pmax,
521     before continuing here. If you have never installed OpenBSD on any
522     architecture, then you need a great deal of patience to do this.
523     If, on the other hand you are used to installing OpenBSD, then
524     this should be no problem for you.
525    
526     <p>
527 dpavlin 4 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
528     <a href="20040710-openbsd-pmax.png"><img src="20040710-openbsd-pmax_small.png"></a>
529     &nbsp;&nbsp;&nbsp;
530     <a href="openbsd-pmax-20040710.png"><img src="openbsd-pmax-20040710_small.png"></a>
531    
532     <p>
533 dpavlin 2 OpenBSD/pmax died at release 2.8 of OpenBSD, so you should be
534     aware of the fact that this will not give you an up-to-date OpenBSD
535     system.
536    
537     <p>
538     Following these instructions <i>might</i> work. If not, then use
539     common sense and imagination to modify them as you see fit.
540    
541     <p>
542     <ol>
543     <li>Create an empty harddisk image, which will be the root disk
544     that OpenBSD installs itself onto:<pre>
545 dpavlin 4 $ <b>dd if=/dev/zero of=obsd_pmax.img bs=1 count=512 seek=900000000</b>
546 dpavlin 2
547     </pre>
548     <li>Download the entire pmax directory from the ftp server: (approx. 99 MB)<pre>
549     $ <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>
550    
551     </pre>
552    
553     <li>Execute the following commands:<pre>
554     $ <b>mv ftp.se.openbsd.org/pub/OpenBSD/2.8/pmax/simpleroot28.fs.gz .</b>
555     $ <b>gunzip simpleroot28.fs.gz</b>
556     $ <b>chmod +w simpleroot28.fs</b> &lt;--- make sure
557    
558     </pre>
559     <li>You now need to make an ISO image of the entire directory you downloaded.
560 dpavlin 6 I recommend using <tt>mkisofs</tt> for that purpose. If you don't
561     already have <tt>mkisofs</tt> installed on your system, you need
562     to install it in order to do this.<pre>
563 dpavlin 2 $ <b>mkisofs -o openbsd_pmax_2.8.iso ftp.se.openbsd.org/pub/OpenBSD/2.8/pmax</b>
564    
565     </pre>
566     <li>Start the emulator with all three (!) disk images:<pre>
567 dpavlin 4 $ <b>gxemul -E dec -e 3max -b -d obsd_pmax.img -d b:simpleroot28.fs -j bsd -d c:openbsd_pmax_2.8.iso</b>
568 dpavlin 2
569     </pre>
570 dpavlin 6 (If you add <tt><b>-X</b></tt>, you will run with the graphical
571     framebuffer. This is <i>REALLY</i> slow because the console has to
572     scroll a lot during the install. I don't recommend it.)
573 dpavlin 2 <p>
574     <li>Go on with the installation as you would do if you were installing on a real machine.
575     If you are not used to the OpenBSD installer, then this will most likely
576     be a very uncomfortable experience. Some important things to keep in mind are:
577     <ul>
578     <li>rz0 is the rootdisk you wish to install onto.
579     <li>rz1 is the simpleroot image.
580     <li>rz2 is the CDROM containing the "install sets".
581     <li>When asked for the "<b>root device?</b>", enter <b>rz1</b>.
582     <li>At "<b>Enter pathname of shell or RETURN for sh:</b>", press enter.
583     <li>At the # prompt, do the following:<pre>
584     $ <b>fsck /dev/rz1a</b> (and mark the filesystem as clean)
585     $ <b>mount /dev/rz1a /</b>
586     $ <b>mount -t kernfs kern kern</b>
587     $ <b>./install</b>
588    
589     </pre>
590     and proceed with the install. Good luck. :-)
591     <li>Answer "<b>y</b>" when asked if you wish to configure the network.
592     (See the section about installing NetBSD/pmax for suitable
593     network settings.)
594     <li>Install from "<b>c</b>" (cdrom), choose "<b>rz2</b>" as the cdrom device, and "<b>/</b>" as
595     the directory containing the install sets.
596     </ul>
597     <p>
598     <li>
599     For some unknown reason, the install script does not set the root
600     password! The first time you boot up OpenBSD after the install, you
601     need to go into single user mode and run <b>passwd root</b> to set
602     the root password, or you will not be able to log in at all!
603     <pre>
604 dpavlin 4 $ <b>gxemul -E dec -e 3max -b -d obsd_pmax.img -d 2c:openbsd_pmax_2.8.iso -j bsd -o '-s'</b>
605 dpavlin 2 </pre>
606     While you are at it, you might want to extract the X11 install sets
607     as well, as the installer seems to ignore them too. (Perhaps due to a bug
608     in the installer, perhaps because of the way I used mkisofs.)
609     <p>
610     Execute the following commands in the emulator:
611     <pre>
612     # <b>fsck /dev/rz0a</b>
613     # <b>mount /</b>
614     # <b>passwd root</b>
615    
616 dpavlin 6 # <b>cd /; mount -t cd9660 /dev/rz2c /mnt; sh</b>
617 dpavlin 2 # <b>for a in /mnt/[xX]*; do tar zxvf $a; done</b>
618     # <b>ln -s /usr/X11R6/bin/Xcfbpmax /usr/X11R6/bin/X</b>
619     # <b>ln -s /dev/fb0 /dev/mouse</b>
620     # <b>echo /usr/X11R6/lib >> /etc/ld.so.conf</b>
621     # <b>ldconfig</b>
622    
623     # <b>sync</b>
624     # <b>halt</b>
625     </pre>
626     </ol>
627    
628     <p>
629     NOTE: It is also possible to install via ftp instead of using a CDROM image.
630     This is not much less awkward, you still need the simpleroot filesystem
631     image, and you still have to manually add the X11 install sets and set the
632     root password, and so on.
633    
634     <p>
635     Once you have completed the installation procedure, the following command
636     will let you boot from the new rootdisk image:
637     <pre>
638 dpavlin 4 $ <b>gxemul -E dec -e 3max -b -X -M64 -o '-aN' -d obsd_pmax.img -j bsd</b>
639 dpavlin 2 </pre>
640    
641     <p>
642 dpavlin 6 (Normally, you would be asked about which root device to use (<tt>rz0</tt>),
643     but using <b><tt>-o '-aN'</tt></b> supresses that.)
644 dpavlin 2
645     <p>
646     When asked for which terminal type to use, when logging in as root,
647 dpavlin 6 enter <b><tt>rcons</tt></b> if you are using the graphical framebuffer,
648     <b><tt>vt100</tt></b> for text-mode.
649     <br>Use <b><tt>startx</tt></b> to start X windows.
650 dpavlin 2
651    
652    
653    
654    
655    
656     <p><br>
657     <a name="openbsdarcinstall"></a>
658 dpavlin 4 <h3>Installing OpenBSD/arc in GXemul:</h3>
659 dpavlin 2
660     It is possible to run OpenBSD/arc on an emulated Acer PICA-61 in the
661     emulator.
662    
663     <p>
664 dpavlin 4 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
665     <a href="20041024-openbsd-arc-installed.gif"><img src="20041024-openbsd-arc-installed_small.gif"></a>
666    
667     <p>
668 dpavlin 2 (You should be aware of the fact that OpenBSD for the ARC platform died at
669     release 2.3, so this will not give you an up-to-date OpenBSD system.
670     See
671     <a href="http://www.openbsd.org/arc.html">http://www.openbsd.org/arc.html</a>
672     for more information.)
673    
674     <p>
675     To install OpenBSD/arc onto an emulated harddisk image, follow these
676     instructions:
677    
678     <p>
679     <ol>
680     <li>Create an empty harddisk image, which will be the root disk
681     that OpenBSD installs itself onto:<pre>
682     $ <b>dd if=/dev/zero of=obsd_arc.img bs=1024 count=1 seek=700000</b>
683    
684     </pre>
685     <li>Download the entire arc directory from the ftp server: (approx. 75 MB)<pre>
686     $ <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>
687    
688     </pre>
689    
690     <li>You now need to make an ISO image of the entire directory you downloaded.
691 dpavlin 6 I recommend using <tt>mkisofs</tt> for that purpose. If you don't
692     already have <tt>mkisofs</tt> installed on your system, you need
693     to install it in order to do this.<pre>
694 dpavlin 2 $ <b>mkisofs -o openbsd_arc_2.3.iso ftp.se.openbsd.org/pub/OpenBSD/</b>
695    
696     </pre>
697     <li>Start the emulator using this command line:<pre>
698 dpavlin 6 $ <b>gxemul -X -b -E arc -e pica -d obsd_arc.img -d b:openbsd_arc_2.3.iso -j 2.3/arc/bsd.rd</b>
699 dpavlin 2
700     </pre>
701     and proceed like you would do if you were installing OpenBSD
702     on a real Acer PICA-61. (Answer 'no' when asked if you want to
703     configure networking, and then install from CD-ROM.)
704     </ol>
705    
706     <p>
707     Once the install has finished, the following command should let you
708     boot from the harddisk image:
709     <p>
710     <pre>
711     $ <b>gxemul -X -b -E arc -e pica -d obsd_arc.img ftp.se.openbsd.org/pub/OpenBSD/2.3/arc/bsd</b>
712    
713     </pre>
714    
715    
716    
717    
718    
719     <!--
720    
721     <p><br>
722     <a name="openbsdsgiinstall"></a>
723 dpavlin 4 <h3>Running OpenBSD/sgi in GXemul:</h3>
724 dpavlin 2
725     <a href="http://www.openbsd.org/sgi.html">OpenBSD/sgi</a>
726     can theoretically run in GXemul on an emulated O2 (SGI-IP32) with root on nfs.
727    
728     <p>
729     <font color="#ff0000">NOTE: I haven't succeeded with this yet.</font>
730    
731     <p>
732     GXemul does not yet emulate the AHC PCI SCSI controller in the O2, so
733     another emulated machine must be used as the nfs root server, and the
734     emulated O2 machine must boot as a
735     <a href="http://www.openbsd.org/cgi-bin/man.cgi?query=diskless&manpath=OpenBSD+Current&format=html">diskless</a>
736     client. Performing this setup is very time consuming, but necessary.
737    
738     <p>
739     <ol>
740 dpavlin 6 <li><a href="#netbsdinstall">Install NetBSD/pmax 2.0 from CDROM</a>
741     (or install some other similar OS) inside the emulator. This will
742     be the "nfs server" machine. Create a 600 MB <tt>/tftpboot</tt>
743     partition during the installation.
744 dpavlin 2 <p>
745     <li>Configure the nfs server machine to act as an nfs server.<pre>
746 dpavlin 6 # <b>echo hostname=server &gt;&gt; /etc/rc.conf</b>
747     # <b>echo ifconfig_le0=\"inet 10.0.0.2\" &gt;&gt; /etc/rc.conf</b>
748 dpavlin 2 # <b>echo nameserver 10.0.0.254 &gt;&gt; /etc/rc.conf</b>
749     # <b>echo 10.0.0.254 &gt; /etc/mygate</b>
750 dpavlin 6 # <b>echo /tftpboot -maproot=root 10.0.0.1 &gt; /etc/exports</b>
751 dpavlin 2 # <b>echo rpcbind=YES &gt;&gt; /etc/rc.conf</b>
752     # <b>echo nfs_server=YES &gt;&gt; /etc/rc.conf</b>
753     # <b>echo mountd=YES &gt;&gt; /etc/rc.conf</b>
754     # <b>echo bootparamd=YES &gt;&gt; /etc/rc.conf</b>
755 dpavlin 6 # <b>printf "client root=10.0.0.2:/tftpboot \\\n swap=10.0.0.2:/tftpboot/swap\n" &gt; /etc/bootparams</b>
756 dpavlin 2 # <b>echo 10.0.0.1 client &gt; /etc/hosts</b>
757    
758 dpavlin 6 Reboot. Then download the OpenBSD/sgi distribution: (NOTE: This
759     takes quite some time, even if you have a fast network connection.)
760 dpavlin 2
761 dpavlin 6 # <b>cd /tftpboot; ftp -i ftp.se.openbsd.org</b>
762 dpavlin 2 ...
763 dpavlin 6 <b>cd pub/OpenBSD/3.7/sgi</b>
764 dpavlin 2 <b>mget *</b>
765    
766     # <b>sh</b>
767     # <b>for a in base* etc* misc*; do tar vzxfp $a; done</b>
768     # <b>dd if=/dev/zero of=swap bs=1024 count=16384</b>
769    
770     </pre>
771     <p>
772     <li>Create a configuration file along these lines:<pre>
773     <font color="#2020cf">!!gxemul
774     !
775     ! Configuration file for running OpenBSD/sgi diskless with
776     ! a NetBSD/pmax machine as the nfs server.
777     !
778     ! Change the filenames to suit your setup.</font>
779    
780     <b>emul(
781     net()
782    
783     machine(
784     name("client machine")
785     type("sgi")
786     subtype("ip32")
787     bintrans(yes)
788     load("openbsd-sgi-20050202-bsd")
789     start_paused(yes)
790     )
791    
792     machine(
793     name("nfs server")
794     type("dec")
795     subtype("5000/200")
796     bintrans(yes)
797     disk("nbsd_pmax.img")
798     )
799     )</b>
800    
801     </pre>
802     <li>Boot the nfs server and the OpenBSD/sgi client machine like this:<pre>
803     $ <b>gxemul @myconf</b>
804    
805     </pre>
806     You might want to log in as root on the server machine, and
807     run <b>tcpdump -lnvv</b> or similar, to see that what the client
808     machine actually does on the network.
809     <p>
810     The OpenBSD box ("client machine") will be paused, so when you
811     are ready to unpause it, press CTRL-C in the main GXemul
812     window and use the <b>focus</b> and <b>pause</b> commands to
813     unpause the main CPU in that machine, and then <b>continue</b>
814     to resume execution.
815     <p>
816     When asked for "root device :", enter <b>mec0</b>.
817     </ol>
818    
819     <p>
820     TODO...
821    
822     -->
823    
824    
825    
826    
827    
828     <p><br>
829     <a name="ultrixinstall"></a>
830 dpavlin 4 <h3>Installing Ultrix/RISC in GXemul:</h3>
831 dpavlin 2
832 dpavlin 4 Ultrix 4.x can run in GXemul on an emulated DECstation 5000/200.
833 dpavlin 2
834 dpavlin 4 <p>
835     &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
836     <a href="20040504-ultrix45-boot1.png"><img src="20040504-ultrix45-boot1_small.gif"></a>
837     &nbsp;&nbsp;&nbsp;
838     <a href="ultrix4.5-20040706.png"><img src="ultrix4.5-20040706_small.gif"></a>
839    
840     <p>
841     The following instructions should let you install Ultrix onto a disk image:
842    
843 dpavlin 2 <ol>
844     <li>Create an empty harddisk image, which will be the root disk
845     that Ultrix installs itself onto:<pre>
846     $ <b>dd if=/dev/zero of=rootdisk.img bs=1024 count=1 seek=800000</b>
847    
848     </pre>
849 dpavlin 6 <li>Place your Ultrix installation media in your CDROM drive.
850     (On FreeBSD and similar systems, it is called <tt>/dev/cd0c</tt>.
851     Replace that with the name of your CDROM drive, or the name of a
852     .iso image file.) Then, start the emulator like this:<pre>
853 dpavlin 2 $ <b>gxemul -X -b -M64 -E dec -e 3max -d rootdisk.img -d bc:/dev/cd0c -j vmunix</b>
854    
855     </pre>
856     <li>Once the first stage of the installation is done (restoring the root
857     filesystem), you need to restart the emulator, booting from the
858     new rootdisk, to continue the installation process.
859 dpavlin 6 This is done by removing the bootflag ('<tt>b</tt>') from the second
860 dpavlin 2 diskimage argument:<pre>
861     $ <b>gxemul -X -b -M64 -E dec -e 3max -d rootdisk.img -d c:/dev/cd0c -j vmunix</b>
862    
863     </pre>
864     </ol>
865    
866     <p>
867     When the installation is completed, the following command should start
868     Ultrix from the harddisk image:<pre>
869     $ <b>gxemul -X -b -M64 -E dec -e 3max -j vmunix -d rootdisk.img</b>
870     </pre>
871    
872     <p>
873     Ultrix mostly seems to work with dynamic binary translation (enabled by
874 dpavlin 6 the <b><tt>-b</tt></b> command line option). If you have a very fast
875 dpavlin 2 host machine, and use bintrans, you might experience a weird timer related
876     bug, which makes it impossible to logon to the system. It is triggered
877     when the emulation goes faster than any real DECstation machine was
878 dpavlin 6 capable of running. A temporary workaround is to add <b><tt>-I33000000</tt></b>
879 dpavlin 2 to fix the emulated clock speed to 33 million instructions per emulated
880 dpavlin 6 second. (When using <tt><b>-CR4400</b></tt>, <b><tt>-I16000000</tt></b>
881     should be used instead.)
882 dpavlin 2
883     <p>
884 dpavlin 6 You can experiment with adding <b><tt>-Z2</tt></b> (for emulating a
885     dual-headed workstation) or even <b><tt>-Z3</tt></b> (tripple-headed), and
886     also the <b><tt>-Y2</tt></b> option for scaling down the framebuffer
887     windows by a factor 2x2.
888     There is also a <b><tt>-z</tt></b> option for supplying names of X11
889     displays to use. The following example starts Ultrix on an emulated
890     tripple-headed workstation, on three different displays (<tt>remote1:0.0</tt>,
891     <tt>localhost:0.0</tt>, and <tt>remote2:0.0</tt>), using no scaledown:<pre>
892 dpavlin 2 $ <b>gxemul -M64 -bN -E dec -e 3max -jgenvmunix -d rootdisk.img \
893 dpavlin 6 -XZ3 -z remote1:0.0 -z localhost:0.0 -z remote2:0.0</b>
894 dpavlin 2 </pre>
895    
896     <p>
897 dpavlin 6 The photo below shows a single Ultrix session running tripple-headed in
898     GXemul on an Alpha 21164PC, with displays on a Sun Ultra1 (to the left),
899     on the Alpha itself (in the middle), and on an HP700/RX X-terminal (8-bit
900     color depth, running off the Alpha) to the right.
901    
902     <p>
903     &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
904     <a href="20041209-ultrix-tripplehead.jpg"><img src="20041209-ultrix-tripplehead_small.jpg"></a>
905    
906     <p>
907 dpavlin 2 The X11 displays may differ in bit depth and endianness. Unfortunately,
908     there is no way yet to set the scaledown factor on a per-window basis, so
909     the scaledown factor affects all windows.
910    
911     <p>
912 dpavlin 6 (If you didn't use <tt><b>-Z<i>n</i></b></tt> during the installation, and
913     compiled your own <tt>/vmunix</tt>, then it will not contain support for
914     multiple graphics cards. To overcome this problem, use the generic kernel,
915     <tt><b>-j genvmunix</b></tt>, whenever you are running the emulator with a
916     different setup than the one you used when Ultrix was installed.)
917 dpavlin 2
918 dpavlin 4 <p>
919     A note for the historically interested: OSF/1 for MIPS was quite similar
920     to Ultrix, so that is possible to run as well. If you are unsuccessful
921     in installing Ultrix or OSF/1 directly in the emulator, you can always
922     install it on your real machine onto a real SCSI disk, and then copy the
923 dpavlin 6 contents of that SCSI disk into a file (using <b><tt>dd(1)</tt></b>), and use
924 dpavlin 4 that file as a disk image file in the emulator.
925 dpavlin 2
926    
927    
928    
929    
930    
931     <p><br>
932     <a name="sprite"></a>
933 dpavlin 4 <h3>Running Sprite for DECstation in GXemul:</h3>
934 dpavlin 2
935     Sprite was a research operating system at the University of Berkeley.
936     The Unix Heritage Society (TUHS, <a href="http://www.tuhs.org">www.tuhs.org</a>)
937     has made available a copy of a Sprite harddisk image for a DECstation 5000/200.
938     If you want to find out more about Sprite in general, read
939     <a href="http://www.cs.berkeley.edu/projects/sprite/retrospective.html">
940     http://www.cs.berkeley.edu/projects/sprite/retrospective.html</a>.
941    
942     <p>
943 dpavlin 4 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
944     <a href="20040711-sprite-1.png"><img src="20040711-sprite-1_small.png"></a>
945     &nbsp;&nbsp;&nbsp;
946     <a href="sprite-20040711.png"><img src="sprite-20040711_small.png"></a>
947    
948     <p>
949 dpavlin 2 The following instructions should let you run Sprite in the emulator:
950    
951     <p>
952     <ol>
953     <li>Download the Sprite harddisk image using ftp or http:<pre>
954     <a href="http://www.es.embnet.org/Services/ftp/misc/TUHS/other_os/Sprite/">http://www.es.embnet.org/Services/ftp/misc/TUHS/other_os/Sprite</a>/<a href="http://www.es.embnet.org/Services/ftp/misc/TUHS/other_os/Sprite/ds5000.bt">ds5000.bt</a>
955 dpavlin 8 or <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>
956 dpavlin 2 83973120 bytes, MD5 = ec84eeeb20fe77b758370d5e312e4a5e
957    
958     </pre>
959     <li>Start the emulator with the following command line:<pre>
960     $ <b>gxemul -X -b -E dec -e 3max -M128 -d ds5000.bt -j vmsprite -o ''</b>
961    
962     </pre>
963     </ol>
964    
965     <p>
966     The first time you boot up with the disk image, you will be asked a number
967     of questions regarding network settings. If you feel like entering correct
968     values, then you should use the following:
969     <p>
970    
971     <pre>
972     Your machine's Ethernet address: 10:20:30:40:50:60
973     Your machine's IP: 10.0.0.1
974     Subnet mask: 0xff000000
975     Gateway's Ethernet address: 60:50:40:30:20:10
976     Gateway's IP: 10.0.0.254
977     </pre>
978    
979     <p>
980     Unfortunately, at the end of <a href="http://www.es.embnet.org/Services/ftp/misc/TUHS/other_os/Sprite/boot.txt">
981     http://www.es.embnet.org/Services/ftp/misc/TUHS/other_os/Sprite/boot.txt</a>, the
982     following sad statement can be found:
983     <pre>
984     The bootable Sprite image is meant to be a demonstration of Sprite, not
985     a robust Sprite system. There are several missing things, such as
986     floating point and network support.
987     </pre>
988    
989     <p>
990     Once you are logged in as root, running <b>xinit</b> will start the X11
991     environment.
992    
993    
994    
995    
996    
997     <p><br>
998     <a name="declinux"></a>
999 dpavlin 4 <h3>Installing Debian GNU/Linux for DECstation in GXemul:</h3>
1000 dpavlin 2
1001 dpavlin 4 <font color="#ef0000">NOTE: This is experimental, and <i>extremely</i>
1002 dpavlin 2 unstable. During my tests, even pressing the wrong key during the install
1003     (for example the wrong cursor key) can cause a kernel Oops.
1004     I <i>think</i> this has to do with interrupts from the serial controller.
1005 dpavlin 6 Hopefully using the <tt><b>-U</b></tt> command line option will reduce the
1006     risk for such crashes. (I haven't had time to come up with a clean
1007     solution to this yet; it feels like a buffer overflow in Linux' serial
1008     driver for the 5000/200, but it is also likely that it is a bug in GXemul.)
1009 dpavlin 2 </font>
1010    
1011     <p>
1012 dpavlin 4 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1013     <a href="20041212-debian_1.png"><img src="20041212-debian_1_small.gif"></a>
1014     &nbsp;&nbsp;&nbsp;
1015     <a href="20041212-debian_2.png"><img src="20041212-debian_2_small.gif"></a>
1016     &nbsp;&nbsp;&nbsp;
1017     <a href="20041213-debian_3.png"><img src="20041213-debian_3_small.gif"></a>
1018     &nbsp;&nbsp;&nbsp;
1019     <a href="20041213-debian_4.png"><img src="20041213-debian_4_small.gif"></a>
1020    
1021     <p>
1022 dpavlin 2 The following steps should let you install Debian GNU/Linux for DECstation
1023     onto a harddisk image:
1024    
1025     <p>
1026     <ol>
1027     <li>Create an empty harddisk image, which will be the root disk
1028     that Debian installs itself onto:<pre>
1029     $ <b>dd if=/dev/zero of=debian.img bs=1024 count=1 seek=2000000</b>
1030    
1031     </pre>
1032     <li>Download an install kernel:<pre>
1033     <a href="http://http.us.debian.org/debian/dists/testing/main/installer-mipsel/current/images/r3k-kn02/boot.img">http://http.us.debian.org/debian/dists/testing/main/</a>
1034     <a href="http://http.us.debian.org/debian/dists/testing/main/installer-mipsel/current/images/r3k-kn02/boot.img">installer-mipsel/current/images/r3k-kn02/boot.img</a>
1035     or
1036     <a href="http://http.us.debian.org/debian/dists/unstable/main/installer-mipsel/current/images/r3k-kn02/boot.img">http://http.us.debian.org/debian/dists/unstable/main/</a>
1037     <a href="http://http.us.debian.org/debian/dists/unstable/main/installer-mipsel/current/images/r3k-kn02/boot.img">installer-mipsel/current/images/r3k-kn02/boot.img</a>
1038    
1039     </pre>
1040     depending on whether you want to install Debian "Testing" or
1041     "Unstable".
1042     <p>
1043     <li>For a text-mode installation, start the emulator like this:<pre>
1044     $ <b>gxemul -E dec -e 3max -b -U -M64 -o 'console=ttyS3' -d debian.img -O boot.img</b>
1045    
1046     </pre>
1047     </ol>
1048    
1049     <p>
1050     Debian GNU/Linux on DECstation works reasonably fine with dynamic
1051 dpavlin 6 binary translation, enabled by the <b><tt>-b</tt></b> command line option.
1052     (Without this option, the emulator might be less buggy, but also too slow
1053     to be useful when running Linux as a guest OS.)
1054 dpavlin 2
1055     <p>
1056     (If you want to, you can try <b>-X</b> instead of <b>-o 'console=ttyS3'</b> on
1057     the command line. This will cause Linux to use the graphical framebuffer.
1058     Unfortunately, Linux does not seem to have a driver for the DZ11 keyboard
1059     controller yet, so you cannot interact with the system. You will see the
1060     penguin in the upper lefthand corner while booting, and nicely rendered Unicode
1061     characters, but that's about it.)
1062    
1063     <p>
1064     You need to enter some values during the installation procedure, for example
1065     network settings. The following should work:
1066     <p>
1067     <pre>
1068     DHCP: No, choose "Configure network manually"
1069     IP address: 10.0.0.1
1070     Netmask: 255.0.0.0
1071     Gateway: 10.0.0.254
1072     Name server addresses: 10.0.0.254
1073     </pre>
1074    
1075     <p>
1076     <ol start="4">
1077     <li>Once the first phase of the install has finished, the following command
1078     should let you boot into Debian, and perform post-install
1079     configuration:<pre>
1080     $ <b>gxemul -E dec -e 3max -U -b -M64 -o 'console=ttyS3' -d debian.img</b>
1081    
1082     </pre>
1083     </ol>
1084    
1085     <p>
1086     It seems that there's a problem with getting a login prompt on serial
1087     console (at least when I've done test installs), so when the installation
1088     is finished and you're supposed to get a login prompt, you need to press
1089     CTRL-C and type <b>quit</b>, and then:
1090    
1091     <p>
1092     <ol start="5">
1093     <li>Download a normal kernel (<i>not</i> a RAMDISK kernel):<pre>
1094     <a href="http://http.us.debian.org/debian/dists/testing/main/installer-mipsel/current/images/cdrom/vmlinux-2.4.27-r3k-kn02">http://http.us.debian.org/debian/dists/testing/main/</a>
1095     <a href="http://http.us.debian.org/debian/dists/testing/main/installer-mipsel/current/images/cdrom/vmlinux-2.4.27-r3k-kn02">installer-mipsel/current/images/cdrom/vmlinux-2.4.27-r3k-kn02</a>
1096    
1097     </pre>
1098     <li>Boot Debian using the following command line:<pre>
1099     $ <b>gxemul -E dec -e 3max -U -b -M64 -o \
1100     'console=ttyS3 root=/dev/sda1 rw init=/bin/sh' \
1101     -d debian.img vmlinux-2.4.27-r3k-kn02</b>
1102    
1103     </pre>
1104     You'll enter single-user mode. You need to add a line to
1105     /etc/inittab, to enable logins via serial console.<pre>
1106     sh-2.05b# <b>echo 'T3:23:respawn:/sbin/getty -L ttyS3 9600 vt100' >> /etc/inittab</b>
1107     sh-2.05b# <b>echo 'ttyS3' >> /etc/securetty</b>
1108     sh-2.05b# <b>sync; umount /</b>
1109     </pre>
1110     </ol>
1111    
1112     <p>
1113     The system should now be ready for everyday use.
1114    
1115     <p>
1116     Use this command to boot from the completely installed disk image:<pre>
1117     $ <b>gxemul -E dec -e 3max -U -b -M64 -o 'console=ttyS3' -d debian.img</b>
1118    
1119     </pre>
1120    
1121     <p>
1122     [&nbsp;<font color="#ff0000">UPDATE 2005-01-19:</font>&nbsp;
1123     Kaj-Michael Lang noticed that the current CVS-version of
1124     <a href="http://www.linux-mips.org/">linux-mips</a> has
1125     support for keyboards now, on DECstation 5000/200, so it is
1126     possible to run Debian GNU/Linux with framebuffer/keyboard.
1127 dpavlin 6 (Add <b><tt>-X</tt></b> (or <b><tt>-XY2</tt></b>) and remove the
1128     <b><tt>console=ttyS3</tt></b> option.) He has made a kernel available here:
1129     <a href="http://home.tal.org/~milang/o2/kernels/vmlinux-2.4.29-rc2-r3k-mipsel-decstation">
1130     http://home.tal.org/~milang/o2/kernels/vmlinux-2.4.29-rc2-r3k-mipsel-decstation</a>
1131 dpavlin 2 It has other problems (ethernet doesn't seem to work, for
1132     example), but at least it doesn't Oops that often.&nbsp;]
1133    
1134    
1135    
1136    
1137    
1138    
1139     <p><br>
1140     <a name="declinuxredhat"></a>
1141 dpavlin 4 <h3>Running Redhat Linux for DECstation in GXemul:</h3>
1142 dpavlin 2
1143     <font color="#ff0000">NOTE: This is experimental, and <i>extremely</i>
1144 dpavlin 6 unstable. Read the note about <b><tt>-U</tt></b> in the section on how to
1145     install Debian.
1146 dpavlin 2 </font>
1147    
1148 dpavlin 4 <p>
1149     &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1150     <a href="20041129-redhat_mips.png"><img src="20041129-redhat_mips_small.png"></a>
1151 dpavlin 2
1152     <p>
1153     The following steps should let you run Redhat Linux for DECstation in GXemul:
1154    
1155     <p>
1156     <ol>
1157     <li>Download a kernel. This is a Debian kernel, but it works fine:<pre>
1158     <a href="http://http.us.debian.org/debian/dists/testing/main/installer-mipsel/current/images/cdrom/vmlinux-2.4.27-r3k-kn02">http://http.us.debian.org/debian/dists/testing/main/</a>
1159     <a href="http://http.us.debian.org/debian/dists/testing/main/installer-mipsel/current/images/cdrom/vmlinux-2.4.27-r3k-kn02">installer-mipsel/current/images/cdrom/vmlinux-2.4.27-r3k-kn02</a>
1160    
1161     </pre>
1162     <li>Download a root filesystem tree:<pre>
1163     <a href="ftp://ftp.uni-wuppertal.de/pub/linux/mips/mipsel-linux/root/mipsel-root-20011216.tgz">ftp://ftp.uni-wuppertal.de/pub/linux/mips/</a>
1164     <a href="ftp://ftp.uni-wuppertal.de/pub/linux/mips/mipsel-linux/root/mipsel-root-20011216.tgz">mipsel-linux/root/mipsel-root-20011216.tgz</a>
1165     19486676 bytes, md5 = 5bcb725c90209479cd7ead8ad0c4a414
1166    
1167     </pre>
1168     <li>This is the tricky part: Create an ext2 filesystem image called redhat.img using
1169     the filesystem tree you just downloaded. The disk image should have a MS-DOS
1170     partition table (!), and then one or more ext2 partitions.
1171     (Use loopback mount, or similar. This is probably easiest to do on a Linux host.)
1172     However, in order to actually boot the system you need to modify /etc/fstab.
1173     Change<pre>
1174     /dev/root / nfs defaults 1 1
1175     #/dev/sdc1 / ext2 defaults 1 1
1176     none /proc proc defaults 0 0
1177     none /dev/pts devpts mode=0622 0 0
1178    
1179     </pre>to<pre>
1180     #/dev/root / nfs defaults 1 1
1181     /dev/sda1 / ext2 defaults 1 1
1182     none /proc proc defaults 0 0
1183     none /dev/pts devpts mode=0622 0 0
1184    
1185     </pre>(Note sda1 instead of sdc1.)
1186     <p>
1187     <li>To boot Linux, start the emulator like this:<pre>
1188     $ <b>gxemul -E dec -e 3max -U -b -M128 -o \
1189     "console=ttyS3 root=/dev/sda1 ro" -d redhat.img vmlinux-2.4.27-r3k-kn02</b>
1190    
1191     </pre>
1192     </ol>
1193    
1194     <p>
1195     If you need to boot into single user mode, try the following:<pre>
1196     $ <b>gxemul -E dec -e 3max -U -b -o "console=ttyS3 root=/dev/sda1 rw init=/bin/sh" \
1197     -d redhat.img vmlinux-2.4.27-r3k-kn02</b>
1198    
1199     </pre>
1200    
1201     <p>
1202     Redhat Linux on DECstation in R3000 mode should work fine with dynamic binary
1203     translation (enabled by the <b>-b</b> command line option).
1204    
1205     <p>
1206     NOTE: You can add <b>-X</b> and remove <b>console=ttyS3</b> from the command
1207     line, if you want to use a graphical framebuffer. Unfortunately, Linux
1208     doesn't have support for keyboards on DECstation 5000/200 yet, so you cannot
1209     actually interact with the sytem. :-(
1210    
1211     <p>
1212     [&nbsp;<font color="#ff0000">UPDATE 2005-01-22:</font>&nbsp;
1213     Read the 2005-01-19 update in the Debian section above, and then, if
1214     you do not need ethernet support, try Kaj-Michael Lang's kernel compiled
1215     from <a href="http://www.linux-mips.org/">linux-mips</a>' CVS.
1216     <a href="http://home.tal.org/~milang/o2/patches/vmlinux-2.4.29-rc2-r3k-mipsel-decstation">
1217     http://home.tal.org/~milang/o2/patches/vmlinux-2.4.29-rc2-r3k-mipsel-decstation</a>
1218     It should work with framebuffer/keyboard.&nbsp;]
1219    
1220    
1221    
1222    
1223    
1224    
1225     <p><br>
1226     <a name="mach"></a>
1227 dpavlin 4 <h3>Running Mach/PMAX in GXemul:</h3>
1228 dpavlin 2
1229     Read the following link if you want to know more about Mach in general:
1230     <a href="http://www-2.cs.cmu.edu/afs/cs/project/mach/public/www/mach.html">
1231     http://www-2.cs.cmu.edu/afs/cs/project/mach/public/www/mach.html</a>
1232    
1233     <p>
1234     <font color="#ff0000">NOTE: Mach for DECstation requires some files
1235     (called 'startup' and 'emulator') which I haven't been able to find
1236     on the web. Without these, Mach will not get very far. These
1237     installation instructions are preliminary.
1238     </font>
1239    
1240     <p>
1241 dpavlin 4 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
1242     <a href="20041018-mach_pmax.png"><img src="20041018-mach_pmax_small.png"></a>
1243    
1244     <p>
1245 dpavlin 2 The following steps should let you experiment with running Mach
1246     for DECstation in the emulator:
1247    
1248     <p>
1249     <ol>
1250     <li>Compile gxemul with cache emulation: (<b>NOTE: --enable-caches</b>)<pre>
1251     $ <b>./configure --enable-caches; make</b>
1252    
1253     </pre>
1254     <li>Download the pmax binary distribution for Mach 3.0:<pre>
1255     <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/daveg/Info/Links/Mach/src/release/pmax.tar.Z</a>
1256     7263343 bytes, md5 = f9d76c240a6e169921a1df99ad560cc0
1257    
1258     </pre>
1259     <li>Extract the Mach kernel:<pre>
1260     $ <b>tar xfvz pmax.tar.Z pmax_mach/special/mach.boot.MK83.STD+ANY</b>
1261    
1262     </pre>
1263     <li>Create an empty disk image:<pre>
1264     $ <b>dd if=/dev/zero of=disk.img bs=1 count=512 seek=400000000</b>
1265    
1266     </pre>
1267     <li>Load the contents of pmax.tar.Z onto the disk image. This is
1268     complicated, and should be described in more detail some time.
1269     For now, use your imagination. (For example using OpenBSD/pmax:
1270     <i>disklabel -E rz1; newfs -O /dev/rz1a;
1271     mount /dev/rz1a /mnt; cd /mnt; download pmax.tar.Z using ftp;
1272     tar xzvf pmax.tar.Z; mv pmax_mach/* .; rmdir pmax_mach;
1273     mkdir mach_servers;
1274     cd mach_servers;
1275     cp ../etc/mach_init .;
1276     cp ../tests/test_service startup;
1277     dd if=/dev/zero of=paging_file bs=65536 count=400;
1278     cd /; sync; umount /mnt</i>)
1279     <p>
1280     <li>Start the emulator with the following command:<pre>
1281     $ <b>gxemul -E dec -e 3max -X -d disk.img \
1282     pmax_mach/special/mach.boot.MK83.STD+ANY</b>
1283    
1284     </pre>
1285     </ol>
1286    
1287    
1288    
1289    
1290    
1291    
1292    
1293    
1294     </p>
1295    
1296     </body>
1297     </html>

  ViewVC Help
Powered by ViewVC 1.1.26