Job Management Partner 1/Software Distribution Administrator's Guide Volume 2
4.15 dcmpkget.exe (acquiring a backup of a package)
(1) Function
This command creates a backup of the specified package.
(2) Format
dcmpkget.exe /i parameter-file /o output-directory
[/of result-output-file-name]
[/LC {ON|OFF}]
(3) Arguments
- /i
In parameter-file, specify the full pathname of the parameter file.
You can use a file generated by the dcmpack command as the parameter file to be specified in this command. However, the command ignores package_name in the PACKAGING_INFORMATION tag.
- /o
In output-directory, specify the full pathname of the directory for containing the backup file set that the command will create. If the specified directory does not exist, the command automatically creates the directory. You cannot specify a network drive as the output directory.
- /of
In result-output-file-name, specify the base name of the backup file set you want to create in the output directory. This argument is optional, and the default is dcmpkget. The base name specified in this argument is combined with the package attributes (package type, cabinet ID, package ID, version, and generation) to create a backup file name. The command adds the extensions .DPF, .SCI, and .PKG to this backup file name to generate three files. Note that if / is included in Version, / is replaced by $ and a file name with $ is created.
The backup file name can contain up to 256 characters. If the backup file name generated by adding the package attributes exceeds 256 characters, the command automatically truncates the name.
In result-output-file-name, you can also specify the reserved words \CY, \CM, \CD, \CH, \CN, \CS, \VERSION, and \PKGID. For \VERSION and \PKGID, the command references the first package definition. If they are not found in the definition, the command ignores \VERSION and \PKGID. For details about the reserved words, see 4.27 Reserved word specification method.
- /LC
Specify ON or OFF to indicate whether the command's processing is to continue after logging off from Windows when Task Scheduler or JP1/AJS is used to execute commands in the background.
- ON
Continues command processing even after logging off from Windows.
- OFF
Forcibly terminates command processing once Windows is logged off.
This argument is effective when the command is executed from a service under any of the following OSs:
- Windows NT 4.0
- Windows 2000
- Windows XP
- Windows Server 2003 (excluding Windows Server 2003 (IPF))
Do not specify /LC ON when you execute the command from the command prompt, because in this case the command is executed as a foreground program.
You can use a registry setting to specify whether command processing is to continue after Windows is logged off. For details about the registry setting, see the following sections:
- Executing the command in JP1/Software Distribution Manager
4.6 Registry settings (JP1/Software Distribution Manager) in the manual Setup Guide
- Executing the command in JP1/Software Distribution Client (relay system)
5.4 Registry settings (JP1/Software Distribution Client (relay system)) in the manual Setup Guide
Note that operation may differ depending on the combination of the /LC specification and the registry setting. For details, see 4.28 Command operation at logoff that depends on a registry setting and logoff option.
(4) Parameters in a parameter file and corresponding command arguments
You can also use command arguments to specify the contents of the parameter file used in this command. The table below shows the correspondence between the contents of a parameter file and the command arguments.
If you use both a parameter file and a command argument to specify an item, the value of the command argument prevails over the value specified in the parameter file. However, if you use command arguments to specify only some of the package attributes, the first package information set of the PACKAGING_INFORMATION tag in the parameter file is used.
Table 4-15 Correspondence between parameter file contents and arguments (dcmpkget command)
Parameter file specification contents |
Description |
Specification |
Command argument |
Tag |
Parameter |
PACKAGING_INFORMATION#1 |
package_name |
Package name |
X |
-- |
package_id |
Package ID |
R#2 |
/I value |
version_revision |
Version/revision |
R#2 |
/v value |
generation |
Generation |
R#2 |
/G value |
cabinet_name |
Cabinet name |
X |
-- |
cabinet_id |
Cabinet ID |
R |
/C value |
package_code |
Package code |
O |
/KW or /KP |
- Legend:
- R: required.
- O: optional.
- X: not required (ignored if specified).
- --: Cannot be specified in a command argument.
- #1
- This command does not accept the reserved words used in the parameters of the PACKAGING_INFORMATION tag.
- #2
- You can omit these parameters if you specify the cabinet ID only. If you specify the cabinet ID only, the command creates backups of all the packages in the cabinet.
(5) Format of the command without using a parameter file
The following shows the format of the command when you specify the command by using arguments only instead of using a parameter file:
dcmpkget.exe /I package-ID /v version/revision-number /G generation-number
/C cabinet-ID [/KW|/KP] /o output-directory
[/of result-output-file-name] [/LC {ON|OFF}]
(6) Return codes
The following explains the return codes that the dcmpkget command may return:
Code |
Meaning |
Action |
0 |
The file output was successfully completed. |
None. |
1 |
The command cannot open the specified parameter file or the format of the specified parameter file is incorrect. |
Check the pathname or format of the parameter file. |
2 |
An invalid value is specified in a command argument or in the parameter file. |
Check the values of command arguments or the values of the parameters in the parameter file. |
3 |
Error during connection to managing server. |
- Check the version of the managing server.
- Check the job execution status.
|
4 |
The specified package does not exist. |
- Ensure that the specified package exists in the managing server.
- Check the job execution status.
|
12 |
Other errors occurred. |
Check the event log. |
14 |
The command could not create the output directory or output file. |
Check the paths of the output directory and the output file. |
If JP1/Base is linked to manage JP1/Software Distribution users, see 1.3.3 Setting for executing commands.
- You can specify more than one package in this command. If one of the specified packages does not exist, the command skips creating a backup of the non-existent package and continues processing for the subsequent packages. If the dcmpkget command skipped the processing for a package, the command returns the return code 4.
- If the dcmpkget command has more than one package specified and fails during processing, the command cancels creating the backups of the packages. The command deletes all the backups created before the error occurred and returns a code indicating an error.
- If a UNIX package that was created without specifying a script file is backed up, no SCI file is output.
(8) Example
The following is an example of making a backup of a package whose package ID is 0100, version/revision number is 0100, and generation number is 0000 in the cabinet whose cabinet ID is 01.
(a) Creating a parameter file
Specify in a parameter file the package and cabinet to be backed up as described below, and save the parameter file with any name:
** dcmpkget Parameter File Sample
PACKAGING_INFORMATION{
package_id=0100
version_revision=0100
generation=0000
cabinet_id=01
package_code=P
}
(b) Command execution
To save the parameter file as C:\Dmbat\dcmpkget.txt and the backup file as C:\Dmbat\backup, specify the following command:
dcmpkget.exe /i C:\Dmbat\dcmpkget.txt /o C:\Dmbat\backup /of BackupFile
All Rights Reserved. Copyright (C) 2009, 2013, Hitachi, Ltd.
Copyright, patent, trademark, and other intellectual property rights related to the "TMEng.dll" file are owned exclusively by Trend Micro Incorporated.