Red Hat Training

A Red Hat training course is available for Red Hat Enterprise Linux

10.3. Windows インストール時のドライバーのインストール

この手順では、Windows のインストール時に virtio ドライバーをインストールする方法を説明します。
この方法では、Windows ゲスト仮想マシンがデフォルトのストレージデバイスに virtio ドライバーを使用できます。

手順10.3 Windows インストール時の virtio ドライバーのインストール

  1. virtio-win パッケージのインストール

    以下のコマンドを使用して、virtio-win パッケージをインストールします。
    # yum install virtio-win
  2. ゲスト仮想マシンの作成

    重要
    仮想マシンを起動せずに、通常通り仮想マシンを作成します。以下の手順のいずれかに従ってください。
    以下の いずれか のゲスト作成方法を選択し、手順に従います。
    1. virsh を使用したゲスト仮想マシンの作成

      この方法では、インストール に virtio ドライバーフロッピーディスクを Windows ゲストに割り当てます。
      virsh を使用して XML 定義ファイルから仮想マシンを作成する場合は、 virsh create コマンドではなく、virsh define コマンドを使用します。
      1. 仮想マシンを作成しますが、起動しません。virsh コマンドで仮想マシンを作成する方法は、『Red Hat Enterprise Linux Virtualization Administration Guide』 を参照してください。
      2. virsh コマンドを使用して、ドライバーディスクを仮想化フロッピーディスクとして追加します。この例では、ゲスト仮想マシンに仮想化されたフロッピーデバイスがない場合はコピーおよび使用できます。vm_name は仮想マシンの名前に置き換える必要があることに注意してください。
        # virsh attach-disk vm_name /usr/share/virtio-win/virtio-win.vfd fda --type floppy
        ステップ 3 に進むことができます。
    2. virt-manager を使用してゲスト仮想マシンを作成し、ディスクタイプを変更します。

      1. virt-manager ゲスト作成ウィザードの最後のステップで、Customize configuration before install チェックボックスをオンにします。

        図10.16 virt-manager ゲスト作成ウィザード

        Step 5 of 5 of creating a new virtual machine with virt-manager, with a check box selected under Storage to customize configuration before install.
        Finish ボタンをクリックして続行します。
      2. Add Hardware ウィザードを開きます。

        新しいパネルの左下にある Add Hardware ボタンをクリックします。
      3. ストレージデバイスの選択

        ストレージ は、ハードウェアタイプ 一覧でのデフォルト選択です。

        図10.17 Add new virtual hardware ウィザード

        The Add new virtual hardware wizard with Storage selected in the Hardware type field.
        Select managed or other existing storage ラジオボタンが選択されていることを確認します。Browse... をクリックします。

        図10.18 管理ストレージまたは既存のストレージを選択

        The Add new virtual hardware wizard with Storage selected in the Hardware type field, and the Select managed or other existing storage radio button selected.
        表示された新しいウィンドウで、Browse Local をクリックします。/usr/share/virtio-win/virtio-win.vfd に移動し、選択 をクリックして確定します。
        Device typeFloppy disk に変更し、Finish をクリックして続行します。

        図10.19 デバイスタイプの変更

        The Device type field, set to Floppy Disk.
      4. 設定の確認

        デバイス設定を確認します。

        図10.20 仮想マシンのハードウェア情報ウィンドウ

        The virtual machine hardware information window with the target device (Floppy 1) selected.
        これで、仮想マシンがアクセスできるリムーバブルデバイスが作成されました。
      5. ハードディスクの種類を変更する

        ハードディスクタイプを IDE ディスクから Virtio Disk に変更するには、最初に既存のハードディスクである Disk 1 を削除する必要があります。ディスクを選択し、削除 ボタンをクリックします。

        図10.21 仮想マシンのハードウェア情報ウィンドウ

        The virtual machine hardware information window with virtual disk Disk 1 selected, with the Remove button available at the bottom right corner of the window.
        Add Hardware をクリックして、新しい仮想ストレージデバイスを追加します。次に、Device typeIDE ディスク から Virtio Disk に変更します。Finish をクリックして操作を確認します。

        図10.22 仮想マシンのハードウェア情報ウィンドウ

        The virtual machine hardware information window with the Floppy 1 target device selected, and the Add Hardware on the left bottom corner of the window.
      6. 設定が正しいことを確認します。

        VirtIO Disk 1 の設定を確認します。

        図10.23 仮想マシンのハードウェア情報ウィンドウ

        The virtual machine hardware information window with the Overview option selected, showing Basic Details, Hypervisor Details, plus expandable headings Machine Setting and Security, in the right part of the window.
        設定の詳細が適切であれば インストールの開始 ボタンをクリック します。
        ステップ 3 に進むことができます。
    3. virt-install を使用したゲスト仮想マシンの作成

      virt-install コマンドを使用してドライバーディスクをインストールに追加するには、以下のパラメーターを以下のように完全に追加します。
      --disk path=/usr/share/virtio-win/virtio-win.vfd,device=floppy
      重要
      追加するデバイスが ディスク ( フロッピー または cdromではなく)の場合は、以下のように --disk パラメーターの最後に bus=virtio オプションを追加する必要があります。
      --disk path=/usr/share/virtio-win/virtio-win.vfd,device=disk,bus=virtio
      インストールする Windows のバージョンに応じて、以下のいずれかのオプションを virt-install コマンドに追加します。
      --os-variant win2k3
      --os-variant win7
      ステップ 3 に進むことができます。
  3. ドライバーインストールの追加手順

    インストール時に、Windows ゲストのタイプに応じて、ドライバーをインストールするために追加の手順が必要です。
    1. Windows Server 2003

      インストール Blue 画面がサードパーティーのドライバー用に F6 を繰り返し押す前。

      図10.24 Windows 設定画面

      The Windows pre-installation blue screen reads Window Setup at the top in plain text, and "Press F6 if you need to install a third party SCSI or RAID driver..." at the bottom.
      S を押して、追加のデバイスドライバーをインストールします。

      図10.25 Windows 設定画面

      The next Windows pre-installation blue screen reads Window Setup at the top in plain text and details the option to install an additional device. Options at the bottom of the screen include S to "Specify Additional Device", ENTER to continue, or F3 to exit.

      図10.26 Windows 設定画面

      The next Windows blue screen reads Window Setup at the top in plain text and provides options to select the SCSI Adapter to be installed. Options at the bottom of the screen include ENTER to select, or F3 to exit.
      Enter を押して、インストールを続行します。
    2. Windows Server 2008

      Windows Server 2003 でも同じ手順に従いますが、インストーラーがドライバーを要求されたら、Load Driver をクリックし、インストーラーに A のドライブをポイントし て、ゲストオペレーティングシステムとアーキテクチャーに適したドライバーを選択します。