DEV Community

Discussion on: Getting PostgreSQL To Work On A Rails App Using Ubuntu And WSL

Collapse
 
butadpj profile image
Paul John Butad • Edited

If you don't want to manually create a database from postgres shell (you want to use "rake db:create" command)
You'll get this error
FATAL: password authentication failed for user "postgres"

Make sure you have set the password first after you type "psql".
Just type the command below and you'll get a prompt to enter your password

postgress=# \password
Enter fullscreen mode Exit fullscreen mode
Collapse
 
nrymarz profile image
Nathan Rymarz

Thanks for the advice. I wasn't aware that you could or needed to re enter your password for the default postgres user. Being able to create the db from rake db:create would definitely save time. I'll keep this in mind for the future!