hajichan.net technical version
トップページ >> サーバ構築(Solaris) >> ネットワークインストール

サーバ構築

ネットワークインストール

インストールサーバを構築すれば、ネットワーク経由でOSをインストールできます。CD-ROM、DVDドライブが付いていないハードにOSをインストールするときに重宝します。

インストールサーバの構築

まずはコンテンツを提供するインストールサーバを構築します。これが無いと始まりませんので。

コンテンツコピー先ディレクトリを作成します。

# mkdir /var/inst_sol9

CDをマウント後、CDのコンテンツをコピーします。

# mount -F hsfs -o rw /dev/dsk/c1t2d0s0 /cdrom
# cd /cdrom/cdrom0/s0/Solaris_9/Tools

コンテンツのコピーには、setup_install_serverコマンドを使用します。Solaris_1_of_2のコンテンツがコピーされます。

# ./setup_install_server /var/inst_sol9
---
Verifying target directory...
Calculating the required disk space for the Solaris_9 product
Calculating space required for the installation boot image
Copying the CD image to disk...
Copying Install Boot Image hierarchy...
Install Server setup complete

続いて、Solaris_2_of_2のコンテンツコピーです。

# cd /cdrom/sol_9_sparc_2/Solaris_9/Tools
# ./add_to_install_server /var/inst_sol9

ブートサーバの構築

インストールサーバが、クライアントと同セグメントにある場合は不要です。もし構築する場合は、以下のコマンドを実行します。

# ./setup_install_server -b <dir>

インストールサーバにクライアント情報を追加する

インストールサーバにクライアントの情報を追加します。-sオプションでインストールコンテンツ(inst-srv:/var/inst_sol9)、 -iオプションでインストールクライアントのIP(192.168.1.3)、-eオプションでインストールクライアントのMAC(00:03:ba:13:aa:39)を指定します。

# cd /var/inst_sol9/Solaris_9/Tools
# ./add_install_client -s inst-srv:/var/inst_sol9 -i 192.168.1.3 \
-e 00:03:ba:13:aa:39 inst-client sun4u
---
Adding IP address for inst-client to /etc/hosts
Adding Ethernet number for inst-client to /etc/ethers
saving original /etc/dfs/dfstab in /etc/dfs/dfstab.orig
Adding "share -F nfs -o ro,anon=0 /var/inst_sol9" to /etc/dfs/dfstab
making /tftpboot
enabling tftp in /etc/inetd.conf
starting rarpd
starting bootparamd
starting nfsd's
starting nfs mountd
updating /etc/bootparams
copying inetboot to /tftpboot

出力されたメッセージを見ると、自動的にNFSサーバの設定、TFTPの設定などがされていることが分かります。

ネットワーク経由でインストール

ここまでの手順でネットワークインストール環境が整ったので、ネットワークインストールを行ってみます。

クライアント側のokプロンプトで、boot netを実行してネットワークから起動します。インストールサーバを発見して、インストーラが走りだします。

ok boot net
---
Res
LOM event: +19h21m44s host reset
etting ...

Sun Fire V100 (UltraSPARC-IIe 500MHz), No Keyboard
OpenBoot 4.0, 128 MB memory installed, Serial #51620409.
Ethernet address 0:3:ba:13:aa:39, Host ID: 8313aa39.

Executing last command: boot net
Boot device: /pci@1f,0/ethernet@c  File and args:
External loopback test -- Did not receive expected loopback packet.
SunOS Release 5.9 Version Generic 64-bit
Copyright 1983-2002 Sun Microsystems, Inc.  All rights reserved.
Use is subject to license terms.
NOTICE: dmfe1: PHY 1 link down
whoami: no domain name
Configuring /dev and /devices
Using RPC Bootparams for network configuration information.
Skipping interface dmfe1
Configured interface dmfe0
Searching for configuration file(s)...
Search complete.

その後のインストール手順は、CDから行ったときと同じなので、省略します。

インストール後の後片づけ

rm_install_clientコマンドで、情報削除しておきます。

# ./rm_install_client inst-client
---
removing wing.hajichan.net from bootparams
removing /etc/bootparams, since it is empty
removing /tftpboot/inetboot.SUN4U.Solaris_9-1
removing /tftpboot
disabling tftp in /etc/inetd.conf
ページのトップへ戻る