Fix bugs in pg_restore phase
Merge branch 'master' into for_puppet