この節では、3 つのフェーズの例を示します。
ldmp2v collect コマンドの使用方法の例を次に示します。
NFS マウント済みファイルシステムを共有する。次の例は、collect 手順の簡単な実行方法を示しています。この場合、ソースシステムとターゲットシステムは、1 つの NFS マウント済みファイルシステムを共有します。
スーパーユーザーで、必要なすべての UFS ファイルシステムがマウントされていることを確認してください。
volumia# df -k Filesystem kbytes used avail capacity Mounted on /dev/dsk/c1t1d0s0 16516485 463289 15888032 3% / /proc 0 0 0 0% /proc fd 0 0 0 0% /dev/fd mnttab 0 0 0 0% /etc/mnttab /dev/dsk/c1t1d0s3 8258597 4304 8171708 1% /var swap 4487448 16 4487432 1% /var/run swap 4487448 16 4487432 1% /tmp /dev/dsk/c1t0d0s0 1016122 9 955146 1% /u01 vandikhout:/u1/home/dana 6230996752 1051158977 5179837775 17% /home/dana |
次の例は、ソースシステムとターゲットシステムが 1 つの NFS マウント済みファイルシステムを共有している場合に収集ツールを実行する方法を示しています。
volumia# ldmp2v collect -d /home/dana/p2v/volumia Collecting system configuration ... Archiving file systems ... DUMP: Writing 63 Kilobyte records DUMP: Date of this level 0 dump: vr 28 nov 2008 15:04:03 MET DUMP: Date of last level 0 dump: the epoch DUMP: Dumping /dev/rdsk/c1t1d0s0 (volumia:/) to /home/dana/p2v/ufsdump.0. DUMP: Mapping (Pass I) [regular files] DUMP: Mapping (Pass II) [directories] DUMP: Estimated 950240 blocks (463,98MB). DUMP: Dumping (Pass III) [directories] DUMP: Dumping (Pass IV) [regular files] DUMP: 950164 blocks (463,95MB) on 1 volume at 6215 KB/sec DUMP: DUMP IS DONE DUMP: Writing 63 Kilobyte records DUMP: Date of this level 0 dump: vr 28 nov 2008 15:05:27 MET DUMP: Date of last level 0 dump: the epoch DUMP: Dumping /dev/rdsk/c1t0d0s0 (volumia:/u01) to /home/dana/p2v/ufsdump.1. DUMP: Mapping (Pass I) [regular files] DUMP: Mapping (Pass II) [directories] DUMP: Estimated 282 blocks (141KB). DUMP: Dumping (Pass III) [directories] DUMP: Dumping (Pass IV) [regular files] DUMP: 250 blocks (125KB) on 1 volume at 8928 KB/sec DUMP: DUMP IS DONE DUMP: Writing 63 Kilobyte records DUMP: Date of this level 0 dump: vr 28 nov 2008 15:05:27 MET DUMP: Date of last level 0 dump: the epoch DUMP: Dumping /dev/rdsk/c1t1d0s3 (volumia:/var) to /home/dana/p2v/ufsdump.2. DUMP: Mapping (Pass I) [regular files] DUMP: Mapping (Pass II) [directories] DUMP: Estimated 13324 blocks (6,51MB). DUMP: Dumping (Pass III) [directories] DUMP: Dumping (Pass IV) [regular files] DUMP: 13228 blocks (6,46MB) on 1 volume at 1146 KB/sec DUMP: DUMP IS DONE |
NFS マウント済みファイルシステムを共有しない。ソースシステムとターゲットシステムが 1 つの NFS マウント済みファイルシステムを共有しない場合、ファイルシステムイメージをローカル記憶領域に書き込んだあとで制御ドメインにコピーできます。ufsdump を使用してファイルを除外することはできないため、ldmp2v が提供するフラッシュアーカイブ方式を使用します。フラッシュツールは、作成したアーカイブを自動的に除外します。
volumia# ldmp2v collect -d /home/dana/p2v/volumia -a flash Collecting system configuration ... Archiving file systems ... Determining which filesystems will be included in the archive... Creating the archive... 895080 blocks Archive creation complete. |
ファイルシステムのバックアップステップをスキップする。NetBackup など、他社のバックアップツールを使用することでシステムのバックアップをすでに利用できる場合は、none アーカイブ方式を使用してファイルシステムのバックアップステップをスキップできます。このオプションを使用する場合、システム構成マニフェストのみが作成されます。
volumia# ldmp2v collect -d /home/dana/p2v/volumia -a none Collecting system configuration ... The following file system(s) must be archived manually: / /u01 /var |
-d で指定するディレクトリが、ソースシステムとターゲットシステムによって共有されていない場合は、そのディレクトリの内容を制御ドメインにコピーします。準備フェーズを開始する前に、ディレクトリの内容を制御ドメインにコピーする必要があります。
ldmp2v prepare コマンドの使用方法の例を次に示します。
次の例は、物理システムの MAC アドレスを維持しながら、/etc/ldmp2v.conf に構成されているデフォルトを使用することで、volumia という論理ドメインを作成します。
# ldmp2v prepare -d /home/dana/p2v/volumia -o keep-mac volumia Creating vdisks ... Creating file systems ... Populating file systems ... Modifying guest domain OS image ... Removing SVM configuration ... Unmounting guest file systems ... Creating domain volumia ... Attaching vdisks to domain volumia ... |
次のコマンドは、volumia 論理ドメインに関する情報を表示します。
# ldm list -l volumia NAME STATE FLAGS CONS VCPU MEMORY UTIL UPTIME volumia inactive ------ 2 4G NETWORK NAME SERVICE DEVICE MAC MODE PVID VID vnet0 primary-vsw0 00:03:ba:1d:7a:5a 1 DISK NAME DEVICE TOUT MPGROUP VOLUME SERVER disk0 volumia-vol0@primary-vds0 disk1 volumia-vol1@primary-vds0 |
次の例は、-C オプションを使用して、ドメインとそのバックエンドデバイスを完全に削除できることを示しています。
# ldmp2v prepare -C volumia Cleaning up domain volumia ... Removing vdisk disk0 ... Removing vdisk disk1 ... Removing domain volumia ... Removing volume volumia-vol0@primary-vds0 ... Removing ZFS volume tank/ldoms/volumia/disk0 ... Removing volume volumia-vol1@primary-vds0 ... Removing ZFS volume tank/ldoms/volumia/disk1 ... |
次の例は、-m オプションを使用してマウントポイントとその新しいサイズを指定することで、P2V の実行中に 1 つ以上のファイルシステムのサイズを変更できることを示しています。
# ldmp2v prepare -d /home/dana/p2v/normaal -m /:8g normaal Resizing file systems ... Creating vdisks ... Creating file systems ... Populating file systems ... Modifying guest domain OS image ... Removing SVM configuration ... Modifying file systems on SVM devices ... Unmounting guest file systems ... Creating domain normaal ... Attaching vdisks to domain normaal ... |
ldmp2v convert コマンドの使用方法の例を次に示します。
ネットワークインストールサーバーを使用する。ldmp2v convert コマンドは、指定した仮想ネットワークインタフェースを使用することによってネットワーク経由で Logical Domains を起動します。インストールサーバーで setup_install_server および add_install_client スクリプトを実行する必要があります。
Custom JumpStart 機能を使用し、完全に操作不要の変換を実行することもできます。この機能では、JumpStart サーバー上のクライアントに対して適切な sysidcfg およびプロファイルファイルを作成および構成する必要があります。プロファイルには次の行を含めるようにしてください。
install_type upgrade root_device c0d0s0 |
sysidcfg ファイルは、アップグレード処理にのみ使用されます。したがって、次のような構成で十分であるはずです。
name_service=NONE root_password=uQkoXlMLCsZhI system_locale=C timeserver=localhost timezone=Europe/Amsterdam terminal=vt100 security_policy=NONE nfs4_domain=dynamic network_interface=PRIMARY {netmask=255.255.255.192 default_route=none protocol_ipv6=no} |
Custom JumpStart の使用については、『Solaris 10 10/09 インストールガイド (カスタムJumpStart/ 上級編)』を参照してください。
# ldmp2v convert -j -n vnet0 -d /p2v/volumia volumia LDom volumia started Waiting for Solaris to come up ... Using Custom JumpStart Trying 0.0.0.0... Connected to 0. Escape character is '^]'. Connecting to console "volumia" in group "volumia" .... Press ~? for control options .. SunOS Release 5.10 Version Generic_137137-09 64-bit Copyright 1983-2008 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. onfiguring devices. Using RPC Bootparams for network configuration information. Attempting to configure interface vnet0... Configured interface vnet0 Reading ZFS config: done. Setting up Java. Please wait... Serial console, reverting to text install Beginning system identification... Searching for configuration file(s)... Using sysid configuration file 129.159.206.54:/opt/SUNWjet/Clients/volumia/sysidcfg Search complete. Discovering additional network configuration... Completing system identification... Starting remote procedure call (RPC) services: done. System identification complete. Starting Solaris installation program... Searching for JumpStart directory... Using rules.ok from 129.159.206.54:/opt/SUNWjet. Checking rules.ok file... Using begin script: Clients/volumia/begin Using profile: Clients/volumia/profile Using finish script: Clients/volumia/finish Executing JumpStart preinstall phase... Executing begin script "Clients/volumia/begin"... Begin script Clients/volumia/begin execution completed. Searching for SolStart directory... Checking rules.ok file... Using begin script: install_begin Using finish script: patch_finish Executing SolStart preinstall phase... Executing begin script "install_begin"... Begin script install_begin execution completed. WARNING: Backup media not specified. A backup media (backup_media) keyword must be specified if an upgrade with disk space reallocation is required Processing profile Loading local environment and services Generating upgrade actions Checking file system space: 100% completed Space check complete. Building upgrade script Preparing system for Solaris upgrade Upgrading Solaris: 10% completed [...] |
ISO イメージを使用する。ldmp2v convert コマンドは、Solaris DVD ISO イメージを論理ドメインに関連付け、そこから起動します。アップグレードを行うには、sysid のすべての質問に回答し、「Upgrade」を選択します。
sysid の質問への回答は、アップグレード処理時にのみ使用されるため、もっとも単純なオプション (ネットワーク接続なし、ネームサービスなし、など) を選択できます。システムの元の ID は、アップグレードによって維持され、アップグレードの完了後に再起動すると有効になります。アップグレードの実行に必要な時間は、元のシステムにインストールされている Solaris クラスタによって異なります。
# ldmp2v convert -i /tank/iso/s10s_u5.iso -d /home/dana/p2v/volumia volumia Testing original system status ... LDom volumia started Waiting for Solaris to come up ... Select 'Upgrade' (F2) when prompted for the installation type. Disconnect from the console after the Upgrade has finished. Trying 0.0.0.0... Connected to 0. Escape character is '^]'. Connecting to console "volumia" in group "volumia" .... Press ~? for control options .. Configuring devices. Using RPC Bootparams for network configuration information. Attempting to configure interface vnet0... Extracting windowing system. Please wait... Beginning system identification... Searching for configuration file(s)... Search complete. Discovering additional network configuration... Configured interface vnet0 Setting up Java. Please wait... Select a Language 0. English 1. French 2. German 3. Italian 4. Japanese 5. Korean 6. Simplified Chinese 7. Spanish 8. Swedish 9. Traditional Chinese Please make a choice (0 - 9), or press h or ? for help: [...] - Solaris Interactive Installation -------------------------------------------- This system is upgradable, so there are two ways to install the Solaris software. The Upgrade option updates the Solaris software to the new release, saving as many modifications to the previous version of Solaris software as possible. Back up the system before using the Upgrade option. The Initial option overwrites the system disks with the new version of Solaris software. This option allows you to preserve any existing file systems. Back up any modifications made to the previous version of Solaris software before starting the Initial option. After you select an option and complete the tasks that follow, a summary of your actions will be displayed. ------------------------------------------------------------------------------- F2_Upgrade F3_Go Back F4_Initial F5_Exit F6_Help |