Skip to content

Instantly share code, notes, and snippets.

@jkatz
Created April 4, 2013 16:12
Show Gist options
  • Save jkatz/5311748 to your computer and use it in GitHub Desktop.
Save jkatz/5311748 to your computer and use it in GitHub Desktop.
# only supply or default logfile path when none is given explicitly in
# postgresql.conf
@options = ($pg_ctl, 'start', '-D', $info{'pgdata'});
$logsize = 0;
if ($info{'logfile'}) {
push @options, ('-l', $info{'logfile'});
# remember current size of the log
$logsize = (stat $info{'logfile'})[7];
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment