Last active
April 5, 2016 10:38
-
-
Save noherczeg/e7fd57b62dbfe5ad170aadc24a60f4ef to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ## source: http://www.if-not-true-then-false.com/2012/install-postgresql-on-fedora-centos-red-hat-rhel/ ## | |
| ## Add exclude to /etc/yum.repos.d/fedora.repo file ## | |
| $ nano /etc/yum.repos.d/fedora.repo | |
| [fedora] | |
| ... | |
| exclude=postgresql* | |
| ## Add exclude to /etc/yum.repos.d/fedora-updates.repo ## | |
| $ nano /etc/yum.repos.d/fedora-updates.repo | |
| [updates] | |
| ... | |
| exclude=postgresql* | |
| ## Fedora 23 - x86_64 - 64-bit ## | |
| $ rpm -Uvh http://yum.postgresql.org/9.4/fedora/fedora-23-x86_64/pgdg-fedora94-9.4-4.noarch.rpm | |
| ## Install Postgres ## | |
| $ dnf install postgresql94 postgresql94-server postgresql94-contrib | |
| ## Initialize a database ## | |
| $ su - postgres -c /usr/pgsql-9.4/bin/initdb | |
| ## Start PostgreSQL 9.4 ## | |
| $ systemctl start postgresql-9.4.service | |
| ## Start PostgreSQL 9.4 on every boot ## | |
| $ systemctl enable postgresql-9.4.service |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment