Here, settings are made for which database Web Port should use for data storage, how often data is written to the database and how long data is stored.
The following settings can be made:
| Setting: | Description: |
| Database type | Indicates the type of database used (Default is SQLite) |
| Connection string | Used when connecting to MSSQL, as well as MySQL databases |
| Low Space Alert | Low Disc Space Alarm Limit |
| Write buffer | Number of seconds when values are buffered in memory between writing to database |
| Standard alarm history | Number of days alarm history is stored in the database |
| Standard trend history | Number of days trend history is stored in the database |
| Stop storing to database | Indicates that Web Port stops storing trend data when the disk space is less than the set number of MB |
Tip!
You can validate the connection to the database by pressing the "Check DB Connection"-button down to the right in the menu. (New function from version 2.23.10 and forward)
A popup appears in the bottom right corner and shows the current status of the connection.
SQLite database
When using an SQLite database, Web Port will create one trend database file per month. The files will be named in the format: trend_YYMM.sqlite
- YY represents the last two digits of the year.
- MM represents the month number.
For example, March 2025 would be named:
trend_2503.sqlite
Information:
If MSSQL or MySQL is used, a database must be created and the connection string created.
The connection string indicates which user to use and to which server and database Web Port should connect.
Example of connection string:
Server=localhost;Port=3306;Database=webport;Uid=user;Pwd=password;
Web Port generates its own tables when connecting to the database, which means that the user must have permissions for this.
Cache settings
Setting for cache type indicates how long after each page load that page settings are kept in system memory. Keeping the page settings in memory speeds up the loading of pages, but also increases the memory usage of the system. Page settings are always reloaded when restarting the system.
The options are:
| Option: | Description: |
| MEMORY | Page settings are not cleared from system memory until the system restarts |
| MIXx | Page settings are cleared from memory after x (1-10) minutes and are requested from the cache database the next time they are needed |