Fedora
User
To the operation of the database, first transfer to Postgres user
The first time you want to set a password
sudo passwd postgres
Switch to this user
Su-postgres
Database initialization
The first time to do
initdb/var/lib/pgsql/data/
pg_ctl-d/var/lib/pgsql/data-l logfile Start
PS: Built in the home is better, home space generally give a relatively large, I used to encounter PostgreSQL database space is full of problems
Initdb/home/postgres
pg_ctl-d/home/postgres-l logfile Start
Pure SQL Build User
Psql
Go to SQL command line
CREATE role Gitlab LOGIN ENCRYPTED PASSWORD ' z129854 ' NOINHERIT VALID ' UNTIL ';
CREATE DATABASE gitlabhq_production with encoding= ' UTF8 ' Owner=gitlab;
Creating a database (recommended for pure SQL)
Then enter:
Createdb Bigzhu
The library is placed in the/var/lib/postgresql/8.4/main/base but is not removable.
Establish database user (recommended pure SQL)
Go to SQL Editor
Psql Bigzhu
Create a user
CREATE user username with PASSWORD ' password ';
CREATE USER bigzhu with PASSWORD ' password ';
CREATE USER redmine with PASSWORD ' password ';
Delete Database
Dropdb Bigzhu