0

I observed that the dump of my DB done "by hand" in the CLI is a lot bigger (>800MB) than the one produced by the Workbench (v8.0) (<500MB) and I am trying to figure out why that's the case.

The Workbench shows in parts what it does:

Running: mysqldump.exe --defaults-file="C:\Users\WOLF\AppData\Local\Temp\tmp4hx8j0cs.cnf" --host=localhost --port=3306 --default-character-set=utf8 --user=root --protocol=tcp --skip-triggers "psynet"

I guess the magic is in the defaults-file but unfortunately this seems to be temporary created and eliminated automatically. [EDIT]: it doesn't...it only contains the temporary password.

My command looks like this:

mysqldump -e -uroot -p --skip-triggers --default-character-set=utf8 psynet > 'C:\Users\WOLF\psynet_testdump.sql'

I'd appreciate input on how I can crunch this down further as I might have to upload this repeatedly in the future.

2
  • Did you try --compact parameter? Apr 29, 2022 at 14:14
  • Unfortunately no significant impact. By now I am very sure that the workbench does more stuff under the hood that it doesnt show in the interface. I mean...the command it shows would pretty much just write to the CLI if executed like this. And the magic of compression doesn't lie within the shown parameters. So I guess there is more of a pipeline behind it.
    – Wolfone
    Apr 29, 2022 at 14:19

1 Answer 1

0
  • Look in the first hundred lines of each. Do you see significant differences?

  • Are INSERTs 'batched'? That is one row per Insert statement versus lots of rows.

  • Next time you run the Workbench dump have an other cmd running so you can (hopefully) capture the cnf file.

  • For compressing after the fact, use WinZip / 7zip / etc to shrink the output file by a factor of about 3. (And reverse the action when you need to read the dump.)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.