6.8.3 簡易構築定義ファイルの作成例

テンプレートファイルをコピーし,名称を変更して,任意の場所に格納します。

なお,ここでは,ファイル名を「MyWebSystemDef.xml」に変更して,次の図に示す構成を定義しています。

図6-6 簡易構築定義ファイルの作成例で使用している構成情報

[図データ]

簡易構築定義ファイル(MyWebSystemDef.xml)の作成例を次に示します。

MyWebSystemDef.xmlファイル

<?xml version="1.0" encoding="UTF-8"?>
<model-definition xmlns="http://www.cosminexus.com/mngsvr/schema/ModelDefinition-2.5">
 <!-- Webシステムの属性定義 -->
 <web-system>
   <name>MyWebSystem</name>
   <!-- 負荷分散機の定義 -->
   <load-balancer>
     <name>MyBIGIPv9</name>
     <load-balancer-type>BIG-IPv9</load-balancer-type>
     <!-- cookieスイッチングの定義 -->
     <cookie-switching>
       <cookie-switching-enabled>true</cookie-switching-enabled>
       <cookie-name>CMX_SERVER_ID</cookie-name>
       <server-id-rule>1024-2048</server-id-rule>
     </cookie-switching>
     <management-host>192.168.100.10</management-host>
     <!-- 仮想サーバの定義 -->
     <virtual-server>
       <virtual-server-name>www.sample.com</virtual-server-name>
       <ip-address>192.168.1.10</ip-address>
       <http-port>80</http-port>
     </virtual-server>
   </load-balancer>
   <!-- 物理ティアの定義 -->
   <tier>
     <tier-type>combined-tier</tier-type>
     <configuration>
       <logical-server-type>j2ee-server</logical-server-type>
       <param>
          <param-name>webserver.container.server_id.enabled</param-name>
          <param-value>true</param-value>
       </param>
     </configuration>
   </tier>
   <!-- サービスユニットの定義 -->
   <unit>
     <name>unit1</name>
     <allocated-host>
       <host-ref>apsv1</host-ref>
       <hosts-for>combined-tier</hosts-for>
     </allocated-host>
   </unit>
   <unit>
     <name>unit2</name>
     <allocated-host>
       <host-ref>apsv2</host-ref>
       <hosts-for>combined-tier</hosts-for>
     </allocated-host>
   </unit>
 </web-system>
 <!-- ホストの定義 -->
 <host>
   <host-name>apsv1</host-name>
   <agent-host>192.168.100.11</agent-host>
 </host>
 <host>
   <host-name>apsv2</host-name>
   <agent-host>192.168.100.12</agent-host>
 </host>
</model-definition>

注 太字の部分が編集部分です。