Possebility of corrupted mysqldump when using docker
TheOneRing opened this issue · 0 comments
TheOneRing commented
WHAT Needs to be Documented?
When following the instructions to create a mysqldump with docker
docker-compose exec mariadb \
/usr/bin/mysqldump -u root --password=owncloud \
owncloud > owncloud_$(date +%Y%m%d).sql
The process appears to be stuck and when it eventually finishes the dump is corrupted,
namely only the table definitions made it to the dump, not the data.
Adding -T
to the exec however solves that issue
docker-compose exec -T mariadb \
/usr/bin/mysqldump -u root --password=owncloud \
owncloud > owncloud_$(date +%Y%m%d).sql
https://docs.docker.com/compose/reference/exec/
Dumping in a non interactive shell works without a problem.
WHERE Does This Need To Be Documented (Link)?
https://doc.owncloud.com/server/next/admin_manual/installation/docker/
WHY Should This Change Be Made?
Working backups are kind of important
(Optional) What Type Of Content Change Is This?
- New Content Addition
- Old Content Deprecation
- Existing Content Simplification
- Bug Fix to Existing Content
(Optional) Which Manual Does This Relate To?
- Admin Manual
- Developer Manual
- User Manual
- Android
- iOS
- Branded Clients
- Desktop Client
- Other