PostgreSQL 9.4 failed to start on Manjaro

time to read 1 min | 71 words

After setting up Manjaro on my new working laptop, I installed PostgreSQL 9.4. When I want to start the service by running sudo systemctl start postgresql, postgresql keep failing to start.

Apparently before PostgreSQL can function correctly on Arch Linux based distro, the database cluster must be initialized by the postgres user. Fix this just by running the following command:

sudo -i -u postgres
initdb --locale en_US.UTF-8 -E UTF8 -D '/var/lib/postgres/data'

Related Post:

  1. Feb 11, 2016 Fix GDM Service Can't be Enabled on Arch Linux
  2. Feb 03, 2016 Remove Entry from Known Host
  3. Aug 20, 2015 Installing or Upgrading PostgreSQL 9.4 on Ubuntu 14.04
  4. Jul 29, 2015 Fix Locale Settings Error On Ubuntu Server 14.04
  5. Apr 26, 2015 Installing Varnish with nginx on Ubuntu 14.04
  6. Apr 25, 2015 Disabling Apport Error Reporting on Ubuntu
  7. Jan 24, 2015 MariaDB error failed to start, errno 12