[Ilugc] Help with PostgreSQL (psycopg)

  • From: tech@xxxxxxxxxxxxxxx (Ma Siva Kumar)
  • Date: Wed Jul 19 16:55:32 2006

On Wed July 19 2006 4:26 pm, you wrote:

------------------- pg_hba.conf-------------------------
# Database administrative login by UNIX sockets
local   all         postgres                          ident sameuser

# TYPE  DATABASE    USER        CIDR-ADDRESS          METHOD

# "local" is for Unix domain socket connections only
local   all         all                               ident sameuser
--------------------------------------------------------

Should this be made into this ??

------------------- pg_hba.conf-------------------------
# Database administrative login by UNIX sockets
local   all         postgres                          ident sameuser

# TYPE  DATABASE    USER        CIDR-ADDRESS          METHOD

# "local" is for Unix domain socket connections only
local   all         all                               trust
--------------------------------------------------------

I guess so. Did you change this, restart postgresql and try connecting again? 

The set up 
"ident sameuser" means you can connect only as the user you are working as 
(unix loginname). With password or trust authentication, that restriction is 
gone and your script should work.

3. I am not sure why your python script fails to connect. Are you running
your python script in the same machine running the database server?

Nope, I am having PostgreSQL in my laptop in which I am working on
Python. The gimmick needs to be found the first time, as I am pretty new
to PostgreSQL and things aren't like MySQL.

After you are through with this do subscribe to pgsql-general@xxxxxxxxxxxxxx 
mailing list. 
One of the high quality tech lists I subscribe to. The discussions are always 
on topic, except when someone brings up MySQL :-). 

With PostgreSQL things are not like MySQL, they are far better. That is what 
the PostgreSQL developers and users believe. 

Best regards,

Ma Sivakumar
PS: You are not replying to the list. Use the reply all button in your mail 
client :-)

-- 
Integrated Management Tools for leather industry
----------------------------------
http://www.leatherlink.net

Ma Siva Kumar,
BSG LeatherLink (P) Ltd,
Chennai - 600106

Other related posts: