pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedTCP/IP connection problem
10+ messages / 4 participants
[nested] [flat]
* TCP/IP connection problem
@ 2006-10-26 13:02 Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 13:06 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
2006-10-26 15:41 ` Re: TCP/IP connection problem Enrico <scotty@linuxtime.it>
0 siblings, 2 replies; 10+ messages in thread
From: Jari Vauhkonen @ 2006-10-26 13:02 UTC (permalink / raw)
To: pgsql-admin
Hello,
I have tried to set up a PostgreSQL server with no success. Connections from
other-than-local hosts won't work. I've tried to connect from Windows XP using
PgWorkSheet && pgAccess.
I have studied the internet for similar problems without an answer. the
following has been done:
-- PSQL & PSQL-server installation
-- configuring the pg_hba.conf with following lines:
host all 127.0.0.1 255.255.255.255 trust
host all <my_ip> 255.255.255.255 trustlocal all trust
host koli <my_ip> 255.255.255.255 trust
-- configuring the postgresql.conf wit following lines:
#listen_addresses = '*'
#port = 5432
#tcpip_socket = true
-- starting the postmaster with command
/usr/local/pgsql/bin/postmaster -i -D /usr/local/pgsql/data &
-- installing the PSQL ODBC driver for Windows
I wonder if the problem is related to the operating system's TCP/IP settings? I
tried netstat to find out if the port 5432 is used, but it seems that it isn't.
What should I do? Remember, I'm quite a newbie with linux-style operating
systems so keep it simple.
Thanks already,
Jari
^ permalink raw reply [nested|flat] 10+ messages in thread
* Re: TCP/IP connection problem
2006-10-26 13:02 TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
@ 2006-10-26 13:06 ` Ben Suffolk <ben@vanilla.net>
2006-10-26 15:22 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
1 sibling, 1 reply; 10+ messages in thread
From: Ben Suffolk @ 2006-10-26 13:06 UTC (permalink / raw)
To: Jari Vauhkonen <jari.vauhkonen@joensuu.fi>; +Cc: pgsql-admin
> -- configuring the postgresql.conf wit following lines:
> #listen_addresses = '*'
> #port = 5432
> #tcpip_socket = true
Jari,
You need to remove the # from the lines, a # comments the line out,
so although you have set the port and changed the address it will not
actually have done anything.
Regards
Ben
^ permalink raw reply [nested|flat] 10+ messages in thread
* Re: TCP/IP connection problem
2006-10-26 13:02 TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 13:06 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
@ 2006-10-26 15:22 ` Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:26 ` Re: TCP/IP connection problem Alvaro Herrera <alvherre@commandprompt.com>
0 siblings, 1 reply; 10+ messages in thread
From: Jari Vauhkonen @ 2006-10-26 15:22 UTC (permalink / raw)
To: Ben Suffolk <ben@vanilla.net>; +Cc: pgsql-admin
Quoting Ben Suffolk <ben@vanilla.net>:
> > -- configuring the postgresql.conf wit following lines:
> > #listen_addresses = '*'
> > #port = 5432
> > #tcpip_socket = true
>
> Jari,
>
> You need to remove the # from the lines, a # comments the line out,
> so although you have set the port and changed the address it will not
> actually have done anything.
>
Ben,
thank you for your reply. A truly amateurish mistake by me :)
BUT fixing that one did no good. The problem remains.
Jari
^ permalink raw reply [nested|flat] 10+ messages in thread
* Re: TCP/IP connection problem
2006-10-26 13:02 TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 13:06 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
2006-10-26 15:22 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
@ 2006-10-26 15:26 ` Alvaro Herrera <alvherre@commandprompt.com>
2006-10-26 15:29 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
0 siblings, 1 reply; 10+ messages in thread
From: Alvaro Herrera @ 2006-10-26 15:26 UTC (permalink / raw)
To: Jari Vauhkonen <jari.vauhkonen@joensuu.fi>; +Cc: Ben Suffolk <ben@vanilla.net>; pgsql-admin
Jari Vauhkonen wrote:
> Quoting Ben Suffolk <ben@vanilla.net>:
>
> > > -- configuring the postgresql.conf wit following lines:
> > > #listen_addresses = '*'
> > > #port = 5432
> > > #tcpip_socket = true
> >
> > Jari,
> >
> > You need to remove the # from the lines, a # comments the line out,
> > so although you have set the port and changed the address it will not
> > actually have done anything.
>
> thank you for your reply. A truly amateurish mistake by me :)
>
> BUT fixing that one did no good. The problem remains.
Did you restart the server after changing those lines?
--
Alvaro Herrera http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support
^ permalink raw reply [nested|flat] 10+ messages in thread
* Re: TCP/IP connection problem
2006-10-26 13:02 TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 13:06 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
2006-10-26 15:22 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:26 ` Re: TCP/IP connection problem Alvaro Herrera <alvherre@commandprompt.com>
@ 2006-10-26 15:29 ` Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:35 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
0 siblings, 1 reply; 10+ messages in thread
From: Jari Vauhkonen @ 2006-10-26 15:29 UTC (permalink / raw)
To: Alvaro Herrera <alvherre@commandprompt.com>; +Cc: pgsql-admin
Quoting Alvaro Herrera <alvherre@commandprompt.com>:
> Jari Vauhkonen wrote:
> > Quoting Ben Suffolk <ben@vanilla.net>:
> >
> > > > -- configuring the postgresql.conf wit following lines:
> > > > #listen_addresses = '*'
> > > > #port = 5432
> > > > #tcpip_socket = true
> > >
> > > Jari,
> > >
> > > You need to remove the # from the lines, a # comments the line out,
> > > so although you have set the port and changed the address it will not
> > > actually have done anything.
> >
> > thank you for your reply. A truly amateurish mistake by me :)
> >
> > BUT fixing that one did no good. The problem remains.
>
> Did you restart the server after changing those lines?
>
> --
Yes.
^ permalink raw reply [nested|flat] 10+ messages in thread
* Re: TCP/IP connection problem
2006-10-26 13:02 TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 13:06 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
2006-10-26 15:22 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:26 ` Re: TCP/IP connection problem Alvaro Herrera <alvherre@commandprompt.com>
2006-10-26 15:29 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
@ 2006-10-26 15:35 ` Ben Suffolk <ben@vanilla.net>
2006-10-26 15:52 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
0 siblings, 1 reply; 10+ messages in thread
From: Ben Suffolk @ 2006-10-26 15:35 UTC (permalink / raw)
To: Jari Vauhkonen <jari.vauhkonen@joensuu.fi>; +Cc: pgsql-admin
>>>> actually have done anything.
>>>
>>> thank you for your reply. A truly amateurish mistake by me :)
>>>
>>> BUT fixing that one did no good. The problem remains.
>>
>> Did you restart the server after changing those lines?
>>
>> --
>
> Yes.
When you try and connect check /var/log/messages for any errors, and
let us know what (if any) errors are reported.
Regards
Ben
^ permalink raw reply [nested|flat] 10+ messages in thread
* Re: TCP/IP connection problem
2006-10-26 13:02 TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 13:06 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
2006-10-26 15:22 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:26 ` Re: TCP/IP connection problem Alvaro Herrera <alvherre@commandprompt.com>
2006-10-26 15:29 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:35 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
@ 2006-10-26 15:52 ` Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:57 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
0 siblings, 1 reply; 10+ messages in thread
From: Jari Vauhkonen @ 2006-10-26 15:52 UTC (permalink / raw)
To: Ben Suffolk <ben@vanilla.net>; +Cc: pgsql-admin
Quoting Ben Suffolk <ben@vanilla.net>:
> >>>> actually have done anything.
> >>>
> >>> thank you for your reply. A truly amateurish mistake by me :)
> >>>
> >>> BUT fixing that one did no good. The problem remains.
> >>
> >> Did you restart the server after changing those lines?
> >>
> >> --
> >
> > Yes.
>
> When you try and connect check /var/log/messages for any errors, and
> let us know what (if any) errors are reported.
>
1) These are the latest messages ( /var/log/messages )
Only my test of closing down & reopening postgresql.
Oct 26 18:33:25 joymap su(pam_unix)[4901]: session opened for user postgres by
root(uid=0)
Oct 26 18:33:25 joymap su(pam_unix)[4901]: session closed for user postgres
Oct 26 18:33:33 joymap postgresql: postmaster shutdown succeeded
Oct 26 18:33:35 joymap su(pam_unix)[4951]: session opened for user postgres by
root(uid=0)
Oct 26 18:33:35 joymap su(pam_unix)[4951]: session closed for user postgres
2) Enrico's firewall propotion:
There is a firewall in WinXP ( F-Secure ). I allready tried disabling it. I have
also configured the Red Hat security level. Right now it allows all traffic
thru eth0.
3) I managed to get a connection-lookalike:
netstat print:
tcp 0 0 <my_psql_server_domain>:postgres <my_client_domain>:2429 TIME_WAIT
What next?
^ permalink raw reply [nested|flat] 10+ messages in thread
* Re: TCP/IP connection problem
2006-10-26 13:02 TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 13:06 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
2006-10-26 15:22 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:26 ` Re: TCP/IP connection problem Alvaro Herrera <alvherre@commandprompt.com>
2006-10-26 15:29 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:35 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
2006-10-26 15:52 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
@ 2006-10-26 15:57 ` Ben Suffolk <ben@vanilla.net>
2006-10-26 16:35 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
0 siblings, 1 reply; 10+ messages in thread
From: Ben Suffolk @ 2006-10-26 15:57 UTC (permalink / raw)
To: Jari Vauhkonen <jari.vauhkonen@joensuu.fi>; +Cc: pgsql-admin
> 1) These are the latest messages ( /var/log/messages )
> Only my test of closing down & reopening postgresql.
>
> Oct 26 18:33:25 joymap su(pam_unix)[4901]: session opened for user
> postgres by
> root(uid=0)
> Oct 26 18:33:25 joymap su(pam_unix)[4901]: session closed for user
> postgres
> Oct 26 18:33:33 joymap postgresql: postmaster shutdown succeeded
> Oct 26 18:33:35 joymap su(pam_unix)[4951]: session opened for user
> postgres by
> root(uid=0)
> Oct 26 18:33:35 joymap su(pam_unix)[4951]: session closed for user
> postgres
>
> 2) Enrico's firewall propotion:
> There is a firewall in WinXP ( F-Secure ). I allready tried
> disabling it. I have
> also configured the Red Hat security level. Right now it allows all
> traffic
> thru eth0.
>
> 3) I managed to get a connection-lookalike:
> netstat print:
> tcp 0 0 <my_psql_server_domain>:postgres <my_client_domain>:2429
> TIME_WAIT
>
> What next?
I suggest you try and connect from the pgsql machine locally using
tcp :-
> psql -h = same.host.as.configured.from.windows.box -p = 5432 db user
Then we can see if the problem still lies with pgsql, or with the
firewall.
BEn
^ permalink raw reply [nested|flat] 10+ messages in thread
* Re: TCP/IP connection problem
2006-10-26 13:02 TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 13:06 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
2006-10-26 15:22 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:26 ` Re: TCP/IP connection problem Alvaro Herrera <alvherre@commandprompt.com>
2006-10-26 15:29 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:35 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
2006-10-26 15:52 ` Re: TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:57 ` Re: TCP/IP connection problem Ben Suffolk <ben@vanilla.net>
@ 2006-10-26 16:35 ` Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
0 siblings, 0 replies; 10+ messages in thread
From: Jari Vauhkonen @ 2006-10-26 16:35 UTC (permalink / raw)
To: Ben Suffolk <ben@vanilla.net>; +Cc: pgsql-admin
Quoting Ben Suffolk <ben@vanilla.net>:
>
>
> I suggest you try and connect from the pgsql machine locally using
> tcp :-
>
> > psql -h = same.host.as.configured.from.windows.box -p = 5432 db user
>
> Then we can see if the problem still lies with pgsql, or with the
> firewall.
>
Ben,
All right. Now it works.
I tested your suggestion and found out from logfiles that my pg_hba.conf file
was quite corrupted ( i.e. invalid IP masks ) . I re-arranged the file, tested,
re-arranged again... and finally, it works.
Thanks to everyone who helped. I hope all of you didn't get too annoyed with all
these "PRESS ANYKEY" - "Hey, where's the anykey???" -styled questions of mine.
Jari
^ permalink raw reply [nested|flat] 10+ messages in thread
* Re: TCP/IP connection problem
2006-10-26 13:02 TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
@ 2006-10-26 15:41 ` Enrico <scotty@linuxtime.it>
1 sibling, 0 replies; 10+ messages in thread
From: Enrico @ 2006-10-26 15:41 UTC (permalink / raw)
To: pgsql-admin
On Thu, 26 Oct 2006 16:02:01 +0300
Jari Vauhkonen <jari.vauhkonen@joensuu.fi> wrote:
>
>
> Hello,
>
> I have tried to set up a PostgreSQL server with no success. Connections from
> other-than-local hosts won't work. I've tried to connect from Windows XP using
> PgWorkSheet && pgAccess.
Is there any firwall between client and server like ZoneAlarm on Windows XP?
Enrico
--
If Bill Gates had a penny for everytime Windows crashed,he'd be a multi-billionaire by now .......oh look, he already is !!!!
scotty@linuxtime.it - Skype:sscotty71
http://www.linuxtime.it/enricopirozzi
^ permalink raw reply [nested|flat] 10+ messages in thread
end of thread, other threads:[~2006-10-26 16:35 UTC | newest]
Thread overview: 10+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2006-10-26 13:02 TCP/IP connection problem Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 13:06 ` Ben Suffolk <ben@vanilla.net>
2006-10-26 15:22 ` Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:26 ` Alvaro Herrera <alvherre@commandprompt.com>
2006-10-26 15:29 ` Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:35 ` Ben Suffolk <ben@vanilla.net>
2006-10-26 15:52 ` Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:57 ` Ben Suffolk <ben@vanilla.net>
2006-10-26 16:35 ` Jari Vauhkonen <jari.vauhkonen@joensuu.fi>
2006-10-26 15:41 ` Enrico <scotty@linuxtime.it>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox