Configure PostgreSQL by storing the database files in an alternative location, initializing the data directory, setting the database service to start on boot, and start the database service.
|
Note These are RHEL 7 commands. RHEL 6 users must translate the service commands into the old form.
|
- (Optional) If you want to store database files in an alternative location follow the steps in the section Specifying an Alternative PostgreSQL Data Directory on RHEL.
- (Optional) If you are migrating to PostgreSQL 11 from an older version follow the steps in the section Upgrading to PostgreSQL 11.
- Initialize the PostgreSQL data directory:
sudo -u postgres /usr/pgsql-11/bin/initdb --encoding UTF8 /var/lib/pgsql/11/data
- Set the database service to start on boot:
chkconfig postgresql-11 on
- If you are migrating from PostgreSQL 9.5, you will need to stop the old version before proceeding to the next step.
systemctl stop postgresql-9.5
systemctl disable postgresql-9.5
- Start the database service:
systemctl enable postgresql-11
systemctl start postgresql-11
© 2001-2021 Fair Isaac Corporation. All rights reserved. This documentation is the
property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not
convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except
solely for internal evaluation purposes to determine whether to purchase a license to the software
described in this documentation, or as otherwise set forth in a written software license agreement
between you and FICO (or a FICO affiliate). Use of this documentation and the software described in
it must conform strictly to the foregoing permitted uses, and no other use is permitted.