PostgreSQL error: could not connect to database template1: could not connect to server: No such file or directory

The error means that the Postgres server is not running. Try starting it: sudo systemctl start postgresql I believe the service name is postgresql, but if that doesn’t work, try typing sudo systemctl start postgres and pressing tab to auto-complete. Make sure that the server starts on boot: sudo systemctl enable postgresql

Text compression in PostgreSQL

Compression is enabled by default for all string types, you don’t have to tell the database to do it. Check the manual about TOAST PLAIN prevents either compression or out-of-line storage; furthermore it disables use of single-byte headers for varlena types. This is the only possible strategy for columns of non-TOAST-able data types. EXTENDED allows … Read more

Rails 3.1 – Pushing to Heroku – Errors installing postgres adapter?

Option 1: Add pg to your Gemfile but skip trying to install it locally. $ cat Gemfile … group :production do # gems specifically for Heroku go here gem “pg” end # Skip attempting to install the pg gem $ bundle install –without production Option 2 (Debian/Ubuntu): Add pg to your Gemfile but first install … Read more