-
Notifications
You must be signed in to change notification settings - Fork 3
/
15_postgresql
50 lines (43 loc) · 2.1 KB
/
15_postgresql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
# To create a database instance, after install do
# sudo mkdir -p /opt/local/var/db/postgresql83/defaultdb
# sudo chown postgres:postgres /opt/local/var/db/postgresql83/defaultdb
# sudo su postgres -c '/opt/local/lib/postgresql83/bin/initdb -D /opt/local/var/db/postgresql83/defaultdb'
#
# The files belonging to this database system will be owned by user "postgres".
# This user must also own the server process.
#
# The database cluster will be initialized with locale C.
# The default database encoding has accordingly been set to SQL_ASCII.
# The default text search configuration will be set to "english".
#
# fixing permissions on existing directory /opt/local/var/db/postgresql83/defaultdb ... ok
# creating subdirectories ... ok
# selecting default max_connections ... 20
# selecting default shared_buffers/max_fsm_pages ... 2400kB/20000
# creating configuration files ... ok
# creating template1 database in /opt/local/var/db/postgresql83/defaultdb/base/1 ... ok
# initializing pg_authid ... ok
# initializing dependencies ... ok
# creating system views ... ok
# loading system objects' descriptions ... ok
# creating conversions ... ok
# creating dictionaries ... ok
# setting privileges on built-in objects ... ok
# creating information schema ... ok
# vacuuming database template1 ... ok
# copying template1 to template0 ... ok
# copying template1 to postgres ... ok
#
# WARNING: enabling "trust" authentication for local connections
# You can change this by editing pg_hba.conf or using the -A option the
# next time you run initdb.
#
# Success. You can now start the database server using:
#
# /opt/local/lib/postgresql83/bin/postgres -D /opt/local/var/db/postgresql83/defaultdb
# or
# /opt/local/lib/postgresql83/bin/pg_ctl -D /opt/local/var/db/postgresql83/defaultdb -l logfile start
# http://www.robbyonrails.com/articles/2008/01/22/installing-ruby-on-rails-and-postgresql-on-os-x-third-edition
alias pg_ld="mate /opt/local/etc/LaunchDaemons/org.macports.postgresql83-server/postgresql83-server.wrapper"
alias pg_dbs="open /opt/local/var/db/postgresql83"
alias pg_logs="open /opt/local/var/log/postgresql83"