Обсуждение: Fresh Installation of 7.1.1 RPMs = no binding to a port

Поиск
Список
Период
Сортировка

Fresh Installation of 7.1.1 RPMs = no binding to a port

От
Neil Mock
Дата:
Hi,

I just installed (not upgraded) Postgrseql 7.1.1 from
RPM's from the postgresl website.  I'm running RedHat
7.1, and the startup script in init.d seems to work
fine, it says postgresql is running, etc.  I can
create databases and work with them, but for some
reason postgrseql is not binding to any port.  I have
set in the configuration file for it to bind to port
5432 (which is the default I believe), but no luck.
Everything else seems to work fine.

Any suggestions?

Thanks,

Neil

__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - buy the things you want at great prices
http://auctions.yahoo.com/

Re: Fresh Installation of 7.1.1 RPMs = no binding to a port

От
Justin Clift
Дата:
Hi Neil,

In the configuration file, did you give it the -i option?

This tells it to accept TCP/IP connections as well.  Don't know your
exact script, so you may have to use -o '-i' to get the -i to take
effect.  You'll figure it out.

:-)

Regards and best wishes,

Justin Clift

Neil Mock wrote:
>
> Hi,
>
> I just installed (not upgraded) Postgrseql 7.1.1 from
> RPM's from the postgresl website.  I'm running RedHat
> 7.1, and the startup script in init.d seems to work
> fine, it says postgresql is running, etc.  I can
> create databases and work with them, but for some
> reason postgrseql is not binding to any port.  I have
> set in the configuration file for it to bind to port
> 5432 (which is the default I believe), but no luck.
> Everything else seems to work fine.
>
> Any suggestions?
>
> Thanks,
>
> Neil
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Auctions - buy the things you want at great prices
> http://auctions.yahoo.com/
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: Have you checked our extensive FAQ?
>
> http://www.postgresql.org/users-lounge/docs/faq.html

--
"My grandfather once told me that there are two kinds of people: those
who work and those who take the credit. He told me to try to be in the
first group; there was less competition there."
     - Indira Gandhi

Re: Fresh Installation of 7.1.1 RPMs = no binding to a port

От
Tom Lane
Дата:
Sounds like you forgot the -i switch, and/or need to add entries to
pg_hba.conf.

            regards, tom lane

Re: Fresh Installation of 7.1.1 RPMs = no binding to a port

От
Jorge Sarmiento
Дата:
This is true, in Red Hat 7.1 with PostgreSQL RPMS 7.1.1 you have to MANUALLY
edit the /etc/rc.d/init.d/postgresql and change the line:

su -l postgres -c "LC_ALL=C /usr/bin/pg_ctl  -D $PGDATA -p
/usr/bin/postmaster start >/dev/null 2>&1" < /dev/null

for:

su -l -s /bin/sh postgres -c "LC_ALL=C /usr/bin/pg_ctl -o "-i"  -D $PGDATA -p
/usr/bin/postmaster start >/dev/null 2>&1" < /dev/null

when you do this you add the -i option so the postmaster now listens for
connection (default localhost). After that you should change pg_hba.conf to
add permissions to external hosts to connect.

Greetings,

Jorge Sarmiento



On Sunday 27 May 2001 11:18 am, Justin Clift wrote:
> Hi Neil,
>
> In the configuration file, did you give it the -i option?
>
> This tells it to accept TCP/IP connections as well.  Don't know your
> exact script, so you may have to use -o '-i' to get the -i to take
> effect.  You'll figure it out.
>
> :-)
>
> Regards and best wishes,
>
> Justin Clift
>
> Neil Mock wrote:
> > Hi,
> >
> > I just installed (not upgraded) Postgrseql 7.1.1 from
> > RPM's from the postgresl website.  I'm running RedHat
> > 7.1, and the startup script in init.d seems to work
> > fine, it says postgresql is running, etc.  I can
> > create databases and work with them, but for some
> > reason postgrseql is not binding to any port.  I have
> > set in the configuration file for it to bind to port
> > 5432 (which is the default I believe), but no luck.
> > Everything else seems to work fine.
> >
> > Any suggestions?
> >
> > Thanks,
> >
> > Neil
> >
> > __________________________________________________
> > Do You Yahoo!?
> > Yahoo! Auctions - buy the things you want at great prices
> > http://auctions.yahoo.com/
> >
> > ---------------------------(end of broadcast)---------------------------
> > TIP 5: Have you checked our extensive FAQ?
> >
> > http://www.postgresql.org/users-lounge/docs/faq.html

Re: Fresh Installation of 7.1.1 RPMs = no binding to a port

От
Lamar Owen
Дата:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Monday 28 May 2001 10:25, Jorge Sarmiento wrote:
> This is true, in Red Hat 7.1 with PostgreSQL RPMS 7.1.1 you have to
> MANUALLY edit the /etc/rc.d/init.d/postgresql and change the line:

> su -l postgres -c "LC_ALL=C /usr/bin/pg_ctl  -D $PGDATA -p
> /usr/bin/postmaster start >/dev/null 2>&1" < /dev/null

Please edit /var/lib/pgsql/data/postgresql.conf instead. This is documented
in the README.rpm-dist shipped with the RPMs.  If the documentation in the
README is insufficient, please let me know where I need to correct and
improve it.  But editing the initscript is not necessary -- and, in fact,the
next time you upgrade your RPM installation, your careful edits will be
overwritten as the newer initscript is put into place....

To find the README, execute the following:
rpm -ql postgresql | grep rpm

I have considered making the default back to TCP/IP listening -- but I am
inclined not to do so for security's sake (if postmaster isn't listening it
can't be portscanned) -- and, besides, on a from-source install the default
is to not listen over TCP/IP.

Again, this behavior is documented in the friendly README.rpm-dist shipped in
the main postgresql rpm.
- --
Lamar Owen
WGCR Internet Radio
1 Peter 4:11
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.4 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE7E7va5kGGI8vV9eERAk3hAJ9B+nVRUb8v5btUUxKwpdbPllxsiwCguG2u
OsLdnEoQcQgTlZSLQYdQhlU=
=2jRy
-----END PGP SIGNATURE-----

Re: Fresh Installation of 7.1.1 RPMs = no binding to a port

От
teg@redhat.com (Trond Eivind Glomsrød)
Дата:
Lamar Owen <lamar.owen@wgcr.org> writes:

> I have considered making the default back to TCP/IP listening

I think that's a bad idea, for the "be secure by default" reason.

--
Trond Eivind Glomsrød
Red Hat, Inc.

Re: Fresh Installation of 7.1.1 RPMs = no binding to a port

От
Lamar Owen
Дата:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Tuesday 29 May 2001 11:35, Trond Eivind Glomsrød wrote:
> Lamar Owen <lamar.owen@wgcr.org> writes:
> > I have considered making the default back to TCP/IP listening

> I think that's a bad idea, for the "be secure by default" reason.

Agreed -- as I said, my inclination is to simply document how to properly
enable TCP/IP listening, which I've done -- well, I've at least put a pointer
in the README.rpm-dist to where more documentation can be found on the
subject.

I've tried to leave most things as default as possible, within reason.

And I'd rather have people surprized at TCP/IP not listening than surprized
about it listening....
- --
Lamar Owen
WGCR Internet Radio
1 Peter 4:11
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.4 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE7FAKf5kGGI8vV9eERAoM2AJ4zV+xej9UrPIstfSDTZb3gZTqKagCg5jUf
y0ZBpRYnAO105Ak8ar1dZk8=
=FFPO
-----END PGP SIGNATURE-----