Page 1 of 1

Could not open required defaults file: /etc/mysql/debian.cnf

Posted: Wed Dec 16, 2020 6:29 am
by davorin
Good morning

Had this error message once when upgrading from 1.34.22 to 1.35.16...but could finish the installation with zmupdate.pl...

Now this morning I saw a new update for 1.35.16...and again:

Creating zm db
mysql: [ERROR] Could not open required defaults file: /etc/mysql/debian.cnf
mysql: [ERROR] Fatal error in defaults handling. Program aborted!
Error creating db.

1. Why does ZM needs to create a DB on every update?
2. And why does it refer to a file which doesn't exist on Debian 10.7?


thanks in advance
richard

Re: Could not open required defaults file: /etc/mysql/debian.cnf

Posted: Wed Dec 16, 2020 8:52 am
by Magic919
For a version update there's a .sql file with any changes to the schema. It's not a new database. If you'd already moved to 1.35.16, then it makes no sense.

1.35.x is unstable, so you have to expect some borkage.

Re: Could not open required defaults file: /etc/mysql/debian.cnf

Posted: Wed Dec 16, 2020 9:06 am
by davorin
Well yes..I know uneven numbers are unstable....just wondering who and why it requires debian.cnf....

Anyway...just received this morning a new test system to do a complete fresh install of Debian 10.7 and ZM 1.35and nothing else...

Re: Could not open required defaults file: /etc/mysql/debian.cnf

Posted: Wed Dec 16, 2020 9:45 am
by Magic919
If you are interested, take a look through the source and you can see plenty of instances where it works on the DB and references that file. Like this -

Code: Select all

sudo mysql --defaults-file=/etc/mysql/debian.cnf
The postinst script seems to be behind this error.