Client return codes
The space management client command-line interface exits with return codes that accurately reflect the success or failure of the operation.
Scripts, batch files, and other automation facilities can use the return code from the command-line interface. For operations that use the IBM Spectrum Protect™ scheduler, the return codes are shown in the output of the QUERY EVENT administrative command. For cases where the return code is not 0, you can examine the dsmerror.log file. For scheduled events, you can examine the dsmsched.log file.
Return codes have the following meanings:
| Code | Explanation |
|---|---|
| 0 | All operations completed successfully. |
| 4 | The operation completed successfully,
but some files were not processed. There were no other errors or warnings.
This return code is common. In most cases, files are not processed
for the following reasons:
|
| 8 | The operation completed with at least one warning message. Review the dsmerror.log file to determine what warning messages were issued and to assess their effect on the operation. |
| 12 | The operation completed with at least one error message (except for error messages for skipped files). For scheduled events, the status is Failed. Review the dsmerror.log file to determine what error messages were issued and to assess their effect on the operation. Generally, this return code means that the error was severe enough to prevent the successful completion of the operation. For example, an error that prevents an entire file system from being processed yields return code 12. |
The return code for a client macro is the highest return code issued among the individual commands that comprise the macro. For example, suppose that a macro consists of these commands:
selective "/home/devel/*" -subdir=yes
incremental "/home/devel/TestDriver/*" -subdir=yes
archive "/home/plan/proj1/*" -subdir=yes
If the first command completed with return code 0; the second command completed with return code 8; and the third command completed with return code 4, the return code for the macro is 8.
