diff -ur zabbix-5.0.7.orig/conf/zabbix_proxy.conf zabbix-5.0.7/conf/zabbix_proxy.conf --- zabbix-5.0.7.orig/conf/zabbix_proxy.conf 2021-01-03 20:22:59.543798240 +0100 +++ zabbix-5.0.7/conf/zabbix_proxy.conf 2021-01-03 20:28:36.745798240 +0100 @@ -158,6 +158,7 @@ ### Option: DBName # Database name. # For SQLite3 path to database file must be provided. DBUser and DBPassword are ignored. +# If provided name does not contain '/' or ':' (no a path or special type) a .db file in /var/lib/zabbix will be used. # Warning: do not attempt to use the same database Zabbix server is using. # # Mandatory: yes diff -ur zabbix-5.0.7.orig/src/libs/zbxdb/db.c zabbix-5.0.7/src/libs/zbxdb/db.c --- zabbix-5.0.7.orig/src/libs/zbxdb/db.c 2020-12-14 11:27:17.000000000 +0100 +++ zabbix-5.0.7/src/libs/zbxdb/db.c 2021-01-03 20:30:32.174798240 +0100 @@ -383,6 +383,7 @@ unsigned int i = 0; #elif defined(HAVE_SQLITE3) char *p, *path = NULL; + char dbname_buf[1024]; #endif #ifndef HAVE_MYSQL @@ -830,6 +831,10 @@ ZBX_UNUSED(ca); ZBX_UNUSED(cipher); ZBX_UNUSED(cipher_13); + if (!strchr(dbname, '/') && !strchr(dbname, ':')) { + zbx_snprintf(dbname_buf, sizeof(dbname_buf), "/var/lib/zabbix/%s.db", dbname); + dbname = dbname_buf; + } #ifdef HAVE_FUNCTION_SQLITE3_OPEN_V2 if (SQLITE_OK != sqlite3_open_v2(dbname, &conn, SQLITE_OPEN_READWRITE, NULL)) #else