Configure Postgresql in Ubuntu and Connect With Datagrip: Sheetal Kumar
Configure Postgresql in Ubuntu and Connect With Datagrip: Sheetal Kumar
Sheetal Kumar
Expert in PHP, MySql, Android, Python, Javascript, React
February 13, 2018
User-defined types
Table inheritance
Sophisticated locking mechanism
Foreign key referential integrity
Views, rules, subquery
Nested transactions (savepoints)
Multi-version concurrency control (MVCC)
Asynchronous replication
Here I will explain how to configure PostgreSQL on Ubuntu Server and connect with your local machine.
First of all, you need a ubuntu server and connect your server using SSH. When you are connected with
SSH use the following commands to install PostgreSQL on Ubuntu.
PostgreSQL is installed on your Ubuntu server. Currently, your database user is Postgres that has all
database related privilege. Now you need to create a new user with a password so that you can connect
the database using your app or any database connection tool like DataGrip.
To create a user in Postgres you first need to create a user on your server with the same name. So let's
create a user in ubuntu server:
Now I will create a new user and database named sheetal. So first you need to switch your user to
postgres.
sudo -i -u postgres
createuser sheetal -P
This will ask for a password to be set for the user. Please remember this password, this will require to
connect your database.
createdb sheetal
You have a user, password and a database. Now if you server port 5432 is now publicly open then open
it your server firewall and security setting. So that you can connect the database publicly.
exit
Now you need to update postgres configuration to allow users to connect the database from anywhere.
First update:
Second update:
listen_addresses='*'
/etc/init.d/postgresql restart
All is done on the server side. Now open DataGrip on your local system and connect.
Now you are live with your database. Enjoy the successful connection.
Keywords:
Postgresql Ubuntu Datagrip Configuration Connection
Configure PostgreSQL in ubuntu and connect with DataGrip SQL Language Elements and Data type SQL Operators
Rules to write SQL commands with some important SQL commands Uses of Set Operators Allow mysql to access anywhere at port 3306 in ubuntu
Take MySql database backup daily automatically in Ubuntu Server using cron
Terms & Conditions Privacy Policy