[MacPorts] #68119: postgresql15: Initialize database cluster fails

MacPorts noreply at macports.org
Sun Sep 3 18:03:23 UTC 2023


#68119: postgresql15: Initialize database cluster fails
-------------------------------------------------+-------------------------
  Reporter:  Klogic1                             |      Owner:  (none)
      Type:  defect                              |     Status:  new
  Priority:  Normal                              |  Milestone:
 Component:  ports                               |    Version:  2.8.1
Resolution:                                      |   Keywords:
      Port:  postgresql15, postgresql15-server,  |
  postgresql_select                              |
-------------------------------------------------+-------------------------

Comment (by ryandesign):

 Replying to [comment:2 dgilman]:
 > I believe the `getcwd` / `chdir` errors have to do with the postgres
 user's home directory, that is a bug, I will investigate a fix.

 Klogic1, what is the postgres user's home directory on your system? You
 can find out by running:

 {{{
 dscl . -read /Users/postgres NFSHomeDirectory
 }}}

 On my system, it says:

 {{{
 NFSHomeDirectory: /opt/local/var/db/postgresql15
 }}}

 However, as I recall, the first postgresql*-server port you install
 creates the postgres user and sets its home directory, and if you later
 want to use a different postgres*-server port, you have to edit the
 postgres user's `NFSHomeDirectory` attribute manually with `dscl`. Also,
 if you used Apple's Migration Assistant to move another computer's data to
 this computer, and you migrated the postgres user or any other users
 created by MacPorts or the macports user itself, Migration Assistant will
 move all of their home directories and they will have to be moved back
 where they belong manually in addition to editing the records with `dscl`.

-- 
Ticket URL: <https://trac.macports.org/ticket/68119#comment:3>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list