The event DATABASEFULL belongs to an event category that is always active. This means that it is triggered by the database system as soon as the data area is full.
You now have to define how it is to be handled by the event dispatcher. To do this, you enter an event definition in the configuration file of an event dispatcher and start the event dispatcher. Whenever the database system triggers the corresponding event, it will be handled according to this event definition.
To read the prerequisites, see Database Manager CLI, event_set
Event Dispatcher documentation, add
Concepts of the Database System, Database Event Categories
When the data area of DEMODB on the local database computer is full, an event dispatcher should ensure that the event DATABASEFULL is displayed as an error in the Microsoft Windows Event Viewer with a MaxDB entry.
The configuration file for the event dispatcher should be saved with the name testconfig.txt in the directory C:\test.
The log file of the event dispatcher should be saved in the same directory with the file name testlog.txt.
1. Create a configuration file for the event dispatcher and enter the event definition.
>dbmevtdisp add c:\test\testconfig.txt Name == DATABASEFULL Priority == HIGH Command == "EVENTCREATE /T ERROR /id 100 /L APPLICATION /D \"Database Full\" /SO "MaxDB""
2. Start the event dispatcher
>dbmevtdisp start c:\test\testconfig.txt -l testlog.txt -u DBADMIN,SECRET –d DEMODB
Event Dispatcher instance 1 running
using configuration file c:\test\testconfig.txt
event with name DISPINFO:DISPSTART not dispatched (count 0)
As soon as the data area of DEMODB is full, the database system triggers the event DATABASEFULL.
The event dispatcher is on and will display the event in the Microsoft Windows Event Viewer according to the event definition, with the Type Error, Source MaxDB and the Description Database Full.
The output for the command dbmevtdisp start is continuously updated by the event dispatcher:
event with name DBFILLINGABOVELIMIT not dispatched (count 3)
event with name DBFILLINGABOVELIMIT not dispatched (count 4)
event with name LOGSEGMENTFULL not dispatched (count 5)
event with name AUTOSAVE not dispatched (count 6)
event with name AUTOSAVE not dispatched (count 7)
event with name DBFILLINGABOVELIMIT not dispatched (count 8)
Event with name DATABASEFULL dispatched (count 9)