title: Why PostgreSQL 12 database server don't active
body: <p>I want use postgresql but show error so checking status. it's failed.</p>
  
  <p>once I deleted postmaster but same error happen.</p>
  
  <p>This server is worked before [<em>yum install --enablerepo=remi-php72 php-pdo php-pgsql</em>] and some operation but i don't know this is reason or not.</p>
  
  <pre><code>$sudo systemctl start postgresql-12.service
  
   Job for postgresql-12.service failed because the control process exited with error code. See "systemctl status postgresql-12.service" and "journalctl -xe" for details.
  </code></pre>
  
  <pre><code>$systemctl status postgresql-12.service
  
  ● postgresql-12.service - PostgreSQL 12 database server
     Loaded: loaded (/usr/lib/systemd/system/postgresql-12.service; enabled; ver preset: disabled)
     Active: failed (Result: exit-code) since Sun 2020-05-10 05:17:14 UTC; 40s
       Docs: https://www.postgresql.org/docs/12/static/
    Process: 708 ExecStart=/usr/pgsql-12/bin/postmaster -D ${PGDATA} (code=exit status=1/FAILURE)
    Process: 699 ExecStartPre=/usr/pgsql-12/bin/postgresql-12-check-db-dir ${PGA} (code=exited, status=0/SUCCESS)
   Main PID: 708 (code=exited, status=1/FAILURE)
  </code></pre>
  
  <pre><code>-- Unit postgresql-12.service has begun starting up.
  May 10 06:30:15 localhost.localdomain postmaster[3481]: 2020-05-10 06:30:15.915 UTC [3481] LOG:  starting PostgreSQL 12.2 on x86_64-pc-linux-gnu, compiled by
  May 10 06:30:15 localhost.localdomain postmaster[3481]: 2020-05-10 06:30:15.922 UTC [3481] LOG:  listening on IPv6 address "::1", port 5432
  May 10 06:30:15 localhost.localdomain postmaster[3481]: 2020-05-10 06:30:15.922 UTC [3481] LOG:  listening on IPv4 address "127.0.0.1", port 5432
  May 10 06:30:15 localhost.localdomain postmaster[3481]: 2020-05-10 06:30:15.925 UTC [3481] LOG:  listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
  May 10 06:30:15 localhost.localdomain postmaster[3481]: 2020-05-10 06:30:15.929 UTC [3481] LOG:  listening on Unix socket "/tmp/.s.PGSQL.5432"
  May 10 06:30:16 localhost.localdomain postmaster[3481]: 2020-05-10 06:30:16.000 UTC [3481] LOG:  redirecting log output to logging collector process
  May 10 06:30:16 localhost.localdomain postmaster[3481]: 2020-05-10 06:30:16.000 UTC [3481] HINT:  Future log output will appear in directory "log".
  May 10 06:30:16 localhost.localdomain systemd[1]: postgresql-12.service: main process exited, code=exited, status=1/FAILURE
  May 10 06:30:16 localhost.localdomain systemd[1]: Failed to start PostgreSQL 12 database server.
  -- Subject: Unit postgresql-12.service has failed
  -- Defined-By: systemd
  -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
  --
  -- Unit postgresql-12.service has failed.
  --
  -- The result is failed.
  May 10 06:30:16 localhost.localdomain systemd[1]: Unit postgresql-12.service entered failed state.
  May 10 06:30:16 localhost.localdomain systemd[1]: postgresql-12.service failed.
  May 10 06:30:16 localhost.localdomain sudo[3468]: pam_unix(sudo:session): session closed for user root
  May 10 06:30:16 localhost.localdomain polkitd[393]: Unregistered Authentication Agent for unix-process:3470:439245 (system bus name :1.64, object path /org/f
  
  
  </code></pre>
  
  <p>when I do this and secure(file) in log directory was updated like this.</p>
  
  <p>but i have no idea what i have to do this detail.</p>
  
  <pre><code>$ systemctl start postgresql-12.service
  ==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-units ===
  Authentication is required to manage system services or units.
  Authenticating as: root
  Password:
  ==== AUTHENTICATION COMPLETE ===
  Job for postgresql-12.service failed because the control process exited with error code. See "systemctl status postgresql-12.service" and "journalctl -xe" for details.
  </code></pre>
  
  <pre><code>May 10 08:01:06 localhost polkitd[382]: Registered Authentication Agent for unix-process:3289:174171 (system bus name :1.71 [/usr/bin/pkttyagent --notify-fd 5 --fallback], object path /org/freedesktop/PolicyKit1/AuthenticationAgent, locale en_US.UTF-8)
  May 10 08:01:09 localhost polkitd[382]: Operator of unix-process:3289:174171 successfully authenticated as unix-user:root to gain ONE-SHOT authorization for action org.freedesktop.systemd1.manage-units for system-bus-name::1.72 [systemctl start postgresql-12.service] (owned by unix-user:vagrant)
  May 10 08:01:09 localhost polkitd[382]: Unregistered Authentication Agent for unix-process:3289:174171 (system bus name :1.71, object path /org/freedesktop/PolicyKit1/AuthenticationAgent, locale en_US.UTF-8) (disconnected from bus)
  </code></pre>
  
  <p>postgresql-Sun.log</p>
  
  <pre><code>2020-05-10 05:04:35.435 UTC [3207] LOG:  could not connect to Ident server at address "127.0.0.1", port 113: Connection refused
  2020-05-10 05:04:35.435 UTC [3207] FATAL:  Ident authentication failed for user "postgres"
  2020-05-10 05:04:35.435 UTC [3207] DETAIL:  Connection matched pg_hba.conf line 82: "host    all             all             127.0.0.1/32       
  </code></pre>