Closed geocoug closed 2 years ago
May also want to consider archiving with Block Storage Volumes.
Added postgis-backup service here:
with these commits:
Next steps:
/share/postgis-backups
/share/postgis-backups
Hi @geocoug,
Ok, I ran git pull
and docker-compose up -d
to get the latest:
bbest@mhk-data-ubuntu:~/mhkenvserversoftware$ git pull
remote: Enumerating objects: 8, done.
remote: Counting objects: 100% (8/8), done.
remote: Compressing objects: 100% (6/6), done.
remote: Total 6 (delta 4), reused 0 (delta 0), pack-reused 0
Unpacking objects: 100% (6/6), done.
From https://github.com/marineenergy/server
8c1c7cd..c06d378 master -> origin/master
Updating 8c1c7cd..c06d378
Fast-forward
docker-compose.yml | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
bbest@mhk-data-ubuntu:~/mhkenvserversoftware$ docker-compose up -d
nginx-dev is up-to-date
nginx is up-to-date
rstudio is up-to-date
postgis is up-to-date
proxy is up-to-date
Recreating postgis-backup ...
letsencrypt is up-to-date
Recreating postgis-backup ... done
Hopefully we'll see the backup there tomorrow in /mnt/backups
:
bbest@mhk-data-ubuntu:~$ df -h
Filesystem Size Used Avail Use% Mounted on
udev 3.9G 0 3.9G 0% /dev
tmpfs 798M 1.2M 797M 1% /run
/dev/vda1 155G 38G 118G 25% /
tmpfs 3.9G 0 3.9G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 3.9G 0 3.9G 0% /sys/fs/cgroup
/dev/vda15 105M 8.9M 96M 9% /boot/efi
/dev/sda 496G 226G 246G 48% /share
tmpfs 798M 0 798M 0% /run/user/1000
/dev/sdb 100G 61M 95G 1% /mnt/backups
So @geocoug fixed with:
Ah good eye Caleb. Yes, the database container was not properly referenced so your db to postgis fix should do it. I just updated server:
cd mhkenvserversoftware/
git pull
docker-compose up -d
If it still has trouble producing backups overnight, I'll inspect the server logs with:
docker logs postgis-backup
Thanks a bunch, Ben
Woohoo @geocoug,
The postgis backups are working:
bbest@mhk-data-ubuntu:/mnt/backups/pg_backups$ tree
.
├── 2022
│ └── May
│ ├── PG_gis_gis.20-May-2022.dmp
│ ├── PG_gis_gis.21-May-2022.dmp
│ ├── PG_gis_gis.22-May-2022.dmp
│ └── PG_gis_gis.23-May-2022.dmp
└── globals.sql
2 directories, 5 files
bbest@mhk-data-ubuntu:/mnt/backups/pg_backups$ ls -lh 2022/May/
total 6.8G
-rw-r--r-- 1 root root 1.7G May 20 23:05 PG_gis_gis.20-May-2022.dmp
-rw-r--r-- 1 root root 1.7G May 21 23:04 PG_gis_gis.21-May-2022.dmp
-rw-r--r-- 1 root root 1.7G May 22 23:04 PG_gis_gis.22-May-2022.dmp
-rw-r--r-- 1 root root 1.7G May 23 23:05 PG_gis_gis.23-May-2022.dmp
Schedule nightly DB backups pushed to remote (Integral) server.