Skip to content

alclouds/PostgresqlBackup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Postgresql Backup Script

这两个脚本取自 https://wiki.postgresql.org/wiki/Automated_Backup_on_Linux, 所有版权属于那个网站.

使用方法

  1. 下载并解开, 改一下pg_backup.conf 里面的设定.
curl -sSL https://github.com/hkKimWu/PostgresqlBackup/raw/master/install.sh | sh -s

vi pg_backup.conf
  1. 在 /var/lib/pgsql/data/pg_hba.conf 里面加一行 "host   all         postgres   127.0.0.1/32         trust".
# TYPE  DATABASE    USER        CIDR-ADDRESS          METHOD

# "local" is for Unix domain socket connections only
local   all         all                               ident
# IPv4 local connections:
host    all         postgres    127.0.0.1/32          trust
host    all         all         127.0.0.1/32          ident
# IPv6 local connections:
host    all         all         ::1/128               ident
  1. 运行测试:
./pg_backup.sh

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages