Description
Registers, updates, deletes, and lists software information managed by Systemwalker Software Configuration Manager.
Synopsis
[Windows]
swcfmg_software.exe { -add [-sourceid "Information collection source ID"] -file "Software information file path" [-e "Character encoding"] | -update [-sourceid "Information collection source ID"] -file "Software information file path" [-e "Character encoding"] | -delete -id "Software ID",... | -list [-sourceid "Information collection source ID"] [ -file "Output file path"] [-e "Character encoding"] } |
[Linux]
swcfmg_software { -add [-sourceid "Information collection source ID"] -file "Software information file path" [-e "Character encoding"] | -update [-sourceid "Information collection source ID"] -file "Software information file path" [-e "Character encoding"] | -delete -id "Software ID",... | -list [-sourceid "Information collection source ID"] [-file "Output file path"] [-e "Character encoding"] } |
Options
Registers software information using the specified software information file. The software information is registered as software of the information collection source specified using the information collection source ID. When the information collection source ID is omitted, it is registered as manually registered software.
The software information file is in CSV format. Refer to "6.3.1 Software Information File" for information on software information files.
Updates software information using the specified software information file. Updates the software of the information collection source specified using the information collection source ID. When omitting the information collection source ID, update the manually registered software.
The software information file is in CSV format. Refer to "6.3.1 Software Information File" for information on software information files.
Deletes registered software information. Multiple software IDs can be specified by delimiting them with ',' (comma).
The software ID is configured during registration of this command or the discovery of software application. Specifying -list allows the software ID to be checked from the software information output.
Outputs registered software information in CSV format. Outputs only the software of the information collection source specified using the information collection source ID. When the information collection source ID is omitted, the manually registered software is output.
If -file <Output file path> is omitted, information will be output to the standard output for the command.
If the specified file does not exist, a new file will be created. If the file exists, the existing file will be overwritten.
If the file cannot be output because of an error, either a new file will not be created or, if an existing file was to be overwritten, the existing file will be kept as it is, without being overwritten.
Specify the character encoding for the file.
The character encodings below can be specified (single-byte uppercase characters must be used):
UTF-8
If this option is omitted, the character encoding of the execution environment of this command will be used.
Return value
Return value | Meaning |
---|---|
0 | Completed normally. |
10 | A parameter error has occurred. |
20 | There is an error in the specified I/O file path. |
30 | The specified character encoding is incorrect. |
40 | Failed to read the software information file. |
50 | The software information file description is incorrect. |
70 | The specified information collection source ID or software ID does not exist. |
80 | The software information targeted for deletion cannot be deleted because the parameter settings information or the installed software information has been registered. |
100 | Systemwalker Software Configuration Manager is not running. |
101 | A command that cannot be executed at the same time as this command is executing. |
102 | You do not have the privileges required to execute this command. |
110 | A write error has occurred. |
200 | Setup has not been performed. |
255 | A system error has occurred. |
Command location
Admin server
[Windows]
<Systemwalker Software Configuration Manager installation directory>\SWCFMGM\bin |
[Linux]
/opt/FJSVcfmgm/bin |
Privilege required for execution
[Windows]
Administrator privileges are required. Execute this command as an administrator.
This command can be executed on the admin server.
[Linux]
This command can only be executed by the system administrator (superuser).
This command can be executed on the admin server.
Notes
Commands provided by Systemwalker Software Configuration Manager cannot be executed simultaneously. An exclusive control error will occur if a command is executed while another command is still executing.
Execute this command while Systemwalker Software Configuration Manager is running.
Using this command, the information collection source cannot register, update, or delete the software of UpdateAdvisor.
Only the value of the definition item can be registered and updated.
Software information is registered in accordance with the software information file.
The value of the identification item cannot be omitted. When all identification items are the same, software are recognized as being the same. Furthermore, when the same software is already registered, an error occurs.
Behavior is not guaranteed if the character encoding specified for this command does not match the character encoding used in the software information file. Ensure that the character encoding matches.
When updating registered software information, it is advisable to edit the file that is listed, then treat the edited file as the input file for updating.
The value of the identification item cannot be omitted. In addition, the value of the identification item cannot be updated.
An error will occur in the input file if the description does not include <Software ID>. When updating, always include <Software ID>.
Use this command to delete software information that no longer needs to be managed by Systemwalker Software Configuration Manager.
Before deleting software information, confirm the following:
The corresponding software has not been registered as installed software.
Patches for the corresponding software are not registered
If no software information has been registered, only the header information will be output.
#software-id,software-info,... |
If there is an error in the software information file, registration and update of the software information will be canceled. An error message similar to the following will be output to the standard output:
The file description is incorrect.[Line number:<n>](Cause:<Cause>) |
One of the following messages will be output in <Cause>:
Message | Meaning |
---|---|
Number of elements. | Review the number of elements in the line indicated. |
Mandatory elements are not specified. | Enter the mandatory items in the line indicated. |
The same software is specified in another line. | The same software information is already specified in one of the preceding lines. |
The specified elements are invalid. | An invalid value is entered in the element in "()" in the line indicated. Enter a valid value. For details on available values, refer to "6.3.1 Software Information File". Omit the values of collection items which are not definition items. |
The specified software does not exist. | Software information corresponding to "software-id" in the line indicated does not exist. Specify the existing software ID. |
The software has already been registered. | The software information in the line indicated has already been registered. |
Examples
Registration
[Windows]
swcfmg_software.exe -add -file C:\work\softwareinfo.csv |
[Linux]
swcfmg_software -add -file /tmp/softwareinfo.csv |
Update
[Windows]
swcfmg_software.exe -update -file C:\work\softwareinfo.csv |
[Linux]
swcfmg_software -update -file /tmp/softwareinfo.csv |
Deletion
[Windows]
swcfmg_software.exe -delete -id 34GR4GJLJ@Direct,GIDFGJO43@Direct,5YUYJG935@Direct |
[Linux]
swcfmg_software -delete -id 34GR4GJLJ@Direct,GIDFGJO43@Direct,5YUYJG935@Direct |
List display
[Windows]
swcfmg_software.exe -list -file C:\work\softwareinfo.csv |
[Linux]
swcfmg_software -list -file /tmp/softwareinfo.csv |
Execution results/output format
List display
#software-id,software-info,... 34GR4GJLJ@Direct,ABCDE-Software,1.0,windows,ABCDE Company file output
Output of the software information has started. Output of the software information has ended.
Note that the following header information is added to the first line of the CSV file that is output:
#software-id,software-info,...