Simple tip: faster database backup for Postgres

For millions of records: 1MM+ per minute, depending on your computer.

Dump:

PGPASSWORD=your_password pg_dump -U your_username -h your.host.example.com your_database_name | gzip > dump.sql.gz

Restore:

PGPASSWORD=your_password gzip -d < dump.sql.gz | psql -U your_username -d your_database