In command mode, iCk responds to the commands listed below. Each command, except the first command, sends a message to the iCk daemon process. All commands can be abbreviated to the shortest unique string, hence au is sufficient to identify the autoreboot function and ac the activate function. For most commands, one letter is sufficient.
x " | " exit " | " ^D
This command exits from the interactive command mode. This does not affect the iCk daemon process.
bootCnts [ period ]
This command computes the UNIX reboot information from the /etc/wtmp file. If period is supplied, the specified length of time is used. If it is not supplied, the window period of time for the $autoReboot rule is used. This command generates three numbers: the total number of boot events in the specified period of time prior to and including the current boot event, the number of boot events that were anticipated (or deliberate), and the number of unanticipated boot events. This request does not communicate with the iCk daemon process.
autoReboot {set | clear}
This command forces the kernel auto-reboot flag into the specified state.
readRules [rule-file]
This command rereads the rules file. If a new file name is provided, it is read instead of the previous file. Before you use this command, check the new rules using the iCkAdmin command to insure syntactic correctness.
wakeup
This command makes the iCk daemon wake up immediately and check its state.
rescanBB
This command makes the iCk daemon wakeup and reexamine the Bulletin Board for new instances of known process types.
quit
This command causes the iCk daemon to exit gracefully. (Since iCk is normally run from the /etc/inittab file, init immediately respawns the daemon.) In interactive mode, the command requires confirmation.
verbosity {value}
This command sets the iCk daemon's verbosity flags to the specified values. In this case the symbolic names, as well as octal, decimal, or hexidecimal values, are accepted. Combined values can be produced by separating values with the pipe ( | ).
activate {spec}
This object, in conjunction with the V_TRACE flag, causes the activities specified by {spec} to be logged whenever they run.
inhibit {spec}
This object, in conjunction with the V_TRACE flag, causes the activities specified by {spec} to not be logged whenever they run.
print {spec}
This object logs the status of the activities specified by {spec}. The status information logged as a result of the print command varies based on the activity. The common information printed is the activity index, which may be used in future {spec}s, the rule index, which should correspond to the position of the rule in the rules file, and the type of the activity. In addition, there is the a_clockID, which is non-zero if an alarm is running for the current activity, and the a_nextAlarm, which indicates at what time the next alarm is set to expire. At the end of the entry is a value, as described in the following table:
Value |
Description |
a_flags |
0, meaning no flags are set |
AF_SUPPRESS_TIMING |
Timing is deliberately suppressed for the time being |
AF_CHECK_NEW_RUNLEVEL |
When the run levels change, this activity is checked to see if it should reactivate |
AF_DEBUG_OFF |
Set for any activity that has been inhibited by the inhibit command |
There is also the a_state, which indicates the current state of the activity. Its values are described in the following table:
Value |
Description |
AS_INACTIVE |
This value is not currently being processed |
AS_TIMER_RUNNING |
There is currently an alarm outstanding for this activity |
AS_SERVICE_QUEUED |
An alarm expired for this activity, but has not yet been processed |
AS_IN_PROGRESS |
An activity is currently being processed |
The above-mentioned commands, activate, inhibit, and print, require an activities specification. Such a specification is defined from the list of objects described in the following table. More than one object can be combined with the pipe ( | ):
Object |
Description |
rescanBB |
The $rescanBB activity |
timingMsg |
All the $timingMsg activities |
hungProcess |
The $hungProcess activities |
autoReboot |
The $autoReboot activity |
fileMax |
All the $fileMax activities |
fileCheck |
All the $fileCheck activities |
miscellaneous |
This object applies to the print command only. It causes a report of whether the autoreboot flag has been automatically set or not, the state of the UNIX kernel autoreboot flag, the current run level, the number of rules read, and the number activities currently in force to be logged. |
all/ALL |
Specifies all activities |
NNN |
This object, where NNN are digits, specifies an explicit activity by its index in the array of all activities |
All remaining information is activity-specific. The information logged by activity is described in the following table:
Information |
Description |
Comments |
$timingMsg |
The name of the process, the Bulletin Board slot, and instance |
� |
$hungProcess |
The name of the process, the PID, the Bulletin Board state, work count, time, flag, slot, and instance |
The flag can have values of:
|
$autoReboot |
The computed unanticipated boot event count at the time the system last booted plus the length of the period over which the computation is made |
� |
$fileMax |
The name of the file |
� |
$fileCheck |
The name of the file |
� |
core |
This command is available for debugging purposes |
Causes iCk to produce a core file in /tmp/iCk.core via a core dump operation that is a spawned child process. In other words, iCk itself does not stop, but you do get a reliable core of iCk for debugging evaluation. |