mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-07-11 19:04:31 +02:00
Updated Backup & Restore Data (markdown)
parent
cd85d4b072
commit
2748cddf53
1 changed files with 17 additions and 0 deletions
|
@ -19,3 +19,20 @@ If you are using sqlite, it is sufficient to just copy your `app.db` from your d
|
|||
#### MySQL / MariaDB
|
||||
For MySQL / MariaDB you have to dump the database to an SQL file. You can do this manually with phpmyadmin, or you use [`mysqldump`](https://mariadb.com/kb/en/mariadb-dumpmysqldump/) to dump the database to an SQL file via command line interface (`mysqldump -uBACKUP -pPASSWORD DATABASE`)
|
||||
|
||||
## Restore
|
||||
Install Part-DB as usual as described in the installation section, with the exception of the database creation / migration part. You have to use the same database type (sqlite or mysql) as on the back-uped server instance.
|
||||
|
||||
### Restore configuration
|
||||
Copy configuration files `.env.local`, (and if existing) `config/parameters.yaml` and `config/banner.md` from the backup to your new Part-DB instance and overwrite the existing files there.
|
||||
|
||||
### Restore attachment files
|
||||
Copy the `uploads/` and the `public/media/` folder from your backup into your new Part-DB folder.
|
||||
|
||||
### Restore database
|
||||
#### Sqlite
|
||||
Copy the backup-ed `app.db` into the database folder normally `var/app.db` in Part-DB root folder.
|
||||
|
||||
#### MySQL / MariaDB
|
||||
Recreate a database and user with the same credentials as before (or update the database credentials in the `.env.local` file).
|
||||
Import the dumped SQL file from the backup into your new database.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue