...
You will now have a postgresql user on your system. This account is reserved for running Postgresql in a secure manner. This account neither has a password or a home directory. This account also has a role in the database for administration purposes. I will show you how to use it this account as we go forward.
The postgresql service is also added to the system to start automatically.
...
Warning |
---|
In order to complete this section I need to figure out how to do a configured portable setup of PostgreSQL. |
Initial Setup
Secure Master Account
By default, the master account in the database postgres does not have a password. We want to set this up so that we can provide access to a dba without the dba requiring sudo access to the operating system.
Change the Default postgres Database User Account
If you want to manage postgresql outside of the command line, you must change the default password in postgresql.
The first step, is to launch the postgresql shell.
...
Code Block | ||
---|---|---|
| ||
sudo -u postgres # LaunchRun as the followingoperating commandsystem as the user postgresuser postgres which also has a role in the database. psql # Launch the postgres shell. postgres # Name of the database to load (not the user). |
Info |
---|
Sometimes the last parameter is not used. This is short-hand. If no database name is specified, psql will try to load the database matching the user name. |
Here is what it looks like once you are in,
...