Trusted Solaris Installation and Configuration

IA: Creating a Disk Configuration File on Intel Architecture

The following procedures enable you to use the -d option of the pfinstall command to test custom JumpStart installations for Intel architecture.

IA: How to Create a Disk Configuration File on Intel Architecture

A disk configuration file represents a disk structure (for example, bytes/sectors, flags, slices), and it enables you to use pfinstall from a single system to test profiles against different sized disks. Disk configuration files for an Intel architecture system must also contain information about a disk's fdisk partitions.

Overview - Creating a disk configuration file for an Intel architecture system involves:

  1. Locate an Intel architecture system with a disk that you want to test a profile against.

  2. Determine the device name for the system's disk.

  3. Redirect the output of the following prtvtoc command to a file:


    # prtvtoc /dev/rdsk/device_name > file1
    

    where /dev/rdsk/device_name is the device name of the system's disk, and file1 is the file that contains the output of the prtvtoc command. device_name must be in the form cwtxdyp0 or cxdyp0. Partition 0 must be specified in device_name.

  4. Save the output of the following fdisk command to a file:


    # fdisk -R -d -n /dev/rdsk/device_name 2>file2
    

    Note -

    This version of the fdisk command may not be supported in the next release.


    where /dev/rdsk/device_name is the device name of the system's disk. file2 is the file that contains the output of the fdisk command. device_name must be in the form cwtxdyp0 or cxdyp0. Partition 0 must be specified in device_name.

  5. Concatenate the two files to create a disk configuration file:


    # cat file1 file2 > disk_config
    

    Note -

    The output of the prtvtoc command must be first in a disk configuration file for an Intel architecture system.


  6. Copy the disk configuration file to the JumpStart directory:


    # cp disk_config   jumpstart_dir_path
    

    You have created a disk configuration file for an Intel architecture system. The following page provides an example of creating a disk configuration file. This example creates a disk configuration file, 500_test, on an Intel architecture system with a 500-Mbyte disk.

    First, you would save the output of the prtvtoc command to a file:


    # prtvtoc /dev/rdsk/c0t0d0p0 > output1 
    

    The output1 file is shown as follows:


    * /dev/rdsk/c0t0d0p0 partition map
    *
    * Dimensions:
    *     512 bytes/sector
    *      79 sectors/track
    *       7 tracks/cylinder
    *     553 sectors/cylinder
    *    1481 cylinders
    *    1479 accessible cylinders
    *
    * Flags:
    *   1: unmountable
    *  10: read-only
    *
    *                          First     Sector    Last
    * Partition  Tag  Flags    Sector     Count    Sector  Mount Directory
           0      2    00        553    194103    194655
           1      3    01     194656     65807    260462
           2      6    00          0    819546    819545
           3      6    00     260463     50876    311338
           4      6    00     311339     72996    384334
           6      4    00     384335    434105    818439
           8      1    01          0       553       552

    Second, you would save the output of the fdisk command to a different file:


    # fdisk -R -d -n /dev/rdsk/c0t0d0p0 2>output2
    

    The output2 file is shown as follows:


    fdisk physical geometry:
    
    cylinders[1855] heads[7] sectors[79] sector size[512] blocks[1025815] mbytes[500]
    
    fdisk virtual (HBA) geometry:
    
    cylinders[500] heads[64] sectors[32] sector size[512] blocks[1024000] mbytes[500]
    
    fdisk table on entry:
    
    SYSID ACT BHEAD BSECT BEGCYL   EHEAD ESECT ENDCYL   RELSECT   NUMSECT
    
    6     0   1     1     0        63    32    99       32        204768
    
    130   128 0     1     100      63    96    243      204800    819200
    
    100   0   0     0     0        0     0     0        100       100
    
    100   0   0     0     0        0     0     0        100       100

    Finally, you would concatenate the two files (output1 and output2) together to create the disk configuration file named 500_test.


    # cat output1 output2 > 500_test 
    

    The 500_test file is shown as follows:

    * /dev/rdsk/c0t0d0p0 partition map
    
    *
    
    * Dimensions:
    
    *     512 bytes/sector
    
    *      79 sectors/track
    
    *       7 tracks/cylinder
    
    *     553 sectors/cylinder
    
    *    1481 cylinders
    
    *    1479 accessible cylinders
    
    *
    
    * Flags:
    
    *   1: unmountable
    
    *  10: read-only
    
    *
    
    *                          First     Sector    Last
    
    * Partition  Tag  Flags    Sector     Count    Sector  Mount Directory
    
           0      2    00        553    194103    194655
    
           1      3    01     194656     65807    260462
    
           2      6    00          0    819546    819545
    
           3      6    00     260463     50876    311338
    
           4      6    00     311339     72996    384334
    
           6      4    00     384335    434105    818439
    
           8      1    01          0       553       552
    
    fdisk physical geometry:
    
    cylinders[1855] heads[7] sectors[79] sector size[512] blocks[1025815] mbytes[500]
    
    fdisk virtual (HBA) geometry:
    
    cylinders[500] heads[64] sectors[32] sector size[512] blocks[1024000] mbytes[500]
    
    fdisk table on entry:
    
    SYSID ACT BHEAD BSECT BEGCYL   EHEAD ESECT ENDCYL   RELSECT   NUMSECT
    
    6     0   1     1     0        63    32    99       32        204768
    
    130   128 0     1     100      63    96    243      204800    819200
    
    100   0   0     0     0        0     0     0        100       100
    
    100   0   0     0     0        0     0     0        100       100
    

