Used to check that the mapping information in the devices file is valid.
chkdev {-a} {-p} {[-q || -s]} {[-d database || -f filename || -r ]}
If no options are specified, the devices file in your default database will be checked for serious errors only.
-a All. Reports warnings as well as errors, identifying less serious errors such as overlapping port ranges which would not otherwise be reported.
-p Generate port usage statistics. Reports the highest port number used in the file and a list of available port numbers not currently assigned to PLIds.
-q Quiet. This option suppresses the detail lines that describe each individual error. Only the summary line stating the number of errors (and warnings if -a was specified) is output.
-s Silent. All output is suppressed but the exit status is still set according to the state of the file. This option is intended for use in scripts.
-d database Specify database name. chkdev reads the devices file in the database configs directory.
-f filename Specify file name explicitly. chkdev reads the file specified.
-r Specifies the default devices file which Reality uses if there is no database devices file in the appropriate configs directory.
PLId to Port mapping enables fixed port numbers to be allocated to incoming terminal connections using their Physical Location Identifiers (PLIds), so that when a user logs on at the same terminal, the same port number is always allocated.
The fixed mapping of PLId to port number is defined in the devices file. Each database can have its own devices file in the following location:
UNIX: $REALDBASE/configs
Windows: %REALDBASE\configs
There is also a default devices file which Reality uses if there is no database devices file in the appropriate configs directory:
UNIX: $REALROOT/files
Windows: %REALROOT%\files
In order to be valid, mapping entries in the devices file must be in a defined format and contain PLId and port identities within defined limits, otherwise an error is generated, causing the PLId to Port Mapping software to ignore them, or generate a warning.
See PLId to Port Mapping for more information.
If you are using Database Isolation, you must use realroot to select required instance of Reality before running chkdev.
Errors and warnings relating to the devices file are reported to stdout.
Serious errors which prevent the program from running are reported to stderr (for example, errors in command line parameters, or failure to open the specified file).
chkdev exits with one of the following exit codes:
0 No errors or warnings.
1 One or more warnings, no errors. (Only possible if the -a option is specified.)
2 One or more errors detected.
3 Serious error such as ‘file not found’.
$REALDBASE/configs/devices
$REALROOT/files/devices
$REALROOT/files/devices.tmpl
%REALDBASE%\configs\devices
%REALROOT%\files\devices
%REALROOT%\files\devices.tmpl