Remove postgresql log files

This commit is contained in:
Bob Mottram 2018-04-19 11:28:11 +01:00
parent be74c3040a
commit f2654245aa
1 changed files with 3 additions and 0 deletions

View File

@ -96,6 +96,9 @@ function turn_off_postgresql_logging {
fi
sed -i 's|#log_destination|log_destination|g' /etc/postgresql/9.6/main/postgresql.conf
sed -i "s|log_destination.*|log_destination = 'syslog'|g" /etc/postgresql/9.6/main/postgresql.conf
if [ -d /var/log/postgresql ]; then
$REMOVE_FILES_COMMAND /var/log/postgresql/*
fi
}
function turn_on_postgresql_logging {