[owncloud] improve the postgresql documentation a bit
Adam Williamson
adamwill at fedoraproject.org
Fri Aug 29 06:22:45 UTC 2014
commit 85f1afbc39e55d0a440089bad87900c76e7326ac
Author: Adam Williamson <awilliam at redhat.com>
Date: Thu Aug 28 16:45:30 2014 -0700
improve the postgresql documentation a bit
owncloud-postgresql.txt | 39 +++++++++++++++++++++++++++++----------
1 files changed, 29 insertions(+), 10 deletions(-)
---
diff --git a/owncloud-postgresql.txt b/owncloud-postgresql.txt
index b4afe02..f035a93 100644
--- a/owncloud-postgresql.txt
+++ b/owncloud-postgresql.txt
@@ -1,15 +1,34 @@
Configure PostgreSQL for ownCloud
=================================
-Before you can use PostgreSQL as database backend, you need to follow a couple of steps:
-1. make sure that your PostgreSQL service is configured and running properly
-2. log in to PostgreSQL as system user to create the database and a dedicated user account for ownCloud:
-su - -c "psql" postgres
- CREATE USER username WITH PASSWORD 'password';
- CREATE DATABASE owncloud TEMPLATE template0 ENCODING 'UNICODE';
- ALTER DATABASE owncloud OWNER TO username;
- GRANT ALL PRIVILEGES ON DATABASE owncloud TO username;
+To use PostgreSQL as database backend, you need to do the following:
-Choose identifier and password accordingly.
+1. Make sure that your PostgreSQL service is configured and running properly.
+ If this is a fresh install, you will need to run "postgresql-setup initdb"
+ as root, then "systemctl enable postgresql.service; systemctl start
+ postgresql.service". For more details on initial configuration of PostgreSQL
+ in Fedora, see https://fedoraproject.org/wiki/PostgreSQL
-Now you can launch the ownCloud setup screen, select PostgreSQL in the advanced settings and fill in your credentials.
+2. Log in to PostgreSQL as system user to create the database and a dedicated
+ user account for ownCloud:
+ # su - -c "psql" postgres
+ CREATE USER username WITH PASSWORD 'password';
+ CREATE DATABASE owncloud TEMPLATE template0 ENCODING 'UNICODE';
+ ALTER DATABASE owncloud OWNER TO username;
+ GRANT ALL PRIVILEGES ON DATABASE owncloud TO username;
+ Choose identifier and password accordingly.
+
+3. ownCloud talks to PostgreSQL via TCP/IP, so you need to configure an
+ appropriate authentication mechanism in /var/lib/pgsql/data/pg_hba.conf.
+ For a simple configuration with ownCloud and PostgreSQL on the same host,
+ set the METHOD for the lines that apply to localhost TCP/IP connections
+ to "password". Note that this will result in the password being sent
+ unencrypted from ownCloud to the PostgreSQL server. For more details, see
+ http://www.postgresql.org/docs/9.3/static/auth-pg-hba-conf.html.
+
+4. You also need to allow the web server to communicate with the database by
+ TCP/IP: SELinux disallows this by default. Run:
+ # setsebool -P httpd_can_network_connect_db on
+
+Now you can launch the ownCloud setup screen, select PostgreSQL in the advanced
+settings and fill in your credentials.
More information about the scm-commits
mailing list