IA: How to Create a Multiple Disk Configuration File on Intel Architecture

If you need to test a profile on multiple disks, you can concatenate disk configuration files together to create multiple disk configuration scenarios.

Creating a multiple disk configuration file for an Intel architecture system involves:

  1. Concatenate a disk configuration file with itself and save it to a file.

    The new file becomes the multiple disk configuration file. For example, the following command creates a multiple disk configuration file named dual_500_test:


    $ cat 500_test 500_test > dual_500_test
    
  2. Edit the disk configuration file so that each disk device name has a different target number.

    The dual_500_test file is shown as follows:


    * /dev/rdsk/c0t0d0p0 partition map
    
    *
    
    * Dimensions:
    
    *     512 bytes/sector
    
    *      79 sectors/track
    
    *       7 tracks/cylinder
    
    *     553 sectors/cylinder
    
    *    1481 cylinders
    
    *    1479 accessible cylinders
    
    *
    
    * Flags:
    
    *   1: unmountable
    
    *  10: read-only
    
    *
    
    *                          First     Sector    Last
    
    * Partition  Tag  Flags    Sector     Count    Sector  Mount Directory
    
    0      2    00        553    194103    194655
    
    1      3    01     194656     65807    260462
    
    2      6    00          0    819546    819545
    
    3      6    00     260463     50876    311338
    
    4      6    00     311339     72996    384334
    
    6      4    00     384335    434105    818439
    
    8      1    01          0       553       552
    
    fdisk physical geometry:
    
    cylinders[1855] heads[7] sectors[79] sector size[512] blocks[1025815] mbytes[500]
    
    fdisk virtual (HBA) geometry:
    
    cylinders[500] heads[64] sectors[32] sector size[512] blocks[1024000] mbytes[500]
    
    fdisk table on entry:
    
    SYSID ACT BHEAD BSECT BEGCYL   EHEAD ESECT ENDCYL   RELSECT   NUMSECT
    
    6     0   1     1     0        63    32    99       32        204768
    
    130   128 0     1     100      63    96    243      204800    819200
    
    100   0   0     0     0        0     0     0        100       100
    
    100   0   0     0     0        0     0     0        100       100
    
    * /dev/rdsk/c0t1d0p0 partition map
    
    *
    
    * Dimensions:
    
    *     512 bytes/sector
    
    *      79 sectors/track
    
    *       7 tracks/cylinder
    
    *     553 sectors/cylinder
    
    *    1481 cylinders
    
    *    1479 accessible cylinders
    
    *
    
    * Flags:
    
    *   1: unmountable
    
    *  10: read-only
    
    *
    
    *                          First     Sector    Last
    
    * Partition  Tag  Flags    Sector     Count    Sector  Mount Directory
    
    0      2    00        553    194103    194655
    
    1      3    01     194656     65807    260462
    
    2      6    00          0    819546    819545
    
    3      6    00     260463     50876    311338
    
    4      6    00     311339     72996    384334
    
    6      4    00     384335    434105    818439
    
    8      1    01          0       553       552
    
    fdisk physical geometry:
    
    cylinders[1855] heads[7] sectors[79] sector size[512] blocks[1025815] mbytes[500]
    
    fdisk virtual (HBA) geometry:
    
    cylinders[500] heads[64] sectors[32] sector size[512] blocks[1024000] mbytes[500]
    
    fdisk table on entry:
    
    SYSID ACT BHEAD BSECT BEGCYL   EHEAD ESECT ENDCYL   RELSECT   NUMSECT
    
    6     0   1     1     0        63    32    99       32        204768
    
    130   128 0     1     100      63    96    243      204800    819200
    
    100   0   0     0     0        0     0     0        100       100
    
    100   0   0     0     0        0     0     0        100       100

    Because the dual_500_test file was created by concatenating itself, it required editing as follows:

    The first disk device name was left as is

    The second disk device name was changed from /dev/rdsk/c0t0d0p0 to /dev/rdsk/c0t1d0p0 so it has a unique target number.

    You have created a multiple disk configuration file for an Intel architecture system.