JavaScript is required to for searching.
跳过导航链接
退出打印视图
Oracle Solaris 11 安装手册页     Oracle Solaris 11 Information Library (简体中文)
search filter icon
search icon

文档信息

前言

系统管理命令

aimanifest(1M)

distro_const(1M)

installadm(1M)

js2ai(1M)

文件格式

distro_const

- 用于创建 Oracle Solaris 映像和介质的实用程序

用法概要

/usr/bin/distro_const
distro_const --help
distro_const build [-v] [-r checkpoint name] [-p checkpoint name] [-l] manifest

描述

distro_const 命令使用户能够通过将指定的清单文件用作映像蓝图来创建映像。

可以创建用于在 x86 系统或 SPARC 系统上安装 Oracle Solaris 操作系统的文本安装程序映像。

或者可以创建相当于包含 Oracle Solaris 操作系统的 LiveCD 映像的 ISO 映像。

或者,您可以创建可用于 SPARC 客户机上 Oracle Solaris OS 的网络安装的 SPARC AI ISO 映像,或者可用于 x86 客户机上 Oracle Solaris OS 的网络安装的 x86 AI ISO 映像。

亦或者,可以创建定制 ISO 映像。

不带选项的基本 distro_const 命令在一个步骤中创建完整映像。

命令选项使用户能够在各种检查点暂停和继续映像创建过程,从而使用户能够在每个阶段查看映像的状态并检查已知问题。检查点通过允许您忽略已执行至少一次的冗长步骤来节省构建时间。


注 - 您必须采用超级用户角色或具有超级用户特权来运行 distro_const 命令。

使用分发构造器时,只能在 SPARC 系统上创建 SPARC 映像。并且,只能在 x86 系统上创建 x86 映像。此外,系统上的操作系统发行版必须与您构建的映像的发行版相同。


子命令

distro_const 命令具有下面列出的子命令和选项。另请参见“示例”部分。

--help

显示用法。

build

distro_const build manifest

需要 "build" 子命令。

将指定的清单文件用作映像的蓝图来创建完整映像。需要清单名称。

-v distro_const build - v

指定详细模式。

-l distro_const build [- l] manifest

列出您可以选择停止或继续构建映像的所有有效检查点。该命令选项查询清单文件以寻找有效检查点。对于其他检查点命令选项,将该命令提供的名称用作有效值。需要 build 子命令。

检查点值取决于清单文件中的条目。

-p distro_const build [- p checkpoint] manifest

构建映像,但在指定的检查点名称处暂停构建映像。使用 -l 选项查找有效名称。可以将 -r 选项和 -p 选项结合使用。需要检查点名称和清单名称。需要 build 子命令。

-r distro_const build [- r checkpoint] manifest

从指定的检查点名称处继续构建映像。指定的名称必须是上一次构建停止执行的检查点,或者是更早的检查点。以后的检查点无效。使用 -l 选项可确定可继续进行的检查点。-p 选项可与 -r 选项结合使用。需要检查点名称和清单名称。需要 build 子命令。

-h distro_const [- h]

显示命令用法。

示例

示例 1 使用检查点选项创建映像

  1. 检查可用的检查点。本示例中的清单名称为 dc_livecd.xml

    # distro_const build -l /usr/share/distro_const/dc_livecd.xml

    显示有效的检查点名称,如本样例输出。

     
    
      Checkpoint           Resumable  Description
      --------------------------------------------
      transfer-ips-install X Transfer pkg contents from IPS
      set-ips-attributes   X Set post-install IPS attributes
      pre-pkg-img-mod      X Pre-package image modification
      ba-init              X Boot archive initialization
      ba-config            X Boot archive configuration
      ba-arch              X Boot archive archival
      grub-setup           X Set up GRUB menu
      pkg-img-mod          X Pkg image area modification
      create-iso             ISO media creation
      create-usb             USB media creation     
  2. 开始构建映像,在 ba-init 检查点暂停。

    # distro_const build -p ba-init /usr/share/distro_const/dc_livecd.xml
  3. 从 ba-init 检查点重新启动构建。完成创建映像。

    # distro_const build -r ba-init /usr/share/distro_const/dc_livecd.xml

示例 2 在一个步骤中创建映像

要运行完整的映像构建过程而不暂停,请使用不带检查点选项的基本 distro_const 命令。清单文件名称为 dc_livecd.xml。

# distro_const build /usr/share/distro_const/dc_livecd.xml

属性

有关下列属性的说明,请参见 attributes(5)

属性类型
属性值
可用性
install/distribution-constructor
接口稳定性
Under Development(开发中)

另请参见

dc_manifest(4)

在 OTN 文档库中为当前版本创建定制 Oracle Solaris 11 安装映像