Changeset 54789f3 for postlfs/virtualization/qemu-systemd.xml
- Timestamp:
- 01/24/2016 02:04:18 AM (8 years ago)
- Branches:
- systemd-13485
- Children:
- 83f6c770
- Parents:
- 295ca00
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
postlfs/virtualization/qemu-systemd.xml
r295ca00 r54789f3 7 7 <!ENTITY qemu-download-http "http://wiki.qemu.org/download/qemu-&qemu-version;.tar.bz2"> 8 8 <!ENTITY qemu-download-ftp " "> 9 <!ENTITY qemu-md5sum " 2fab3ea4460de9b57192e5b8b311f221">10 <!ENTITY qemu-size "2 4MB">11 <!ENTITY qemu-buildsize " 291 MB">12 <!ENTITY qemu-time " 1.4 SBU">9 <!ENTITY qemu-md5sum "f469f2330bbe76e3e39db10e9ac4f8db"> 10 <!ENTITY qemu-size "25 MB"> 11 <!ENTITY qemu-buildsize "419 MB (with tests)"> 12 <!ENTITY qemu-time "2.4 SBU (with tests)"> 13 13 ]> 14 14 … … 79 79 <xref linkend="curl"/>, 80 80 <xref linkend="cyrus-sasl"/>, 81 <xref linkend="gnutls"/>, 81 82 <xref linkend="gtk2"/>, 82 83 <xref linkend="gtk3"/>, 83 84 <xref linkend="libusb"/>, 85 <xref linkend="libgcrypt"/>, 84 86 <xref linkend="lzo"/>, 87 <xref linkend="nettle"/>, 85 88 <xref linkend="nss"/> (for libcacard.so), 86 <xref linkend="mesalib"/>, and 89 <xref linkend="mesalib"/>, 90 <xref linkend="sdl"/>, and 87 91 <xref linkend="vte"/> 92 <ulink url="http://www.libssh2.org">libssh2</ulink> 88 93 </para> 89 94 … … 151 156 commands:</para> 152 157 153 <screen><userinput>./configure --prefix=/usr \ 154 --sysconfdir=/etc \ 155 --docdir=/usr/share/doc/qemu-&qemu-version; \ 156 --target-list=x86_64-softmmu && 158 <note><para>Qemu is capable of running many targets. The build process 159 is also capable of building multiple targets at one time in a 160 comma delimited list assigned to <option>--target-list</option>. Run 161 <command>./configure --help</command> to get a complete list of 162 available targets.</para></note> 163 164 <screen><userinput>if [ $(uname -m) = i686 ]; then 165 QEMU_ARCH=i386-softmmu 166 else 167 QEMU_ARCH=x86_64-softmmu 168 fi 169 170 mkdir -vp build && 171 cd build && 172 173 ../configure --prefix=/usr \ 174 --sysconfdir=/etc \ 175 --target-list=$QEMU_ARCH \ 176 --audio-drv-list=alsa \ 177 --docdir=/usr/share/doc/qemu-&qemu-version; && 178 179 unset QEMU_ARCH && 180 157 181 make</userinput></screen> 158 182 159 <para>To run the built in tests, run <command>make V=1 check</command>.</para> 183 <para>To run the built in tests, run <command>make V=1 check</command>. 184 One test is known to fail.</para> 160 185 161 186 <para>Now, as the <systemitem class="username">root</systemitem> user:</para> 162 187 163 188 <screen role="root"><userinput>make install && 164 [ -e /usr/lib/libcacard.so ] && chmod -v 755 /usr/lib/libcacard.so</userinput></screen> 189 [ -e /usr/lib/libcacard.so ] && 190 chmod -v 755 /usr/lib/libcacard.so</userinput></screen> 165 191 166 192 <para> … … 193 219 194 220 <para>For convenience you may want to create a symbolic link to run 195 <command>qemu-system-x86_64</command>:</para>196 197 <screen role="root"><userinput>ln -sv qemu-system-x86_64/usr/bin/qemu</userinput></screen>221 The installed program. For instance:</para> 222 223 <screen role="root"><userinput>ln -sv qemu-system-`uname -m` /usr/bin/qemu</userinput></screen> 198 224 </note> 199 225 … … 203 229 <title>Command Explanations</title> 204 230 205 <para><parameter>--target-list=x86_64-softmmu</parameter>: This switch206 limits the build target to the x86_64 architecture. For other207 hardware emulation see the --target-list list in <command>configure</command>'s208 help output. Omitting this option will build all architectures.</para>209 210 231 <para> 211 < option>--audio-drv-list=alsa</option>: This switch sets the audio driver232 <parameter>--audio-drv-list=alsa</parameter>: This switch sets the audio driver 212 233 to ALSA. For other drivers see the --audio-drv-list list in 213 234 <command>configure</command>'s help output. The default audio driver is … … 230 251 <note><para>The following instructions assume you have created the optional 231 252 symbolic link, <userinput>qemu</userinput>. Additionally, you must run 232 <userinput>qemu</userinput> from an X Window System based terminal.</para></note> 253 <userinput>qemu</userinput> from an X Window System based terminal. 254 (either locally or over ssh).</para></note> 233 255 234 256 <para>To install an operating system, download an iso of your choice or use … … 257 279 <screen><userinput>qemu -enable-kvm vdisk.img -m 384</userinput></screen> 258 280 259 <para>To add networking to the instance add "-net nic -net user" to the 260 command above. qemu provides a DHCP server for the VM and, depending on 281 <para>You may have a problem with <parameter>--enable-kvm</parameter>. Also, 282 you may want to define audio and video drivers, the number of cpu cores, and 283 the number of threads. An alternative command to install the operating system is (see qemu 284 man page for parameters definitions):</para> 285 286 <screen><userinput>qemu -enable-kvm \ 287 -cdrom /home/fernando/ISO/linuxmint-17.1-mate-32bit.iso \ 288 -boot order=d \ 289 -m 1G,slots=3,maxmem=4G \ 290 -machine smm=off \ 291 -soundhw es1370 \ 292 -cpu host \ 293 -smp cores=4,threads=2 \ 294 -vga std \ 295 vdisk.img</userinput></screen> 296 297 <para>One parameter not appearing in the qemu man page is 298 <parameter>-machine smm=off</parameter>, and it used to allow 299 <parameter>-enable-kvm</parameter> in some systems. In order to run the 300 machine, you can alternatively issue:</para> 301 302 <screen><userinput>qemu -enable-kvm \ 303 -machine smm=off \ 304 -boot order=d \ 305 -m 1G,slots=3,maxmem=4G \ 306 -soundhw es1370 \ 307 -cpu host \ 308 -smp cores=4,threads=2 \ 309 -vga vmware \ 310 -hda vdisk.img</userinput></screen> 311 312 <para>Sometimes, you want the machine to have different screen sizes than 313 the ones natively offered by the virtual graphics card. The example below is 314 for the qemu vmware graphics card, which uses 315 <xref linkend="xorg-vmware-driver"/> and is set to give the maximum screen size 316 of 1600x900. As the <systemitem class="username">root</systemitem> user, 317 issue the following:</para> 318 319 <screen role="root"><userinput>cat > /usr/share/X11/xorg.conf.d/20-vmware.conf << "EOF" 320 <literal>Section "Monitor" 321 Identifier "Monitor0" 322 # cvt 1600 900 323 # 1600x900 59.95 Hz (CVT 1.44M9) hsync:55.99 kHz; pclk: 118.25 MHz 324 Modeline "1600x900" 118.25 1600 1696 1856 2112 900 903 908 934 -hysnc +vsync 325 Option "PreferredMode" "1600x900" 326 HorizSync 1-200 327 VertRefresh 1-200 328 EndSection 329 330 Section "Device" 331 Identifier "VMWare SVGA II Adapter" 332 Option "Monitor" "Default" 333 Driver "vmware" 334 EndSection 335 336 Section "Screen" 337 Identifier "Default Screen" 338 Device "VMWare SVGA II Adapter" 339 Monitor "Monitor0" 340 341 SubSection "Display" 342 Depth 24 343 Modes "1600x900" "1440x900" "1366x768" "1280x720" "800x480" 344 EndSubSection 345 EndSection </literal> 346 EOF </userinput></screen> 347 348 <para>New sizes will be available besides the native ones. You need to 349 restart X in order to have the new sizes available.</para> 350 351 <para><!--To add networking to the instance add "-net nic -net user" to the 352 command above.--> qemu provides a DHCP server for the VM and, depending on 261 353 the client system, sets up networking though the host.</para> 262 354 … … 268 360 <itemizedlist spacing="compact"> 269 361 <listitem> 270 <para>Set up bridging using <xref linkend=" network-bridge"/>.</para>362 <para>Set up bridging using <xref linkend="bridgeutils"/>.</para> 271 363 </listitem> 272 364 … … 375 467 <seglistitem> 376 468 <seg> 469 ivshmem-client, 470 ivshmem-server, 471 qemu (symlink), 377 472 qemu-ga, 378 473 qemu-img, 379 474 qemu-io, 380 475 qemu-nbd, 381 qemu-system- x86_64,476 qemu-system-<arch>, 382 477 virtfs-proxy-helper, and 383 478 vscclient … … 385 480 <seg>libcacard.so</seg> 386 481 <seg> 387 /etc/qemu, 388 /usr/include/cacard, 389 /usr/lib/qemu, 390 /usr/share/qemu, and 482 /etc/qemu, and 391 483 /usr/share/doc/qemu-&qemu-version; 392 484 </seg>
Note:
See TracChangeset
for help on using the changeset viewer.