/[gentoo]/xml/htdocs/doc/en/uml.xml
Gentoo

Diff of /xml/htdocs/doc/en/uml.xml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.10 Revision 1.22
1<?xml version='1.0' encoding="UTF-8"?> 1<?xml version='1.0' encoding="UTF-8"?>
2<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/uml.xml,v 1.22 2005/02/05 16:52:57 swift Exp $ -->
2 3
3<!DOCTYPE guide SYSTEM "/dtd/guide.dtd"> 4<!DOCTYPE guide SYSTEM "/dtd/guide.dtd">
4 5
5<guide link="/doc/en/uml.xml"> 6<guide link="/doc/en/uml.xml">
6<title>Gentoo Linux Developer's guide to system testing with User-Mode Linux</title> 7<title>Gentoo Linux Developer's guide to system testing with User-Mode Linux</title>
8<author title="Editor">
7<author title="Editor"><mail link="g2boojum@gentoo.org">Grant Goodyear</mail></author> 9 <mail link="g2boojum@gentoo.org">Grant Goodyear</mail>
10</author>
8<author title="Editor"><!-- zhen@gentoo.org --> 11<author title="Editor"><!-- zhen@gentoo.org -->
9 John Davis 12 John Davis
10</author> 13</author>
11
12<author title="Editor"> 14<author title="Editor">
13 <mail link="swift@gentoo.org">Sven Vermeulen</mail> 15 <mail link="swift@gentoo.org">Sven Vermeulen</mail>
14</author> 16</author>
15<author title="Editor"> 17<author title="Editor">
16 <mail link="bennyc@gentoo.org">Benny Chuang</mail> 18 <mail link="bennyc@gentoo.org">Benny Chuang</mail>
17</author> 19</author>
18 20
19<abstract> 21<abstract>
20 This guide shows Gentoo Linux developers how to set up and use 22This guide shows Gentoo Linux developers how to set up and use
21 user-mode linux for testing potentially system-breaking changes. 23user-mode linux for testing potentially system-breaking changes.
22</abstract> 24</abstract>
23 25
24<license/> 26<license/>
25 27
26<version>0.2</version> 28<version>0.10</version>
27<date>October 24, 2003</date> 29<date>2005-02-05</date>
28 30
29<chapter> 31<chapter>
30<title>Obtaining User-Mode Linux</title> 32<title>Obtaining User-Mode Linux</title>
31<section> 33<section>
32<body> 34<body>
35
36<p>
33<p>As the user-mode linux website 37As the user-mode linux website
34(<uri>http://user-mode-linux.sourceforge.net</uri>) 38(<uri>http://user-mode-linux.sourceforge.net</uri>) states, user-mode linux
35states, user-mode linux
36allows a user to "run Linux inside itself". Specifically, 39allows a user to "run Linux inside itself". Specifically,
37user-mode linux provides a virtual machine on which a user can "[r]un buggy 40user-mode linux provides a virtual machine on which a user can "[r]un buggy
38software, experiment with new Linux kernels or distributions, and poke around 41software, experiment with new Linux kernels or distributions, and poke around
39in the internals of Linux, all without risking your main Linux setup." Changes 42in the internals of Linux, all without risking your main Linux setup."
40to Gentoo core packages such as <e>sys-apps/baselayout</e> or <e>sys-libs/glibc</e> 43Experimental changes to Gentoo core packages such as <e>sys-apps/baselayout</e>
41have the potential to break the system and render it unbootable; with user-mode 44or <e>sys-libs/glibc</e> have the potential to break the system and render it
42linux we can test these changes without having to worry about breaking the live 45unbootable; with user-mode linux we can test these changes without having to
43system. 46worry about breaking the live system.
44</p> 47</p>
48
45<p> 49<p>
46Installing user-mode linux is essentially identical to a normal kernel 50Installing user-mode linux is essentially identical to a normal kernel
47install. First install the kernel sources (appropriately patched for 51install. First install the kernel sources (appropriately patched for
48user-mode linux), and then configure the user-mode linux kernel in the 52user-mode linux), and then configure the user-mode linux kernel in the
49usual fashion: 53usual fashion. Since kernel 2.6.9, UML has been integrated in the vanilla
54kernel.
50</p> 55</p>
51<pre> 56
57<pre caption="Installing UML kernel sources">
58<comment>(We'll install the vanilla 2.6 kernel, you can also use the usermode-sources)</comment>
52# <i>emerge sys-kernel/usermode-sources</i> 59# <i>emerge sys-kernel/development-sources</i>
53# <i>cd /usr/src/uml/linux</i> 60# <i>cd /usr/src/linux</i>
54# <i>make menuconfig <comment>ARCH=um</comment></i> 61# <i>make menuconfig <comment>ARCH=um</comment></i>
55# <i>make linux <comment>ARCH=um</comment></i> 62# <i>make linux <comment>ARCH=um</comment></i>
56# <i>cp linux /usr/local/bin/linux</i> 63# <i>cp linux /usr/local/bin/linux</i>
57</pre> 64</pre>
65
66<warn>
58<warn>The <e>ARCH=um</e> fragment is <e>extremely</e> important!</warn> 67The <e>ARCH=um</e> fragment is <e>extremely</e> important!
59<impo> 68</warn>
69
70<p>
71Make sure that <path>/usr/local/bin</path> is in your path. Edit
72<path>/etc/env.d/00basic</path> to that the PATH variable contains
73<path>/usr/local/bin</path> and rerun <c>env-update</c>:
74</p>
75
76<pre caption="Editing 00basic">
77# <i>nano -w /etc/env.d/00basic</i>
78# <i>env-update</i>
79# <i>source /etc/profile</i>
80</pre>
81
82<p>
60For the user-mode linux kernel to properly boot a Gentoo system the 83For the user-mode linux kernel to properly boot a Gentoo system the
61kernel needs to be configured to <e>not</e> automatically mount 84kernel needs to be configured to <e>not</e> automatically mount
62<path>/dev</path> (devfs) by default. 85<path>/dev</path> (devfs) by default. Also, you will almost certainly
63Also, you will almost certainly
64want to make sure that you have <e>tmpfs</e> (the "Virtual Memory 86want to make sure that you have <e>tmpfs</e> (the "Virtual Memory
65Filesystem") compiled in, since by default the Gentoo linux bootscripts 87Filesystem") compiled in, since by default the Gentoo linux bootscripts
66store their information in a small tmpfs partition. 88store their information in a small tmpfs partition.
67(The binary kernels available 89(The binary kernels available from the user-mode website do automatically
68from the user-mode website do automatically mount <path>/dev</path>, 90mount <path>/dev</path>, and they don't have tmpfs compiled in; don't bother
69and they don't have tmpfs compiled in; don't bother with them.) 91with them).
70</impo> 92</p>
93
94<p>
71<p>I highly recommend reading the user-mode linux documentation, but the 95I highly recommend reading the user-mode linux documentation, but the
72basic idea is that running the <path>/usr/local/bin/linux</path> program 96basic idea is that running the <path>/usr/local/bin/linux</path> program
73boots the user-mode kernel and tries to bring up the system stored in 97boots the user-mode kernel and tries to bring up the system stored in
74the file <path>root_fs</path> that should be located in the current working 98the file <path>root_fs</path> that should be located in the current working
75directory.</p> 99directory.
100</p>
101
102<p>
76<p>It won't hurt to also install the user-mode linux tools.</p> 103It won't hurt to also install the user-mode linux tools.
77<pre> 104</p>
105
106<pre caption="Installing UML tools">
78# <i>emerge sys-apps/usermode-utilities</i> 107# <i>emerge sys-apps/usermode-utilities</i>
79</pre> 108</pre>
109
110<p>
80<p>These tools facilitate networking (among other things) 111These tools facilitate networking (among other things) between the user-mode
81between the user-mode linux virtual system 112linux virtual system and the host Linux system.
82and the host Linux system.</p> 113</p>
114
83</body> 115</body>
84</section> 116</section>
85</chapter> 117</chapter>
86 118
87<chapter> 119<chapter>
88<title>Creating <path>root_fs</path></title> 120<title>Creating root_fs</title>
89
90<section> 121<section>
91<title>Making the Gentoo chroot</title> 122<title>Making the Gentoo chroot</title>
92<body> 123<body>
124
93<p> 125<p>
94The <path>root_fs</path> file needed for user-mode linux is 126The <path>root_fs</path> file needed for user-mode linux is
95a single file that contains an entire Gentoo Linux filesystem. 127a single file that contains an entire Gentoo Linux filesystem.
96To generate this file you will need to have Loopback device 128To generate this file you will need to have Loopback device
97support enabled in the host (non-user-mode) kernel. 129support enabled in the host (non-user-mode) kernel.
98</p> 130</p>
131
132<p>
99<p>Generating the <path>root_fs</path> file itself will be 133Generating the <path>root_fs</path> file itself will be
100our last step. First we will generate a Gentoo filesystem in 134our last step. First we will generate a Gentoo filesystem in
101an ordinary chroot. We need the stage tarball available, which 135an ordinary chroot. We need the stage tarball available, which
102could be downloaded separately, extracted from a liveCD, or 136could be downloaded separately, extracted from a liveCD, or
103extracted from a liveCD .iso. 137extracted from a liveCD .iso.
104</p> 138</p>
139
105<pre caption="Mounting a liveCD .iso"> 140<pre caption="Mounting a liveCD .iso">
106# <i>mkdir /mnt/loop</i> 141# <i>mkdir /mnt/loop</i>
107# <i>mount -o loop /path/to/build-&lt;TAB&gt;.iso /mnt/loop</i> 142# <i>mount -o loop /path/to/install-&lt;TAB&gt;.iso /mnt/loop</i>
108</pre> 143</pre>
144
109<p> 145<p>
110Setting up the chroot is essentially identical to an ordinary Gentoo 146Setting up the chroot is essentially identical to an ordinary Gentoo
111Linux build. 147Linux build.
112</p> 148</p>
113<pre> 149
150<pre caption="Creating the Gentoo chroot mount">
114# <i>mkdir /mnt/gentoo</i> 151# <i>mkdir /mnt/gentoo</i>
115# <i>cd /mnt/gentoo</i> 152# <i>cd /mnt/gentoo</i>
116# <i>tar xvjpf /path/to/build-&lt;TAB&gt;.tar.bz2</i> 153# <i>tar xvjpf /path/to/stage&lt;TAB&gt;.tar.bz2</i>
117</pre> 154</pre>
155
118<p> 156<p>
119Go ahead and unmount the .iso. You don't need it anymore. 157Go ahead and unmount the .iso. You don't need it anymore.
120</p> 158</p>
121<pre> 159
122# <i>cp /etc/resolv.conf /mnt/gentoo/etc/</i>
123# <i>mount -o bind /proc /mnt/gentoo/proc</i>
124# <i>mkdir -p /mnt/gentoo/usr/portage/distfiles</i>
125# <i>mkdir -p /mnt/gentoo/usr/portage/packages</i>
126# <i>mount -o bind /usr/portage/distfiles /mnt/gentoo/usr/portage/distfiles</i>
127# <i>mount -o bind /usr/portage/packages /mnt/gentoo/usr/portage/packages</i>
128# <i>chroot /mnt/gentoo /bin/bash</i>
129<!--per bug 16134, added emerge sync to supress warning, etc-->
130# <i>emerge sync</i>
131# <i>env-update</i>
132# <i>source /etc/profile</i>
133</pre>
134<p>
135By bind-mounting <path>/usr/portage/distfiles</path> and
136<path>/usr/portage/packages</path> we avoid having to download
137or build packages that are already present on the Gentoo host.
138</p> 160<p>
161Bootstrap and build the system in the usual fashion. Just follow the
162installation instructions :)
139<p> 163</p>
140Bootstrap and build the system in the usual fashion: 164
141</p>
142<pre>
143<!--removed the emerge sync below because it is done above-->
144# <i>cd /usr/portage</i>
145# <i>nano -w /etc/make.conf</i>
146# <i>nano -w /etc/make.profile/packages</i>
147# <i>nano -w /usr/portage/profiles/package.mask</i>
148# <i>scripts/bootstrap.sh &amp;&amp; emerge --usepkg system</i>
149</pre>
150<warn>
151<!--Changed grub to virtual/bootloader-->
152The <path>/etc/make.profile/packages</path> file needs to be
153edited to remove the virtual/bootloader ebuild from the default system (just remove the "*"
154from the beginning of the "*virtual/bootloader" line). The virtual/bootloader ebuild
155tries to mount the /boot partition, which will fail in our chroot.
156</warn>
157<note>
158Make sure you examine <path>/etc/make.profile/packages</path>
159and <path>/usr/portage/profiles/package.mask</path> to be sure that
160any to-be-tested packages that you want to install aren't masked out.
161As currently written, <path>scripts/bootstrap.sh</path> will compile
162the bootstrap packages from source. To use already-existing packages,
163add <c>alias emerge="emerge --usepkg"</c> somewhere near the top of
164the bootstrap script.
165</note>
166<p> 165<p>
167Add any additional packages you desire. Feel free to give your virtual 166Add any additional packages you desire. Feel free to give your virtual
168Gentoo system a hostname, if you so desire. In <path>/etc/fstab</path> 167Gentoo system a hostname, if you so desire. In <path>/etc/fstab</path>
169you will want <path>/dev/ROOT</path> to be <path>/dev/ubd/0</path>, with 168you will want <path>/dev/ROOT</path> to be <path>/dev/ubd/0</path>, with
170a fs type of either ext2, ext3, or reiserfs. Set <path>/dev/SWAP</path> 169a fs type of either ext2, ext3, or reiserfs. Set <path>/dev/SWAP</path>
171to be <path>/dev/ubd/1</path>, and comment out <path>/dev/BOOT</path>. 170to be <path>/dev/ubd/1</path>, and comment out <path>/dev/BOOT</path>.
172</p> 171</p>
173 172
173<p>
174<p> At this point, remember to set your root password. </p> 174At this point, remember to set your root password.
175</p>
175 176
176<pre caption="Setting root password"> 177<pre caption="Setting root password">
177# <i>passwd</i> 178# <i>passwd</i>
178</pre> 179</pre>
179 180
180<p> 181<p>
182Now we need to make some changes to the boot scripts. Remove consolefont and
183keymaps from the boot runlevel:
184</p>
185
186<pre caption="Removing unneeded initscripts">
187# <i>rc-update del consolefont boot</i>
188# <i>rc-update del keymaps boot</i>
189</pre>
190
191<p>
181Exit the chroot, unmount all of the bind mounts, 192Exit the chroot, unmount all of the bind mounts,
182tar up the new Gentoo distro, and clean up: 193tar up the new Gentoo distro, and clean up.
183</p> 194</p>
184<pre> 195
185# <i>exit</i> 196<pre caption="Finalising the installation">
186# <i>umount /mnt/gentoo/usr/portage/distfiles</i>
187# <i>umount /mnt/gentoo/usr/portage/packages</i>
188# <i>umount /mnt/gentoo/proc</i>
189# <i>du -ks /mnt/gentoo</i>
190<!-- wtf is this? 261744 /mnt/gentoo-->
191<!-- added dir change to be more explicit-->
192# <i>cd /mnt/gentoo</i> 197# <i>cd /mnt/gentoo</i>
193# <i>tar cvjpf ~/gentoo.tbz2 *</i> 198# <i>tar cvjpf ~/gentoo.tbz2 *</i>
194# <i>cd</i> 199# <i>cd</i>
195# <i>rm -rf /mnt/gentoo</i> 200# <i>rm -rf /mnt/gentoo</i>
196</pre> 201</pre>
197 202
198<p>You might also want to consider reviewing the final steps of the
199<uri link="http://www.gentoo.org/doc/en/gentoo-x86-install.xml">Gentoo Linux x86 Installation Guide</uri>. </p>
200</body> 203</body>
201</section>
202
203<section> 204</section>
205<section>
204<title>Making <path>root_fs</path></title> 206<title>Making root_fs</title>
205<body> 207<body>
208
206<p> 209<p>
207Our Gentoo chroot is nearly 300 MB in size, so 210Our Gentoo chroot is nearly 300 MB in size, so
208<path>root_fs</path> needs to be at least that size. 211<path>root_fs</path> needs to be at least that size.
209We'll choose 0.5 GB as a reasonable size. 212We'll choose 0.5 GB as a reasonable size.
210</p> 213</p>
211<pre> 214
215<pre caption="Creating UML files">
212# <i>dd if=/dev/zero of=root_fs seek=500 count=1 bs=1M</i> 216# <i>dd if=/dev/zero of=root_fs seek=500 count=1 bs=1M</i>
213# <i>mke2fs -F root_fs</i> 217# <i>mke2fs -F root_fs</i>
214# <i>mount -o loop root_fs /mnt/loop</i> 218# <i>mount -o loop root_fs /mnt/loop</i>
215# <i>tar xvjpf gentoo.tbz2 -C /mnt/loop</i> 219# <i>tar xvjpf gentoo.tbz2 -C /mnt/loop</i>
216# <i>umount /mnt/loop</i> 220# <i>umount /mnt/loop</i>
217</pre> 221</pre>
222
218<p> 223<p>
219It would also be nice to have a 0.5 GB swap partition. 224It would also be nice to have a 0.5 GB swap partition.
220</p> 225</p>
221<pre> 226
227<pre caption="Create swap partition">
222# <i>dd if=/dev/zero of=swap_fs seek=500 count=1 bs=1M</i> 228# <i>dd if=/dev/zero of=swap_fs seek=500 count=1 bs=1M</i>
223# <i>mkswap -f swap_fs</i> 229# <i>mkswap -f swap_fs</i>
224</pre> 230</pre>
231
225<p> 232<p>
226Now see if it works! 233Now see if it works!
227</p> 234</p>
228<pre> 235
236<pre caption="Start UML kernel thread">
229# <i>linux ubd0=root_fs ubd1=swap_fs</i> 237# <i>linux ubd0=root_fs ubd1=swap_fs</i>
230</pre> 238</pre>
231<note> 239
240<p>
232User-mode linux uses xterms for the virtual consoles that 241User-mode linux uses xterms for the virtual consoles that
233are run at boot time, so you need to make sure that the 242are run at boot time, so you need to make sure that the
234terminal from which you run user-mode linux has $DISPLAY 243terminal from which you run user-mode linux has $DISPLAY
235properly set (along with proper xhost/xauth permissions). 244properly set (along with proper xhost/xauth permissions).
236</note> 245</p>
246
237<p> 247<p>
238With any luck you should be able to log into your user-mode linux 248With any luck you should be able to log into your user-mode linux
239Gentoo system. The only thing keeping this user-mode linux version 249Gentoo system. The only thing keeping this user-mode linux version
240of Gentoo from being fully functional is networking from the virtual 250of Gentoo from being fully functional is networking from the virtual
241machine to the host. 251machine to the host.
242</p> 252</p>
253
243</body> 254</body>
244</section> 255</section>
245</chapter> 256</chapter>
246 257
247<chapter> 258<chapter>
248<title>Networking</title> 259<title>Networking</title>
249
250<section> 260<section>
251<body> 261<body>
252<p> 262
253Thanks to Martin Schlemmer (Azarah), I now know how
254to get networking to function from within a user-mode
255system. The idea is that we set up a private network
256consisting of the user-mode system and the host system,
257and then the user-mode system routes all of its packets
258to the host, which then forwards packets to the net.
259Make sure that the host kernel has
260Networking --> IP: Netfilter Configuration --> IP tables support
261--> Full NAT --> MASQUERADE target support and
262Network Device Support --> Ethertap network tap
263compiled as modules; then do the following on the
264<e>host</e> machine:
265</p> 263<p>
264Make sure that the host kernel has the following settings compiled as modules:
265</p>
266
267<pre caption="Host kernel configuration">
268Networking --&gt;
269 IP: Netfilter Configuration --&gt;
270 IP tables support --&gt;
271 Full NAT --&gt;
272 &lt;M&gt; MASQUERADE target support
273
274 Network Device Support --&gt;
275 &lt;M&gt; TUN/TAP Support
266<pre> 276</pre>
277
278<p>
279Run the following commands on the <e>host</e> machine:
280</p>
281
282<pre caption="Setup networking">
267# <i>modprobe ethertap</i> 283# <i>modprobe tun</i>
284<comment>(If you receive a FATAL error here, try deleting /dev/net/tun and retry)</comment>
268# <i>modprobe iptable_nat</i> 285# <i>modprobe iptable_nat</i>
269# <i>iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE</i> 286# <i>iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE</i>
270# <i>echo 1 > /proc/sys/net/ipv4/ip_forward</i> 287# <i>echo 1 > /proc/sys/net/ipv4/ip_forward</i>
271</pre> 288</pre>
289
272<p> 290<p>
273The iptables line sets up IP Masquerading between the private 291The iptables line sets up IP Masquerading between the private
274network that our user-mode system will be on and the internet 292network that our user-mode system will be on and the internet
275(reachable via <c>eth0</c> in our case). The echo line then 293(reachable via <c>eth0</c> in our case). The echo line then
276turns on packet forwarding between the private network and the 294turns on packet forwarding between the private network and the
277interface that the default gateway is on (eth0 for us). 295interface that the default gateway is on (eth0 for us).
278</p> 296</p>
297
279<p> 298<p>
280Now we bring up the user-mode system and see if networking 299Now we bring up the user-mode system and see if networking
281is functional. 300is functional.
282</p> 301</p>
283<pre> 302
303<pre caption="Get UML up and running">
284# <i>linux ubd0=root_fs ubd1=swap_fs eth0=ethertap,tap0,,192.168.0.254</i> 304# <i>linux ubd0=root_fs ubd1=swap_fs eth0=tuntap,,,192.168.0.254</i>
285<comment>(login to user-mode system)</comment> 305<comment>(login to user-mode system)</comment>
286# <i>ifconfig eth0 192.168.0.1 up</i> 306# <i>ifconfig eth0 192.168.0.1 up</i>
287# <i>ping -c 2 192.168.0.254</i> 307# <i>ping -c 2 192.168.0.254</i>
288PING 192.168.0.254 (192.168.0.254): 56 octets data 308PING 192.168.0.254 (192.168.0.254): 56 octets data
28964 octets from 192.168.0.254: icmp_seq=0 ttl=255 time=0.8 ms 30964 octets from 192.168.0.254: icmp_seq=0 ttl=255 time=0.8 ms
306 326
307--- www.gentoo.org ping statistics --- 327--- www.gentoo.org ping statistics ---
3082 packets transmitted, 2 packets received, 0% packet loss 3282 packets transmitted, 2 packets received, 0% packet loss
309round-trip min/avg/max = 92.0/105.8/119.6 ms 329round-trip min/avg/max = 92.0/105.8/119.6 ms
310</pre> 330</pre>
331
311<p> 332<p>
312On the user-mode system we assign the user-mode eth0 interface 333On the user-mode system we assign the user-mode eth0 interface
313the private IP address 192.168.0.1 and bring up the interface. The 334the private IP address 192.168.0.1 and bring up the interface. The
314host has private IP address 192.168.0.254, and we ping it to make sure 335host has private IP address 192.168.0.254, and we ping it to make sure
315that our networking is, indeed, up. The route line adds a default 336that our networking is, indeed, up. The route line adds a default
317<path>/etc/resolv.conf</path> (if necessary), and we ping www.gentoo.org 338<path>/etc/resolv.conf</path> (if necessary), and we ping www.gentoo.org
318to make sure that name resolution (and general access to the internet) 339to make sure that name resolution (and general access to the internet)
319is working from our user-mode system. Now the user-mode system can 340is working from our user-mode system. Now the user-mode system can
320<c>emerge</c> at will! 341<c>emerge</c> at will!
321</p> 342</p>
343
322</body> 344</body>
323</section> 345</section>
324</chapter> 346</chapter>
325
326<chapter> 347<chapter>
327<title>Testing the .iso</title> 348<title>Testing the .iso</title>
328
329<section> 349<section>
330<body> 350<body>
351
331<p> 352<p>
332Perhaps the true ideal of Gentoo Linux testing would be 353Perhaps the true ideal of Gentoo Linux testing would be
333to boot the .iso with user-mode linux and do the complete 354to boot the .iso with user-mode linux and do the complete
334Gentoo install from within the user-mode linux virtual system. 355Gentoo install from within the user-mode linux virtual system.
335</p> 356</p>
357
336<p> 358<p>
337Booting the .iso, or actually the initrd from the .iso, is pretty 359Booting the .iso, or actually the initrd from the .iso, is pretty
338straightforward. 360straightforward.
339</p> 361</p>
340<pre> 362
363<pre caption="Booting the ISO">
341# <i>mount -o loop /path/to/build-&lt;TAB&gt;.iso /mnt/loop</i> 364# <i>mount -o loop /path/to/install-&lt;TAB&gt;.iso /mnt/loop</i>
342# <i>cp /mnt/loop/isolinux/rescue.gz .</i> 365# <i>cp /mnt/loop/isolinux/gentoo.igz .</i>
343# <i>linux load_ramdisk=1 prompt_ramdisk=0 ramdisk_size=22000 \</i> 366# <i>linux load_ramdisk=1 prompt_ramdisk=0 ramdisk_size=22000 \</i>
344&gt; <i>initrd=rescue.gz root=/dev/ram0 ubd0=root_fs ubd1=swap_fs \</i> 367&gt; <i>initrd=rescue.gz root=/dev/ram0 ubd0=root_fs ubd1=swap_fs \</i>
345&gt; <i>ubd2=/dev/cdroms/cdrom0 eth0=ethertap,tap0,,192.168.0.254</i> 368&gt; <i>ubd2=/dev/cdroms/cdrom0 eth0=tuntap,,,192.168.0.254</i>
346</pre> 369</pre>
370
371<p>
347<p>Now you can follow the Gentoo install doc essentially verbatim, 372Now you can follow the Gentoo install doc essentially verbatim,
348although you'll need to know that the root filesystem will be 373although you'll need to know that the root filesystem will be
349<path>/dev/ubd/0</path>, the swap "partition" 374<path>/dev/ubd/0</path>, the swap "partition"
350will be <path>/dev/ubd/1</path>, and the CD rom 375will be <path>/dev/ubd/1</path>, and the CD rom
351will be <path>/dev/ubd/2</path>.</p> 376will be <path>/dev/ubd/2</path>.
377</p>
378
352</body> 379</body>
353</section> 380</section>
354</chapter> 381</chapter>
355 382
383<chapter>
384<title>Resources</title>
385<section>
386<body>
387
388<ul>
389 <li>
390 <uri link="http://edeca.net/articles/bridging/index.html">Bridging with
391 UML</uri>
392 </li>
393 <li>
394 <uri link="http://user-mode-linux.sourceforge.net/">UML Homepage</uri>
395 </li>
396 <li>
397 <uri link="http://www.theshore.net/~caker/uml/">Caker's UML Notes</uri>
398 </li>
399 <li>
400 <uri link="http://sourceforge.net/mailarchive/forum.php?forum_id=3647">UML
401 Mailinglist archives</uri>
402 </li>
403</ul>
404
405</body>
406</section>
407</chapter>
356 408
357</guide> 409</guide>

Legend:
Removed from v.1.10  
changed lines
  Added in v.1.22

  ViewVC Help
Powered by ViewVC 1.1.20