Check DNS Configuration (CHKDNSCFG)
Where allowed to run: All environments (*ALL) Threadsafe: No |
Parameters Examples Error messages |
The Check DNS Configuration (CHKDNSCFG) command checks the syntax (but not the semantics) of a Domain Name System (DNS) server's named.conf configuration file. This may include files from the /QIBM/UserData/OS400/DNS/_DYN directory.
Restrictions:
- You must have execute (*X) authority to the directories in the path /QIBM/UserData/OS400/DNS/_DYN
- You must have read (*R) authority to the /QIBM/UserData/OS400/DNS/_DYN directory files.
- You must have execute (*X) authority to the directories in the path of the configuration file.
- You must have read (*R) authority to the configuration file.
- You must have execute (*X) authority to the directories in the path of the output file.
- You must have write (*W) authority to the output file if it already exists.
- You must have read, write and execute (*RWX) authority to the output file's parent directory if the output file does not already exist.
Top |
Parameters
Keyword | Description | Choices | Notes |
---|---|---|---|
CFGFILE | Configuration file | Path name, *DFT | Optional, Positional 1 |
CHKDNSJRNF | Check journal files | *NO, *YES | Optional |
CHKZONEF | Check zone files | *NO, *YES | Optional |
DMPCFGF | Dump configuration files | *NO, *YES | Optional |
TOSTMF | Output file | Path name, *STDOUT | Optional |
Top |
Configuration file (CFGFILE)
Specifies the named.conf configuration file to check.
- *DFT
- Configuration file /QIBM/UserData/OS400/DNS/NS/named.conf is checked.
- path-name
- Specify the path name for a stream file which is the DNS server configuration file to check.
Top |
Check journal files (CHKDNSJRNF)
Specifies, when loading a data zone file, whether or not to read the DNS journal file if it exists. A DNS journal file contains zone updates that need to be merged with the master zone data file.
- *NO
- Do not read any DNS journal files for the zone.
- *YES
- Read any DNS journal files for the zone.
Top |
Check zone files (CHKZONEF)
Specifies whether or not to perform a check load of the master zone data files found in the named.conf configuration file being checked. If any errors are found, they will be displayed. If no errors are found, nothing will be displayed.
- *NO
- Do not check load the master zone data files.
- *YES
- Check load the master zone data files.
Top |
Dump configuration files (DMPCFGF)
Specifies whether or not to dump the named.conf and included files in canonical form if no errors were detected. The dump will go to the stream file identified by the Output file (TOSTMF) parameter.
- *NO
- Do not dump the configuration files.
- *YES
- Dump the configuration files.
Top |
Output file (TOSTMF)
Specifies the name of a stream file where all command output is written.
- *STDOUT
- All command output goes to the standard output device (normally the display).
- path-name
- Specify the path name for a stream file where output should be written.
Top |
Examples
Example 1: Checking the Default DNS Configuration File
CHKDNSCFG CFGFILE(*DFT) TOSTMF(*STDOUT)
This command will check configuration file /QIBM/UserData/OS400/DNS/NS/named.conf. If any errors are found, they will be sent to the standard output device. If no errors are found, nothing will be sent.
Example 2: Checking DNS Journal Files and Zone Data Files
CHKDNSCFG CFGFILE('/QIBM/UserData/OS400/DNS/NS/named.conf') CHKDNSJRNF(*YES) CHKZONEF(*YES) TOSTMF('/mydir/dnserr.txt')
This command will check the configuration file for the server NS and include checking the zone data files and any existing DNS journal files.
If any errors are found, they are written to stream file '/mydir/dnserr.txt'.
Top |
Error messages
*ESCAPE Messages
- DNS0013
- Error processing command parameters.
- DNS0065
- Option 33 of i5/OS is required, but is not installed.
- TCP7124
- Program &1 in library &2 type *PGM ended abnormally.
Top |