Hi team, Good day! Can I know how I can backup Dat...
# all-things-deployment
f
Hi team, Good day! Can I know how I can backup Datahub deployed on Kubernetes and then restore it in a fresh instance?
✅ 1
l
Hey there 👋 I'm The DataHub Community Support bot. I'm here to help make sure the community can best support you with your request. Let's double check a few things first: 1️⃣ There's a lot of good information on our docs site: www.datahubproject.io/docs, Have you searched there for a solution? 2️⃣ It's not uncommon that someone has run into your exact problem before in the community. Have you searched Slack for similar issues?
b
You can use mysqldump like this to do so: https://medium.com/@madushagunasekara/export-mysql-db-dump-from-kubernetes-pod-and-restore-mysql-db-on-kubernetes-pod-6f4ecc6b5a64 Don't forget than once you restored the DB on another instance you need to execute the restore indices job: https://datahubproject.io/docs/how/restore-indices#kubernetes Ps: it takes some times even after the restore indices is done for everything to be fully back (I am speaking about glossary terms, graphs, ...) so make so you don't touch the app (more than just looking the home page) before everything is back
f
I have a copy of my MySQL instance as another pod
So making a new datahub instance, i can use this DB and then create a restore indices job and restore the graph indices as well yeah?
b
Probably you may just need to modifie your deployments env variables to make your new Datahub instance use this specific mysql pod. But I think you may still need the restore indices job at some point.
f
Yes got it!
Hi @blue-honey-61652. Apart from creating a restore-indices-job, is having the mysql DB backup enough? As in, do I need to backup elasticsearch manually as well or is that done by the restore-indices-job?
b
Hi, elasticsearch is populated by the restore-indices-job, it is not advised to backup elasticsearch manually because the restore-indices-job restore it in a safer way