that is overriding the pid file and socket that MySQL is looking for
No I had the /var/lib/mysql/mysql.sock in there under the mysqld section which was also to be seen in the running string from mysql in the log, and socket=/usr/local/mysql/data/mysql.sock under the client section which is put there by default.
Also removing the /var/lib/mysql/mysql.sock and restarting or rebooting did not change anything either.
Reinstalling the second time and leaving out the mysqld line to mysql.sock did not help either.
I have only 1 single my.cnf not even a my.cnf.d directory (as on Centos and Alma). As said, I didn't change anyhting, just re-installed for the 3rd time and bang... suddenly working, used the same my.cnf too.
So yes it's strange indeed. I said it was spooky.
Thank you for pointing to the other options and the shell scripts. But if possible I try to use everything as default as possible, just to prevent issues.
And it still doesn't explain the other odd things which were happening before and solved suddenly was automatically fixed.
I'm under the impression that there is or might be some disk writing issue or something. Reinstalling mariadb is new disk writing. Going back and forth to DA 1.651 and back to 1.652 (fixed spf issue) is new disk writing. Restoring backups, deleting backups and restoring again (several times, fixed the dns issue) is also disk writing.
So to me this is the only thing which can explain all these odd things happening together without me changing anything myself.
I don't know if I can check the filesystem on a VPS somehow, without having to unmount stuff. Got customers on there now.