That's... not an option I gave you

> mariadb-dump --all-databases --add-drop-database
mariadb-dump: unknown option '--log_bin'

…huh?

Yeah… random!

Could that option be coming from a config file?

As far as I’m aware, the MariaDB client tools read the usual option files (e.g. /etc/my.cnf, /etc/mysql/my.cnf, or ~/.my.cnf), and if log_bin is defined somewhere it shouldn’t be, that could explain why mariadb-dump thinks it was passed as an option.

Bit of a long shot, but it might be worth checking.

log_bin is defined in my.ini, but it’s supposed to be. I think.
The problem i run into with that is that every source I read has a different section of the ini it’s supposed to be in.

Activating the Binary Log | Server | MariaDB Documentation
says it goes in [client-server].
Setting Up Replication | Server | MariaDB Documentation
says it goes in [mariadb], or [mysqld] if you’re doing mysql replication…(and then immediately above where it says that, it links to the first link, which says to put it somewhere else???)

I think log_bin is a server setting, as it controls the binary log used for replication, which only the server process cares about. Client tools like mariadb-dump don’t use it at all.

Because of that, it likely belongs under a server-only section such as [mysqld] or [mariadb]. Putting it under [client-server] would mean client programs read it too, which may well be what’s triggering the “unknown option” message.

That error usually happens when the MariaDB client version doesn’t match the server version.

I’ve run into this when using an older mariadb-dump against a newer server with binary logging enabled. Try checking your dump version first:

mariadb-dump --version

If it’s older, updating the client tools fixes it. As a quick workaround, you can also use mysqldump instead, which tends to be more compatible across versions.

Well its the bin in the server folder, so… its going to match.

have switched to mariadb-backup, which seems to be able to work, but will continue to investigate and try changing the my.ini file more.

Ah got it, that makes sense.

If mariadb-backup is working, that’s a good sign the server side is fine. I’ve seen mariadb-dump throw odd option errors before when the binary is present but built with slightly different defaults or configs.

Checking the my.cnf and especially anything related to binlog settings is the right direction. Glad you found a working path — mariadb-backup is usually more reliable for full backups anyway :+1:

Google Gemini AI says the likely cause is that there is a deprecated or misplaced option. If you want to see more of what it says then look at https://gemini.google.com/share/9fd6613eb79c.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.