Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3624168
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T23:28:27+00:00 2026-05-18T23:28:27+00:00

I created a user like this: create user blog with password ‘blog’; Then I

  • 0

I created a user like this:

create user blog with password 'blog';

Then I made it the owner of a database:

alter database blog_development owner to blog;

Then I tried to log in and it didn’t work:

$ psql -d blog_development -U blog -W
Password for user blog:
psql: FATAL:  Ident authentication failed for user "blog"

Any idea why?

One thing I’ve tried is editing pg_hba.conf

 76 # Database administrative login by UNIX sockets
 77 local   all                postgres                          ident
 78
 79 # TYPE  DATABASE           USER        CIDR-ADDRESS          METHOD
 80
 81 # "local" is for Unix domain socket connections only
 82 local   all                all                               ident
 83 # IPv4 local connections:
 84 host    all                all         127.0.0.1/32          md5
 85 host    blog_development   blog        127.0.0.1/32          md5
 86 # IPv6 local connections:
 87 host    all                all         ::1/128               md5

Line 85 is the one I added. I restarted PostgreSQL after that but it didn’t seem to change anything.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-18T23:28:27+00:00Added an answer on May 18, 2026 at 11:28 pm

    I was just trying to connect in the wrong way. Here’s the right way:

    psql -h localhost -U blog -d blog_development
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Imagine a database table that looks like this: create table [dbo].[user] ( id int
I'd like to use this method to create user-friendly URL. Because my site is
I want to do something like this: create table app_users ( app_user_id smallint(6) not
I'd like to do something like this: class Task(models.Model): ... created_by = models.ForeignKey( User,
I have a script which creates a user-defined object like this: obj = new
I've created a simple user control which is manually created with something like MyUserControl
I would like to create a user interface like the iGoogle or facebook profiles
I'm trying to create User Control which will work like a rich button. It's
I'd like to create a user registration form where the user ticks some boxes
I'm trying to create a user control that allows users to make something like

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.