next up previous contents
Next: The Cache Subsystem Up: ConceptBase V7.0 User Manual Previous: The View Language CBVL

The ConceptBase Server

 

The ConceptBase server offers TCP/IP access to the functionality of the O-Telos languages. Specifically, it allows to TELL or UNTELL O-Telos objects and to ASK O-Telos object bases. The operations are called by clients (for example, the user interfaces described in section 4). An arbitrary number of clients can connect to a single ConceptBase server.

The ConceptBase server is startedgif by a command line

  <CB_HOME>/bin/CBserver <params>

or on Microsoft Windows

  <CB_HOME>\bin\CBserver.bat <params>

where CB_HOME is the installation directory of ConceptBase. The following parameters are available:

-d db
Set database db to be loaded. If the database does not exist it is created and initialized with the O-Telos pre-defined objects. A database is maintained as a directory. The parameter is mandatory except when the update mode is set to nonpersistent (see below). You cannot start two concurrent servers which use the same database directory. To avoid this case, a file OB.lock is created in the database directory when the first server is started. If the server crashes during its execution, the file OB.lock will still exist in the directory. Before you restart the server, you might have to remove this file manually.

-u updatemode
controls update persistency. The value updatemode is either persistent or
nonpersistent. In non-persistent mode, all updates are lost after the ConceptBase server is stopped. In persistent mode, updates are stored in the files of the database and will be available for future sessions.

-U untellmode
controls the way how UNTELL is executed by the server. The allowed values are verbatim (default) and cleanup. In verbatim mode, the UNTELL operation will only untell the facts directly described by the O-Telos frame being submitted as argument. In cleanup mode, UNTELL will also try to remove the instantiation to the O-Telos system classes. By this, UNTELL behaves inverse to the TELL operation. More details are explained in subsection 3.3.

-p portnr
sets the TCP/IP socket portnumber for client connections to the ConceptBase server. The value portnr must be between 2000 and 65535. If there is already a process using the portnumber, the ConceptBase server will abortgif. The default value for the portnumber is 4001.

-t tracemode
sets the tracemode of the ConceptBase server. It is one of no,low,high,veryhigh. The tracemode determines the amount of text displayed by the server during its execution. The tracemode does not influence the function but is used for debugging.

-c cachemode
turns on the query cache to allow recursive query evaluation. The value cachemode is one of off, transient, and keep (default). In transient mode the cache is emptied before each transaction. In keep mode, the cache is emptied when the maximum number of entries in the cache is exceeded or an update has invalidated the cache. This parameter is controlling the SLDNF evaluation strategy.

-o optmode
controls the optimizer for rules, constraints and queries. The value optmode is one of 0 (no optimization), 1 (structural optimization by exploiting builtin O-Telos axioms), 2 (optimizing join order) or 3 (combines 1 and 2). Default and recommended is 3.

-r secs
automatically restarts the server after a crash. The value secs specifies how many seconds to wait before restart. Crashes are infrequent with the ConceptBase server. Use this option only when you want maximum accessibility of the server. This option is not available on Microsoft Windows.

-gt x11
is a compatibility mode for the old X11 graphbrowser (part of the ConceptBase X11 user interface); if set the CBserver will preload a newly created database with the definitions required by the X11 graphbrowser. Note that existing databases will not be affected by this option! This option is not available on Microsoft Windows.

-s securitylevel
enables or disables the access control mechanism of ConceptBase. The value 0 means that no access control is employed. Any user can ask, tell, untell, retell any object in any module. The value 1 enables access control. First, untelling of objects must happen in the module where the object has been defined. Second, any transaction submitted by a user to the CBserver is checked against the permission rules as defined in section 5.1. By default, access control is disabled. Enable it when you use ConceptBase in a multi-user setting and you want to avoid errorneous interferences between different users.

-e maxerrors
sets the maximum number of errors to be displayed to a ConceptBase client within one transaction. The value -1 (default) means that no restriction is applied. Set to 0 to surpress any errors message and to a positive number to limit the displayed errors messages to that number. A low positive number can speed up the communication between ConceptBase client and server if a lot of error messages are generated.

-cc ccmode
(force concerned class) controls inhowfar ConceptBase applies strict typing of attribution literals (x m y) occuring in the membership constraints of query classes. If the mode is set to strict, attribution literals without a unique concerned classgif shall not be accepted. If the mode is set to off (=default), ConceptBase also accepts queries with unstrictly-typed attribution literals. The strict mode is preferable since it avoids certain semantic errors.

-v vmode
controls whether view maintenance rules are generated (vmode=on) or not (vmode=off). View maintenance rules are used to keep a ConceptBase view up-to-date upon changes to the object base. Default value for vmode is off.

The trace of the ConceptBase server can be saved by redirecting its output, e.g.

<CB_HOME>/bin/CBserver -r 10 -p 4444 -t high -d MYDB >> mylogfile.log

The ConceptBase server can also be started directly from the ConceptBase User Interface (see section 4) and most parameters can be specified interactively. The command line version is recommended when one CBserver serves multiple users or when user interface and server shall run on different machines.

Note that some features like persistency can be disabled depending on your licence. A corresponding message is displayed in the window where you start the ConceptBase server.

A frequent error message during the startup of the ConceptBase server is the following:

### FATAL ERROR:
Application is locked by hostname, PID 1234 
### CBserver aborted
This messsage is printed if there is still a file with the name OB.lock in the database directory (option -d). The OB.lock file should avoid that two servers are using the same database directory. The file may be left over of a previous ConceptBase server if the server was not stopped correctly (e.g. aborted by Ctrl-C or it crashed). If you get this error message, make sure that there is no other server running that uses this directory and then delete the file OB.lock. Then, the ConceptBase server should start correctly.




next up previous contents
Next: The Cache Subsystem Up: ConceptBase V7.0 User Manual Previous: The View Language CBVL

ConceptBase Team