Job Management Partner 1/Software Distribution Administrator's Guide Volume 2
(1) netmdb_backup.bat command
This command acquires a backup of Embedded RDB. To restore the database from the backup acquired by this command, use Database Manager.
For details about this command, see 7.4.4 Backing up the database in the manual Setup Guide.
(2) netmdb_unload.bat command
This command acquires a backup of Embedded RDB for migration purposes when a new database needs to be created in a different environment, for example after a PC has been replaced. To restore the database from the backup files acquired by this command, use the netmdb_reload.bat command.
This command is stored in JP1/Software-Distribution-Manager-installation-directory\bin.
Note that if the Operation Log List window is used, it may take time to back up the database depending on the amount of operation logs to be managed.
Before you execute this command, first stop JP1/Software Distribution Manager's Remote Install Server service by choosing Services from Administrative Tools on Control Panel.
If you are using Asset Information Manager Subset, also stop the Asset Information Manager Subset services in the following order:
- World Wide Web Publishing Service or World Wide Web Publishing
- Asset Information Synchronous Service and Asset Information Manager Subset commands and tasks
- JP1/Client Security Control - Manager (applicable if JP1/CSC is linked)
If a connection pool has been set up in the ODBC data source, the connection is maintained until the timeout value specified in the connection pool is reached after an Asset Information Manager Subset job has terminated. You must wait until the connection is released before executing the command.
- Function
- This command acquires a backup needed to migrate the database. It also automatically acquires a backup of package files and operation history storage directory.
- Format
netmdb_unload.bat port-number
administrator-ID
password
/i JP1/Software-Distribution-Manager-installation-directory
/b backup-file-storage-target-directory-for-migration
/o execution-result-output-file-name
- Options
- port-number
Specifies the port number used to connect the database.
- administrator-ID
Specifies the administrator ID used to log in to the database.
- password
Specifies the password used to log in to the database.
- /i
Specifies the full path of the JP1/Software Distribution Manager installation directory.
- /b
Specifies the full path of the target directory in which the backup file for migration is to be stored. Hitachi recommends that you specify the storage directory as a string of no more than 150 bytes. If the specified path is extremely long, directory creation may fail. For the storage directory, specify the local drive. You can specify the storage directory using alphanumeric characters, the space, and the following symbols:
: . \ # @( )
- /o
Specifies the full path name of the file to which the execution result is to be output.
- Return code
- The following table shows the return codes of the netmdb_unload.bat command:
Return code |
Description |
0 |
Normal termination |
-1 |
Abnormal termination |
- Notes
- Do not change the contents of the BAT file for this command. If the file contents are changed, the command may no longer be executable.
- This command must be executed by a user with Administrator permissions.
- Specify the same administrator user ID in the netmdb_unload.bat and netmdb_reload.bat commands.
- If you unload the database, the following file and folders are created in the storage directory:
netmdbreplece file
RESOURCE folder
MONITORING folder
If any of these items already exist on the specified storage directory path at the time backup processing is performed, the existing file or folders will be overwritten.
- Specify the command options in the order shown in the format.
- Do not execute this command more than once at the same time.
- Example
- This example acquires a backup for migration using Embedded RDB.
- The example specifies the directories as follows:
- JP1/Software Distribution Manager installation directory
C:\Program Files\Hitachi\NETMDM
- Directory for storing the backup files for migration
C:\NETMDB
- Execution result output file
C:\NETMDB\unload.txt
- Before executing the command, you must create the directory for storing the backup files for migration and the directory for storing the execution result output file.
- The following shows an example of command execution:
netmdb_unload.bat port-number user-ID-of-administrator password /i "C:\Program Files\Hitachi\NETMDM" /b C:\NETMDB /o C:\NETMDB\unload.txt
(3) netmdb_reload.bat command
This command restores Embedded RDB from its backup files for migration.
This command is stored in JP1/Software-Distribution-Manager-installation-directory\bin.
Note that if the Operation Log List window is used, it may take time to restore the database depending on the amount of operation logs to be managed.
Before you execute this command, first stop JP1/Software Distribution Manager's Remote Install Server service by choosing Services from Administrative Tools on Control Panel.
If you are using Asset Information Manager Subset, also stop the Asset Information Manager Subset services in the following order:
- World Wide Web Publishing Service or World Wide Web Publishing
- Asset Information Synchronous Service and Asset Information Manager Subset commands and tasks
- JP1/Client Security Control - Manager (applicable if JP1/CSC is linked)
If a connection pool has been set up in the ODBC data source, the connection is maintained until the timeout value specified in the connection pool is reached after an Asset Information Manager Subset job has terminated. You must wait until the connection is released before executing the command.
- Function
- This command restores the database from the migration backup that was acquired by the netmdb_unload.bat command. It also restores the package files and operation history storage directory.
- Format
netmdb_reload.bat port-number
administrator-ID
password
/i JP1/Software-Distribution-Manager-installation-directory
/b backup-file-storage-target-directory-for-migration
/o execution-result-output-file-name
- Options
- port-number
Specifies the port number used to connect the database.
- administrator-ID
Specifies the administrator ID used to log in to the database.
- password
Specifies the password used to log in to the database.
- /i
Specifies the full path of the JP1/Software Distribution Manager installation directory.
- /b
Specifies the full path of the directory in which the backup file for migration is to be stored. For the storage directory, specify the local drive. You can specify the storage directory using alphanumeric characters, the space, and the following symbols:
: . \ # @ ( )
- /o
Specifies the full path name of the file to which the execution result is to be output.
- Return code
- The following table shows the return codes of the netmdb_reload.bat command:
Return code |
Description |
0 |
Normal termination |
-1 |
Abnormal termination |
- Notes
- The backup file acquired prior to database upgrading cannot be restored because the database structure is different before and after the upgrading. After upgrading the database, acquire its backup again.
- Do not change the contents of the BAT file for this command. If the file contents are changed, the command may no longer be executable.
- This command must be executed by a user with Administrator permissions.
- Specify the same administrator user ID in the netmdb_unload.bat and netmdb_reload.bat commands.
- Specify the command options in the order shown in the format.
- Do not execute this command more than once at the same time.
- Example
- This example restores Embedded RDB from the backup for migration that was acquired by the netmdb_unload.bat command.
- The example specifies the directories as follows:
- JP1/Software Distribution Manager installation directory
C:\Program Files\Hitachi\NETMDM
- Directory storing the backup files for migration
C:\NETMDB
- Execution result output file
C:\NETMDB\unload.txt
- Before executing the command, you must create the directory for storing the execution result output file.
- The following shows an example of command execution:
netmdb_reload.bat port-number user-ID-of-administrator password /i "C:\Program Files\Hitachi\NETMDM" /b C:\NETMDB /o C:\NETMDB\unload.txt
(4) netmfile_backup.bat command
When Microsoft SQL Server or Oracle is used as the JP1/Software Distribution Manager relational database, this command is used to back up package files and operation history files.
This command is stored in JP1/Software-Distribution-Manager-installation-directory\bin.
Before you execute this command, first stop JP1/Software Distribution Manager's Remote Install Server service by choosing Services from Administrative Tools on Control Panel.
- Function
- The netmfile_backup.bat command backs up the package files and operation history files to the specified storage directory.
- Format
netmfile_backup.bat /P /h [/d]
/i JP1/Software-Distribution-Manager-installation-directory
/b backup-file-storage-directory
/o execution-result-output-destination-file-name
- Regarding the /P and /h options, make sure that you specify one or both of them.
- Options
- /P
Specifies that the package files are to be backed up. Note that if you use Microsoft SQL Server and store packages in the database, this option is ignored if it is specified.
If this option is specified, the command creates the RESOURCE folder in the storage directory and stores a backup of the package files.
- /h
Specifies that the operation history files are to be backed up.
If this option is specified, the command creates the MONITORING folder in the storage directory and stores a backup of the operation history files.
- /d
Specifies that the backup files are to be stored in separate folders according to command execution date and time. When this option is specified, the command creates folders that indicate the command execution date and time in the format YYYYMMDDhhmmss (year-month-date-hour-minute-second) under the backup file storage directory, and then acquires backup files in the appropriate folders.
- /i
Specifies the full path of the JP1/Software Distribution Manager installation directory.
- /b
Specifies the full path of the backup file storage directory. Hitachi recommends that you specify the storage directory as no more than 150 bytes in length. If the specified path is too long, creation of the directory may fail.
- /o
Specifies the full path of the execution result output file name. If the specified file already exists, it will be overwritten.
- Return codes
- The following table lists and describes the return codes that are set during execution of the netmfile_backup.bat command.
Return code |
Description |
Action |
0 |
Normal termination |
None |
-1 |
Invalid parameter |
Check and, if necessary, revise the parameters. |
-2 |
Acquisition of registry information failed. |
- Check whether the user who executed the command is authorized to access the registry.
- Make sure that JP1/Software Distribution Manager was installed correctly.
|
-3 |
File copy operation failed. |
- Make sure that the specified path is correct.
- Check whether the user who executed the command is authorized to access the specified directory.
- Check the result output file for the execution result.
|
-4 |
Access to the network drive failed. |
Check and, if necessary, revise the settings (login ID, password, and domain name) specified on the Network Connection page at setup. |
-5 |
An open error occurred in the result output file. |
- Make sure that the specified path is correct.
- Check whether the user who executed the command is authorized to access the specified directory.
|
- Notes
- Do not change the contents of the BAT file for this command. If the file contents are changed, the command may no longer be executable.
- This command must be executed by a user with Administrator permissions.
- Specify the command options in the order shown in the format.
- Do not execute this command more than once at the same time.
- If you omit the /d option and if the RESOURCE or MONITORING folder already exists on the path specified for the storage directory, the folder will be overwritten.
- Example
- This example backs up the package files and operation history files by creating a command execution date/time folder when Microsoft SQL Server or Oracle is used.
- The example specifies the following directories:
- JP1/Software Distribution Manager installation directory
C:\Program Files\Hitachi\NETMDM
- Backup file storage directory
C:\Backup
- Execution result output file name
C:\Backup\Backup.txt
- Before you execute the command, create the backup file storage directory and the directory for storing the execution result files.
- The following shows an example of command execution:
netmfile_backup.bat /P /h /d /i "C:\Program Files\Hitachi\NETMDM" /b C:\Backup /o C:\Backup\Backup.txt
(5) netmfile_restore.bat command
When Microsoft SQL Server or Oracle is used as the JP1/Software Distribution Manager relational database, this command is used to restore package files and operation history files from their backup files.
This command is stored in JP1/Software-Distribution-Manager-installation-directory\bin.
Before you execute this command, first stop JP1/Software Distribution Manager's Remote Install Server service by choosing Services from Administrative Tools on Control Panel.
- Function
- The netmfile_restore.bat command restores the package files and operation history files from their backup files, which are stored in the specified directory.
- Format
netmfile_restore.bat /P /h
/i JP1/Software-Distribution-Manager-installation-directory
/b backup-file-storage-directory
/o execution-result-output-destination-file-name
- Regarding the /P and /h options, make sure that you specify one or both of them.
- Options
- /P
Specifies that the package files are to be restored. Note that if you use Microsoft SQL Server and store packages in the database, this option is ignored if it is specified.
If this option is specified, the command restores the package files from the RESOURCE folder in the backup file storage directory.
- /h
Specifies that the operation history files are to be restored.
If this option is specified, the command restores the operation history files from the MONITORING folder in the backup file storage directory.
- /i
Specifies the full path of the JP1/Software Distribution Manager installation directory.
- /b
Specifies the full path of the backup file storage directory. If the execution date/time folders were created during backup processing, specify the appropriate folder.
- /o
Specifies the full path of the execution result output file name. If the specified file already exists, it will be overwritten.
- Return codes
- The following table lists and describes the return codes that are set during execution of the netmfile_restore.bat command.
Return code |
Description |
Action |
0 |
Normal termination |
None |
-1 |
Invalid parameter |
Check and, if necessary, revise the parameters. |
-2 |
Acquisition of registry information failed. |
- Check whether the user who executed the command is authorized to access the registry.
- Make sure that JP1/Software Distribution Manager was installed correctly.
|
-3 |
File copy operation failed. |
- Make sure that the specified path is correct.
- Check whether the user who executed the command is authorized to access the specified directory.
- Check the result output file for the execution result.
|
-4 |
Access to the network drive failed. |
Check and, if necessary, revise the settings (login ID, password, and domain name) specified on the Network Connection page at setup. |
-5 |
An open error occurred in the result output file. |
- Make sure that the specified path is correct.
- Check whether the user who executed the command is authorized to access the specified directory.
|
- Notes
- Do not change the contents of the BAT file for this command. If the file contents are changed, the command may no longer be executable.
- This command must be executed by a user with Administrator permissions.
- Specify the command options in the order shown in the format.
- Do not execute this command more than once at the same time.
- Example
- This example restores the package files and operation history files from the backup files in the backup execution date/time folder 20081217120030 when Microsoft SQL Server or Oracle is used.
- This example specifies the following directories:
- JP1/Software Distribution Manager installation directory
C:\Program Files\Hitachi\NETMDM
- Backup file storage directory
C:\Backup\200812170030
- Execution result output file name
C:\Backup\Backup.txt
- Before you execute this command, create the directory for storing the execution result files.
- The following shows an example of command execution:
netmfile_restore.bat /P /h /i "C:\Program Files\Hitachi\NETMDM" /b C:\Backup\200812170030 /o C:\Backup\Backup.txt
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.