Hi,
I'm trying to run some queries on the eximstats database. I've tried a number of things as follows:
I have a development environment running on a Windows PC where I do my development work.
After reviewing a large number of posts and websites relating to my issue I have been very aware of the following posts and procedures:
github.com/AstralInternet/query_cpanel_eximstats_sqlite
Excellent script to query the database using perl.
stackoverflow.com/questions/44499844/cant-access-eximstats-sqlite3-db-after-whm64-upgrade
Stack overflow post regarding querying the eximstats database
API call to get a json equivalent of View Sent Summary
In my development environment I've taken a copy of the eximstats database from my live server (/var/cpanel/eximstats_db.sqlite3).
I've then created php scripts which have successfully queried this eximstats database. These php scripts used a variety of methods: calling a perl script, using PDO & using SQLite 3.
All of these scripts have been able to connect to the database I downloaded without any issue in my development environment.
All of these scripts have failed when I have ran them on my production server (they were ran as root).
They fail when querying the database directly (/var/cpanel/eximstats_db.sqlite3).
They fail when querying a copy of the database that has had its permissions changed to 0777.
The error message is always the same: 'file is encrypted or is not a database'.
I've tried numerous other things that may provide some insight.
If I open a copy of the database in DB Browser for SQLite and change the Journal Mode from 'WAL' to 'Off' and then upload this database to my production server, all of the scripts work.
I've read numerous posts about version differences but am not sure if this is the issue. Below are the sqlite version issue information I obtained from my production server:
cpanel-sqlite-3.22.0-1.cp1162.x86_64
ea-php56-php-pdo-5.6.40-2.2.4.cpanel.x86_64
sqlite-3.6.20-1.el6_7.2.x86_64
ea-php55-php-pdo-5.5.38-40.40.4.cpanel.x86_64
ea-php70-php-pdo-7.0.33-2.2.4.cpanel.x86_64
After numerous days trying numerous things I am now at a complete loss!!
Is anyone able to provide any further guidance that may assist me?
Thanks in advance,
Paddy
I'm trying to run some queries on the eximstats database. I've tried a number of things as follows:
I have a development environment running on a Windows PC where I do my development work.
After reviewing a large number of posts and websites relating to my issue I have been very aware of the following posts and procedures:
github.com/AstralInternet/query_cpanel_eximstats_sqlite
Excellent script to query the database using perl.
stackoverflow.com/questions/44499844/cant-access-eximstats-sqlite3-db-after-whm64-upgrade
Stack overflow post regarding querying the eximstats database
API call to get a json equivalent of View Sent Summary
In my development environment I've taken a copy of the eximstats database from my live server (/var/cpanel/eximstats_db.sqlite3).
I've then created php scripts which have successfully queried this eximstats database. These php scripts used a variety of methods: calling a perl script, using PDO & using SQLite 3.
All of these scripts have been able to connect to the database I downloaded without any issue in my development environment.
All of these scripts have failed when I have ran them on my production server (they were ran as root).
They fail when querying the database directly (/var/cpanel/eximstats_db.sqlite3).
They fail when querying a copy of the database that has had its permissions changed to 0777.
The error message is always the same: 'file is encrypted or is not a database'.
I've tried numerous other things that may provide some insight.
If I open a copy of the database in DB Browser for SQLite and change the Journal Mode from 'WAL' to 'Off' and then upload this database to my production server, all of the scripts work.
I've read numerous posts about version differences but am not sure if this is the issue. Below are the sqlite version issue information I obtained from my production server:
cpanel-sqlite-3.22.0-1.cp1162.x86_64
ea-php56-php-pdo-5.6.40-2.2.4.cpanel.x86_64
sqlite-3.6.20-1.el6_7.2.x86_64
ea-php55-php-pdo-5.5.38-40.40.4.cpanel.x86_64
ea-php70-php-pdo-7.0.33-2.2.4.cpanel.x86_64
After numerous days trying numerous things I am now at a complete loss!!
Is anyone able to provide any further guidance that may assist me?
Thanks in advance,
Paddy
Last edited by a moderator: