New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Warn users when running H2 as the application database #8467

Open
senior opened this Issue Sep 5, 2018 · 3 comments

Comments

Projects
None yet
4 participants
@senior
Member

senior commented Sep 5, 2018

H2 is a great way to get up and running quickly with Metabase and try it out, but it has its downsides. First, if users have the defaults (very likely for H2 users) and something like Docker, they will likely have their application database destroyed with the upgrade or remove their current container. For users that have setup an alternate location for their H2 DB file, there are still drawbacks to H2. The database is slower than PostgreSQL/MySQL, occasionally has corruption issues and also doesn't have backup tools like PostgreSQL and MySQL.

For production installs of Metabase, we should encourage users to setup MySQL or PostgreSQL. We should probably put a warning in the log on startup (especially calling out the case where it's H2 with the default file location) and maybe also include some red text in the admin console for this scenario.

@tlrobinson

This comment has been minimized.

Member

tlrobinson commented Sep 6, 2018

I agree, but regarding

something like Docker, they will likely have their application database destroyed with the upgrade or remove their current container

I think we could have the Dockerfile declare a volume which is automatically persisted?

https://docs.docker.com/engine/reference/builder/#volume

@stremlau

This comment has been minimized.

stremlau commented Oct 29, 2018

You should add a warning on the Getting Started -> Docker page (https://www.metabase.com/start/docker.html) that you should not use it in production, because the data will not be persistent.

I followed the detailed instructions on https://www.metabase.com/docs/v0.30.4/operations-guide/running-metabase-on-docker.html under "Mounting a mapped file storage volume". And forgot to set the environment variable because it was not mentioned in the text. It would be good to add it, so that future users have no problems.

@jornh

This comment has been minimized.

Contributor

jornh commented Oct 31, 2018

@stremlau it’s mentioned on the page linked to in the bottom of the one you pointed to above (but yes probably worth putting even more front & center).

See my comment here:
http://discourse.metabase.com/t/i-hosed-my-docker-container-any-pointers-to-restore-from-time-machine/4727/4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment