# Backup and restore docker install / migrate from normal install to docker

**URL:** <https://forum.gitea.com/t/backup-and-restore-docker-install-migrate-from-normal-install-to-docker/1006>\
**Category:** Install/Maintain/Configure\
**Created:** [March 14, 2019, 11:22am UTC](https://forum.gitea.com/t/backup-and-restore-docker-install-migrate-from-normal-install-to-docker/1006 "2019-03-14T11:22:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![vitobotta](https://avatars.discourse-cdn.com/v4/letter/v/5f8ce5/32.png) [@vitobotta](https://forum.gitea.com/u/vitobotta)\
**Post date:** [March 14, 2019, 11:22am UTC](https://forum.gitea.com/t/backup-and-restore-docker-install-migrate-from-normal-install-to-docker/1006/1 "2019-03-14T11:22:17Z")

</div>

Hi!

I have installed Gitea a few days ago with the “manual” installation (but automated with Ansible). Everything is working including backups/restores.

However I am trying to migrate to a docker install instead as it seems like it would be easier to upgrade etc (correct?). It would also simplify my Ansible playbook.

So I got Gitea installed with docker in a test vm, but I am having an issue with backup. I run the backup from the host with the following command:

```
/usr/bin/docker exec -w /backup --user git root_gitea_1 sh -c '/app/gitea/gitea dump -c /data/gitea/conf/app.ini'

```

but it fails with

```
2019/03/14 11:20:22 Creating tmp work dir: /tmp/gitea-dump-863994298
2019/03/14 11:20:22 Packing dump files...
2019/03/14 11:20:22 Dumping local repositories.../data/git/repositories
2019/03/14 11:20:22 Dumping database...
2019/03/14 11:20:22 Failed to dump database: Error 1146: Table 'gitea.o_auth2_application' doesn't exist

```

so it complains about a table which in fact doesn’t exist in the database (I checked).

So the first question is, how can I fix this? I can’t rely on an installation without reliable backups/restores of course.

The second question is, how can I migrate existing MySQL data / repositories / etc from the “manual” installation to the docker installation?

Any help will be greatly appreciated!
