Qual é a sua dúvida?
Postgres Commands
Backup
pg_dump -h HOST -U postgres -W -Ft DATABASE > FILE
Restore
pg_restore -h HOST -U postgres -d DATABASE -W FILE
Inserindo functions no ~/.bashrc
$ nano ~/.bashrc
$ backup() { pg_dump -h $1 -U postgres -W -Ft $2 > $3; }
$ restore() { pg_restore -h $1 -U postgres -d $2 -W $3; }
Executando o Comando
$ backup 127.0.0.1 wordpress wordpress.tar