postgres on SuSE 9.1
Dear my friends... Usually I use MySQL. Now I have to migrate my database from MySQL to Postgres. I have created a database successfully with "creatdb" and a user account successfully. But I can not access the postgres with pgaccess. I found this error message : " Error trying to connect to database 'custadm' on host localhost PostgreSQL error message: Connection to database failed could not create socket: ©Hÿ¿pHÿ¿lHÿ¿ " Error in startup script: window ".pgaw:OpenDB" was deleted before its visibility changed while executing "tkwait visibility .pgaw:OpenDB" (procedure "::Connections::openConn" line 40) invoked from within "::Connections::openConn $i 1" (procedure "main" line 63) invoked from within "main $argc $argv" (file "/usr/bin/pgaccess" line 810) patrixlinux@patrix:~> " Here what I have done " patrixlinux@patrix:~> su Password: patrix:/localhome/patrixlinux # su postgres postgres@patrix:/localhome/patrixlinux> cd postgres@patrix:~> psql custadm Welcome to psql 7.4.2, the PostgreSQL interactive terminal. Type: \copyright for distribution terms \h for help with SQL commands \? for help on internal slash commands \g or terminate with semicolon to execute query \q to quit custadm=# create user someone with password 'pass_me' createdb; CREATE USER custadm=# " Anybody would be so nice to tell me why I can not access my postgres with pgaccess? Thank you very much in advance. __________________________________ Do you Yahoo!? Friends. Fun. Try the all-new Yahoo! Messenger. http://messenger.yahoo.com/
måndag 07 juni 2004 18:37 skrev Prabu Subroto:
Anybody would be so nice to tell me why I can not access my postgres with pgaccess?
Thank you very much in advance.
Most likely the good old access control ... as user postgres, do: # cd # cd data And take a look at a file called 'pg_hba.conf'. You probably have a line, which looks like: local all all ident sameuser Which means, you don't need to create a password for that user, just need to create it. And that you need to be the same user in postgres, as in unix, when you log onto the database at localhost.
__________________________________ Do you Yahoo!? Friends. Fun. Try the all-new Yahoo! Messenger. http://messenger.yahoo.com/
It's solved... Thank you very...very much, my
friend...
I still have one question. I also have one station at
home with SuSE 8.2. Why this postgres from SuSE 8.2
does not have "pg_hba.conf"?
and how can I use pgaccess to access into the postgres
server?
And its "postgresql.conf" is also different as the one
from SuSE 9.2.
Thank you very much in advance.
--- �n_Hansen
m�dag 07 juni 2004 18:37 skrev Prabu Subroto:
Anybody would be so nice to tell me why I can not access my postgres with pgaccess?
Thank you very much in advance.
Most likely the good old access control ... as user postgres, do:
# cd # cd data
And take a look at a file called 'pg_hba.conf'. You probably have a line, which looks like:
local all all ident sameuser
Which means, you don't need to create a password for that user, just need to create it. And that you need to be the same user in postgres, as in unix, when you log onto the database at localhost.
__________________________________ Do you Yahoo!? Friends. Fun. Try the all-new Yahoo! Messenger. http://messenger.yahoo.com/
-- To unsubscribe, email: suse-programming-e-unsubscribe@suse.com For additional commands, email: suse-programming-e-help@suse.com Archives can be found at: http://lists.suse.com/archive/suse-programming-e
__________________________________ Do you Yahoo!? Friends. Fun. Try the all-new Yahoo! Messenger. http://messenger.yahoo.com/
onsdag 09 juni 2004 17:38 skrev Prabu Subroto:
It's solved... Thank you very...very much, my friend...
I still have one question. I also have one station at home with SuSE 8.2. Why this postgres from SuSE 8.2 does not have "pg_hba.conf"? and how can I use pgaccess to access into the postgres server? And its "postgresql.conf" is also different as the one from SuSE 9.2.
Thank you very much in advance.
You're welcome Here's a copy of my pg_hba.conf file, you can use it for reference. To access my server from <internet ip>, I've added a user with: createuser -aMP <user> Now I can access the server, remotely as that user as long as I'm located at the designed <internet ip> below. For using pgaccess, you start it, and select "connect to DB" (the leftmost icon). If you select "localhost" as the server, then you only need to fill in the database as ident->sameuser authendication will apply. If you select a name for the server, that will result in an IP listed in pg_hba.conf with password authendication, you will need to type in the username and password associated with that authendication. # TYPE DATABASE USER IP-ADDRESS IP-MASK METHOD # IPv6-style local connections: host all all ::1 ffff:ffff:ffff:ffff:ffff:ffff: ffff:ffff trust # For local access local all all ident sameuser # For access via "intranet" requires a specific password for each # user. host all all 192.168.0.0 255.255.252.0 md5 # For acces over internet, requires a specific password # for the user. host all all <internet ip> 255.255.255.255 md5 hth, Örn
participants (2)
-
Prabu Subroto
-
Örn Hansen