dokku/dokku-mongo

mongo:import returns Failed: gzip: invalid header

fmendoza opened this issue · 5 comments

I executed the export command in one of my servers following the docs like this:

dokku mongo:export lolipop > lolipop.dump.gz

And when I tried to import it in my other server running dokku as well:

dokku mongo:import lolipop < database.dump.gz

I received this error message Failed: gzip: invalid header

Is dokku mongo:export lolipop erroring somewhere? Run it without piping output elsewhere.

I suspect that my old server have a old version of this plugin without gzip compression in mongo:export command.

That was it. You can close this issue.

For anyone reading this in the future:

dokku plugins:update mongo
dokku mongo:upgrade <service> # <---- !!! will create downtime !!!
dokku mongo:export <service>

Upgrade isn't strictly necessary if both mongo installs are the same version.