0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Setting up local postgresql database server for WSL/Ubuntu

Posted at

The offical Ubuntu guide can be a little confusing.

Here are the correct steps in order to set up a local postgresql database server.

  1. sudo apt install postgresql
  2. sudo service postgresql start
  3. sudo su - postgres
  4. createuser --superuser $USER where $USER is your username
  5. psql
  6. \password $USER is typed into the psql console to set up your account.
  7. \q to exit
  8. createdb $USER by convention
  9. exit and now you can run psql in your own console with your username.
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?