#!/bin/bash cd /tmp DIR=/backup_share [ ! $DIR ] && mkdir -p $DIR || : tar -iczf $DIR/`date +%u`.config.tar.gz `cat /opt/backup/backup_list` sudo -u postgres /usr/bin/pg_dump -b --disable-triggers --inserts --exclude-table-data='*.history*' --exclude-table-data='*.trends*' --exclude-table-data='*.event*' --exclude-table- data='*.escalations*' --exclude-table-data='*.auditlog*' --exclude-table-data='*.alerts*' zabbix | gzip > $DIR/`date +%u`.zabbix.data.gz