Installing and Configuring MySQL 8 Database (Windows)
Installing MySQL is not required for Test Node instances. Only the AIQ controller needs a results database.
AIQ stores results in a MySQL 8 database. There are two supported ways to provide it: a local MySQL server on the Windows controller host, which is what this page covers, or Amazon RDS for MySQL, which is the recommended shape for production — see MySQL 8.x Database on AWS RDS (8.0 and 8.4).
Server requirements
MySQL 8 needs more resources than MySQL 5.7 did, so size the host for the database and not only for the controller. Do not use MySQL 8.1 — it contains changes AIQ does not support. Use 8.4 LTS for new installations; 8.0.x remains supported.
| Minimum | Recommended (performance and load testing) | |
|---|---|---|
| vCPU | 4 | 8 |
| Memory (GB) | 16 | 32 |
| Network performance (Gbps) | 1 | Up to 5 |
Performance and load testing need the larger shape because report generation runs its heavy work inside the stored procedures, on the database host.
Recommended MySQL parameters
Set these values in my.ini on the controller host and restart the MySQL service. On a self-hosted server you set the memory values directly instead of using the RDS formulas.
MyISAM matters more than InnoDB here. AIQ keeps its report tables on MyISAM, so key_buffer_size is what keeps report queries off the disk. Production indexes total roughly 757 MB.
| Parameter | Suggested value | Notes |
|---|---|---|
| key_buffer_size | 2147483648 | 2 GB — MyISAM index cache |
| myisam_use_mmap | 1 | Memory-maps the data files |
| myisam_sort_buffer_size | 268435456 | 256 MB for bulk inserts and repairs |
| myisam_max_sort_file_size | 2147483648 | 2 GB maximum sort file |
| tmp_table_size | 2147483648 | 2 GB — report temp tables stay in memory |
| max_heap_table_size | 2147483648 | Must match tmp_table_size |
| innodb_buffer_pool_size | 4294967296 | 4 GB, or 30 % of host memory |
| innodb_log_buffer_size | 134217728 | 1 % of host memory |
| innodb_flush_log_at_trx_commit | 2 | Faster commits, small durability trade-off |
| innodb_io_capacity / _max | 2000 / 4000 | SSD storage |
| max_connections | 500 | Global connection ceiling on a dedicated host |
| max_user_connections | 200 | Per-user ceiling |
| wait_timeout / interactive_timeout | 1080 | Sleeping connections accumulate otherwise (AIQ-6619) |
| connect_timeout | 10 | Handshake timeout |
| max_allowed_packet | 1073741824 | 1 GB — large result sets and BLOBs |
| bulk_insert_buffer_size | 536870912 | 512 MB for heavy transactional load |
| read_buffer_size | 2097152 | 2 MB per sequential MyISAM scan |
| read_rnd_buffer_size | 2097152 | 2 MB for sorted reads |
| sort_buffer_size | 8388608 | 8 MB per sorting thread |
| join_buffer_size | 4194304 | 4 MB per join without an index |
| table_open_cache | 4000 | Open table descriptors |
| table_definition_cache | 2000 | Cached table definitions |
| thread_cache_size | 100 | Threads kept for reuse |
| log_bin_trust_function_creators | 1 | Required — the schema scripts create stored procedures |
| validate_password | OFF | Leave ON if policy requires it, then match it in every password |
| slow_query_log / long_query_time | 1 / 5 | Optional — queries slower than 5 seconds |
No query cache. MySQL 8 removed query_cache_size and query_cache_type. If you are porting a 5.7 my.ini, delete those lines or the service will not start.
Install the database and schema
- Install MySQL 8.4 (or 8.0.x) server on the controller host, using a service account that survives reboots.
- Stop the service, set the parameters above in my.ini, and start it again.
- Connect as root and run MySQLInitial.sql — it creates the schema and the aiq database user.
- Run MySQLAppvance.sql as that aiq user — it creates the AIQ tables and stored procedures.
- Reconnect and confirm the values took effect with the verification queries below.
Both scripts work unchanged on 8.0 and 8.4.
Where the schema scripts are
You do not need to request these files — they ship inside the AIQ distribution. The two scripts live in the database folder of the TestNode web application:
| Platform | Path |
|---|---|
| Windows | <AIQ>\TestNode\webapps\AppvanceServer\WEB-INF\classes\database |
| Linux / macOS | <AIQ>/TestNode/webapps/AppvanceServer/WEB-INF/classes/database |
<AIQ> is the aiq_distribution folder of the package you installed — on Windows that is normally C:\AIQ\aiq_distribution, so the full path is C:\AIQ\aiq_distribution\TestNode\webapps\AppvanceServer\WEB-INF\classes\database. Both MySQLInitial.sql and MySQLAppvance.sql are in that folder.
Software downloads (official MySQL site):
- MySQL Community Server 8.4 — dev.mysql.com/downloads/mysql
- MySQL 8.0 or any earlier build — downloads.mysql.com/archives/community
- MySQL Workbench, if you prefer a GUI to the command line — dev.mysql.com/downloads/workbench
- Step-by-step using MySQL Workbench (connection, open script, execute) — Install Appvance IQ Database Schema
mysql -u root -p
SOURCE /path/to/MySQLInitial.sql;
SOURCE /path/to/MySQLAppvance.sql;
Verify before you continue
SELECT VERSION();
SHOW TABLES;
SHOW PROCEDURE STATUS WHERE Db = 'aiq';
SHOW VARIABLES LIKE 'max_allowed_packet';
SHOW VARIABLES LIKE 'wait_timeout';
max_allowed_packet must read 1073741824 and wait_timeout must read 1080. If either shows a default value, the parameter file was not picked up — check that you edited the my.ini the service actually reads, then restart it.
When you are done
Continue with Running AIQ on Windows as a Service. If you are deploying the database on AWS instead of locally, use MySQL 8.x Database on AWS RDS (8.0 and 8.4) — the parameter group, instance sizing and troubleshooting there replace the my.ini section of this page.
Last updated November 2026. Applies to MySQL 8.0.x and 8.4.x on Windows.