Difference between revisions of "Brew install postgresql@15"
Jump to navigation
Jump to search
(Created page with "{{lc}} brew install postgresl@15") |
|||
(16 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
{{lc}} | {{lc}} | ||
− | [[brew install]] | + | [[brew install postgresql]]@15 |
+ | |||
+ | ==> Caveats | ||
+ | ==> postgresql@15 | ||
+ | This formula has created a default database cluster with: | ||
+ | [[initdb]] [[--locale]]=C [[-E]] [[UTF-8]] /Users/user/brew/var/postgresql@15 | ||
+ | For more details, read: | ||
+ | https://www.postgresql.org/docs/15/app-initdb.html | ||
+ | <pre> | ||
+ | postgresql@15 is keg-only, which means it was not symlinked into /Users/user/brew, | ||
+ | because this is an alternate version of another formula. | ||
+ | |||
+ | If you need to have postgresql@15 first in your PATH, run: | ||
+ | echo 'export PATH="/Users/user/brew/opt/postgresql@15/bin:$PATH"' >> ~/.zshrc | ||
+ | |||
+ | For compilers to find postgresql@15 you may need to set: | ||
+ | export LDFLAGS="-L/Users/user/brew/opt/postgresql@15/lib" | ||
+ | export CPPFLAGS="-I/Users/user/brew/opt/postgresql@15/include" | ||
+ | |||
+ | For pkg-config to find postgresql@15 you may need to set: | ||
+ | export PKG_CONFIG_PATH="/Users/user/brew/opt/postgresql@15/lib/pkgconfig" | ||
+ | |||
+ | |||
+ | To restart postgresql@15 after an upgrade: | ||
+ | brew services restart postgresql@15 | ||
+ | Or, if you don't want/need a background service you can just run: | ||
+ | /Users/user/brew/opt/postgresql@15/bin/postgres -D /Users/user/brew/var/postgresql@15 | ||
+ | </pre> | ||
+ | |||
+ | |||
+ | To connect: | ||
+ | * <code>[[psql postgres]]</code> | ||
+ | |||
+ | |||
+ | == Errors == | ||
+ | psql | ||
+ | [[psql: error: connection to server on socket]] "[[/tmp/.s.PGSQL.5432]]" failed: FATAL: database "xxxx" does not exist | ||
+ | |||
+ | == Related == | ||
+ | * <code>[[brew formulae]]</code> | ||
+ | |||
+ | |||
+ | == See also == | ||
+ | * {{psql}} | ||
+ | * {{brew install postgres}} | ||
+ | |||
+ | [[Category:PostgreSQL]] |
Latest revision as of 10:17, 23 September 2024
brew install postgresql@15
==> Caveats ==> postgresql@15 This formula has created a default database cluster with: initdb --locale=C -E UTF-8 /Users/user/brew/var/postgresql@15 For more details, read: https://www.postgresql.org/docs/15/app-initdb.html
postgresql@15 is keg-only, which means it was not symlinked into /Users/user/brew, because this is an alternate version of another formula. If you need to have postgresql@15 first in your PATH, run: echo 'export PATH="/Users/user/brew/opt/postgresql@15/bin:$PATH"' >> ~/.zshrc For compilers to find postgresql@15 you may need to set: export LDFLAGS="-L/Users/user/brew/opt/postgresql@15/lib" export CPPFLAGS="-I/Users/user/brew/opt/postgresql@15/include" For pkg-config to find postgresql@15 you may need to set: export PKG_CONFIG_PATH="/Users/user/brew/opt/postgresql@15/lib/pkgconfig" To restart postgresql@15 after an upgrade: brew services restart postgresql@15 Or, if you don't want/need a background service you can just run: /Users/user/brew/opt/postgresql@15/bin/postgres -D /Users/user/brew/var/postgresql@15
To connect:
Errors[edit]
psql psql: error: connection to server on socket "/tmp/.s.PGSQL.5432" failed: FATAL: database "xxxx" does not exist
Related[edit]
See also[edit]
- PostgreSQL:
psql
,.psqlrc, .pgpass
,$HOME/.pg service.conf
,-U, -W, -d
, meta-commands:\du, \dg, \ddp, \dp, \list, \dn, \dt, \c, \l, \di, \q
,show users
,show
,su - postgres
,psql -c, \?, \connect, \conninfo
,--version, --help
, PL/pgSQL brew install postgresql
, PostgreSQL versions,psql
,brew install libpq
, Database operations
Advertising: