new_dz_command

Use the new_dz_command command to create a new UNIX command object for the current zone and sets the new command as the currently selected command in memory. The new command has no field values set. The new_dz_command does not save the new command to Active Directory. To save the UNIX command, you must first set at least the “command” field using set_dzc_field, then use save_dz_command. If you don’t save a new UNIX command, it will disappear when you select a new command or when the ADEdit session ends.

You can only use the new_dz_command command if the currently selected zone is a classic4 or hierarchical zone. The command does not work in other types of zones.

Zone type

Classic and hierarchical

Syntax

new_dz_command name

Abbreviation

newdzc

Options

This command takes no options.

Arguments

This command takes the following argument:

Argument Type Description

name

string

Required. Specifies the name to assign to the new UNIX command.

Return value

This command returns nothing if it runs successfully.

Examples

new_dz_command account_manager

This example creates a new UNIX command named account_manager in the current zone.

Related commands

Before you use this command, you must have a currently selected zone stored in memory. The following commands enable you to view and select UNIX commands:

  • get_dz_commands returns a Tcl list of UNIX commands in the current zone.
  • list_dz_commands returns a list of all UNIX commands in the currently selected zone.
  • select_dz_command retrieves a UNIX command from Active Directory and stores it in memory.

After you have a UNIX command stored in memory, you can use the following commands to work with that command:

  • delete_dz_command deletes the selected command from Active Directory and from memory.
  • get_dzc_field reads a field value from the currently selected command.
  • save_dz_command saves the selected command with its current settings to Active Directory.
  • set_dzc_field sets a field value in the currently selected command.