Backup issue for Gitea

#1

Not able to take backup of Gitea.
getting error “Failed to connect to database: Unknown database type:”
Anyone have idea how to resolve this issue.

0 Likes

#2

I back it up manually: by making copy of all its files and making pg db backup by pg_dump.

0 Likes

#3

Think you could add a little color with regard to which files you back-up? I’m thinking probably the folder containing the git repos as well as the config, in addition to a db dump (in your case via Postgre).

0 Likes

#4

I am using SQLite DB

0 Likes

#5

1.dump db (I use postgresql, so pg_dump)
2.copy git repos
3.copy /var/lib/gitea

2 Likes

#6

@elfuego Thanks for the step, for the step 3 where is /var/lib/gitea in Windows machine?

0 Likes

#7

@vbose1 Have you tried full path on your command like gitea dump -c C:/Gitea/gitea/custom/data/to?

I had the same error, but I solved by just typing gitea dump (my app.ini in the default directory).

0 Likes

#8

Have no idea, but this is custom data path.

0 Likes

#9

not working getting same error
Failed to connect to database: Unknown database type:

0 Likes

#10

Then, have you tried elfuego’s suggestion?

  1. Dump database by gitea dump db /custom/data/to/app.ini
  2. Copy git repositories
  3. Copy /var/lib/gitea (I am not sure where is in Windows by the way)

For my Windows machine, the step 1 and 2 looks like working as same as gitea dump.

0 Likes