Solaris 9 Installation Guide

Creating Disk Configuration Files

This section describes how to create single-disk and multiple-disk configuration files. Disk configuration files enable you to use pfinstall(1M) from a single system to test profiles against different disk configurations.

To Create a Disk Configuration File

  1. Locate a system with a disk you want to test.

  2. Become superuser.

  3. Create a single-disk configuration file by redirecting the output of the prtvtoc(1M) command to a file.


    # prtvtoc /dev/rdsk/device_name >disk_config_file
    

    /dev/rdsk/device_name

    The device name of the system's disk. device_name must be in the form cwtxdys2 or cxdys2.

    disk_config_file

    The name of the disk configuration file. 

  4. Determine if you are testing the installation of Solaris software on multiple disks.

    • If no, stop. You are finished.

    • If yes, concatenate the single-disk configuration files and save the output in a new file.


      # cat disk_file1 disk_file2 >multi_disk_config
      

      The new file becomes the multiple-disk configuration file, as in the following example:


      # cat 104_disk2 104_disk3 104_disk5 >multi_disk_test
      
  5. Determine if the target numbers in the disk device names are unique in the multiple-disk configuration file that you created in the previous step.

    • If yes, stop. You are finished.

    • If no, open the file with a text editor and make the target numbers unique in the disk device names.

      For example, assume that the file contains the same target number, t0, for different disk device names, as shown here:

      * /dev/rdsk/c0t0d0s2 partition map
      ...
      * /dev/rdsk/c0t0d0s2 partition map

      Change the second target number to t2, as shown here:

      * /dev/rdsk/c0t0d0s2 partition map
      ...
      * /dev/rdsk/c0t2d0s2 partition map

Disk Configuration File Example

The following example shows how to create a single-disk configuration file, 104_test, on a system with a 104-Mbyte disk.


Example 24-6 Creating a Disk Configuration File

You redirect the output of the prtvtoc command to a single-disk configuration file that is named 104_test:


# prtvtoc /dev/rdsk/c0t3d0s2 >104_test

The contents of the 104_test file resemble the following:

* /dev/rdsk/c0t3d0s2 partition map
*
* Dimensions:
*     512 bytes/sector
*      72 sectors/track
*      14 tracks/cylinder
*    1008 sectors/cylinder
*    2038 cylinders*    2036 accessible cylinders
* Flags:
*   1: unmountable
*  10: read-only
*
*                          First     Sector    Last
* Partition  Tag  Flags    Sector     Count    Sector  Mount Directory
       1      2    00          0     164304   164303   /
       2      5    00          0    2052288  2052287  
       3      0    00     164304     823536   987839   /disk2/b298
       5      0    00     987840     614880  1602719   /install/298/sparc/work
       7      0    00    1602720     449568  2052287   /space

You have created disk configuration files. "Testing a Profile" contains information about using disk configuration files to test profiles.