OOM Backup and Restore
On local minikube, the following configuration works:
But trying to replicate the configuration to the actual cronjob on oom it's been unsuccessful.
The issue seems to be the mapping of paths from containers to hostPath.
The most common issue seems to be that backup container (mariadb-galera-backup-init) is unable to start the backup and create the folders, then the validation container (mariadb-backup-validate) fails as paths used are not created.
root@xerces-master-policy-03-nfs:~# kubectl logs dev-policy-mariadb-backup-1639580400-dlqpl
cat: /backup/backup.log: No such file or directory
ls: cannot access '/backup/backup-*': No such file or directory
cp: cannot create directory '/bitnami/mariadb/data/backup': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/bin': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/bitnami': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/boot': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/dev': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/docker-entrypoint-initdb.d': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/etc': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/home': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/lib': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/lib64': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/media': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/mnt': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/opt': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/proc': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/root': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/run': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/sbin': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/srv': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/sys': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/tmp': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/usr': Read-only file system
cp: cannot create directory '/bitnami/mariadb/data/var': Read-only file system
Validation Failed!!!