Обсуждение: postgresql-9.1.4 macosx-10.6.8 (hostssl) psql -h hostname crashes

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

postgresql-9.1.4 macosx-10.6.8 (hostssl) psql -h hostname crashes

От
raf
Дата:
hi,

i've just upgraded to 9.1.4 on macosx-10.6.8 and psql crashes
whenever the -h option is used (either with "localhost" or any
other hostname). i only have hostssl connections.

attached is a macosx crash report in case it helps.

i think i'll downgrade now :-)

cheers,
raf


Вложения

Re: postgresql-9.1.4 macosx-10.6.8 (hostssl) psql -h hostname crashes

От
Tom Lane
Дата:
raf <raf@raf.org> writes:
> i've just upgraded to 9.1.4 on macosx-10.6.8 and psql crashes
> whenever the -h option is used (either with "localhost" or any
> other hostname). i only have hostssl connections.

> attached is a macosx crash report in case it helps.

[ squint ... ]  There's something awfully fishy about this link map;
it looks like you've linked to three different versions of libssl,
and likewise for its crony libcrypto:

>        0x1000ad000 -        0x100102fff +libssl.dylib ??? (???) <A3839A52-E3DA-5899-2D4B-EAB22611CE56>
/Library/PostgreSQL/9.1/lib/libssl.dylib
>        0x10015b000 -        0x100187fff  libssl.0.9.7.dylib 0.9.7 (compatibility 0.9.7)
<AB9DB3A1-FBE8-5FAE-5691-E5BCDD6DB211>/usr/lib/libssl.0.9.7.dylib 
>        0x100199000 -        0x10027ffe7  libcrypto.0.9.7.dylib 0.9.7 (compatibility 0.9.7)
<BA5E5276-8696-906D-0A37-0FFEF022B482>/usr/lib/libcrypto.0.9.7.dylib 
>        0x1002d7000 -        0x10043efdf +libcrypto.1.0.0.dylib ??? (???) <DC3B6ADA-E9AF-77BE-8E24-61B34C53F6DD>
/Library/PostgreSQL/9.1/lib/libcrypto.1.0.0.dylib
>     0x7fff84f65000 -     0x7fff85084fe7  libcrypto.0.9.8.dylib 0.9.8 (compatibility 0.9.8)
<14115D29-432B-CF02-6B24-A60CC533A09E>/usr/lib/libcrypto.0.9.8.dylib 
>     0x7fff850fd000 -     0x7fff8513aff7  libssl.0.9.8.dylib 0.9.8 (compatibility 0.9.8)
<F743389F-F25A-A77D-4FCA-D6B01AF2EE6D>/usr/lib/libssl.0.9.8.dylib 

The references to /Library/PostgreSQL/9.1/ make me guess that you're
using EDB's version?  If so, they broke something.  In any case,
I'm thinking this is a build error and not anything to do with the
Postgres source code.

            regards, tom lane

Re: postgresql-9.1.4 macosx-10.6.8 (hostssl) psql -h hostname crashes

От
raf
Дата:
Tom Lane wrote:

> raf <raf@raf.org> writes:
> > i've just upgraded to 9.1.4 on macosx-10.6.8 and psql crashes
> > whenever the -h option is used (either with "localhost" or any
> > other hostname). i only have hostssl connections.
>
> > attached is a macosx crash report in case it helps.
>
> [ squint ... ]  There's something awfully fishy about this link map;
> it looks like you've linked to three different versions of libssl,
> and likewise for its crony libcrypto:
>
> >        0x1000ad000 -        0x100102fff +libssl.dylib ??? (???) <A3839A52-E3DA-5899-2D4B-EAB22611CE56>
/Library/PostgreSQL/9.1/lib/libssl.dylib
> >        0x10015b000 -        0x100187fff  libssl.0.9.7.dylib 0.9.7 (compatibility 0.9.7)
<AB9DB3A1-FBE8-5FAE-5691-E5BCDD6DB211>/usr/lib/libssl.0.9.7.dylib 
> >        0x100199000 -        0x10027ffe7  libcrypto.0.9.7.dylib 0.9.7 (compatibility 0.9.7)
<BA5E5276-8696-906D-0A37-0FFEF022B482>/usr/lib/libcrypto.0.9.7.dylib 
> >        0x1002d7000 -        0x10043efdf +libcrypto.1.0.0.dylib ??? (???) <DC3B6ADA-E9AF-77BE-8E24-61B34C53F6DD>
/Library/PostgreSQL/9.1/lib/libcrypto.1.0.0.dylib
> >     0x7fff84f65000 -     0x7fff85084fe7  libcrypto.0.9.8.dylib 0.9.8 (compatibility 0.9.8)
<14115D29-432B-CF02-6B24-A60CC533A09E>/usr/lib/libcrypto.0.9.8.dylib 
> >     0x7fff850fd000 -     0x7fff8513aff7  libssl.0.9.8.dylib 0.9.8 (compatibility 0.9.8)
<F743389F-F25A-A77D-4FCA-D6B01AF2EE6D>/usr/lib/libssl.0.9.8.dylib 

there are a lot of libssl's here (system, xcode, macports, plus other
application-specific ones i didn't list):

  /Developer/SDKs/MacOSX10.5.sdk/usr/lib/libssl.0.9.7.dylib
  /Developer/SDKs/MacOSX10.5.sdk/usr/lib/libssl.0.9.dylib
  /Developer/SDKs/MacOSX10.5.sdk/usr/lib/libssl.dylib
  /Developer/SDKs/MacOSX10.6.sdk/usr/lib/libssl.0.9.7.dylib
  /Developer/SDKs/MacOSX10.6.sdk/usr/lib/libssl.0.9.8.dylib
  /Developer/SDKs/MacOSX10.6.sdk/usr/lib/libssl.0.9.dylib
  /Developer/SDKs/MacOSX10.6.sdk/usr/lib/libssl.dylib
  /opt/local/lib/libssl.1.0.0.dylib
  /opt/local/lib/libssl.a
  /opt/local/lib/libssl.dylib
  /opt/local/lib/nss/libssl3.dylib
  /usr/lib/libssl.0.9.7.dylib
  /usr/lib/libssl.0.9.8.dylib
  /usr/lib/libssl.0.9.dylib
  /usr/lib/libssl.dylib
  /Library/PostgreSQL/9.1/lib/libssl.1.0.0.dylib
  /Library/PostgreSQL/9.1/lib/libssl.a
  /Library/PostgreSQL/9.1/lib/libssl.dylib
  /Library/PostgreSQL/9.1/pgAdmin3.app/Contents/Frameworks/libssl.dylib

the working version of psql from 9.1.3 is using the system's libssl-0.9.7:

$ otool -L /Library/PostgreSQL/9.1/bin/psql
/Library/PostgreSQL/9.1/bin/psql:
        @loader_path/../lib/libpq.5.dylib (compatibility version 5.0.0, current version 5.4.0)
        /usr/lib/libssl.0.9.7.dylib (compatibility version 0.9.7, current version 0.9.7)
        @loader_path/../lib/libedit.0.dylib (compatibility version 1.0.0, current version 1.37.0)
        /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.4)

the non-working version from 9.1.4 is using the libssl-1.0.0 in the postgres directory:

$ otool -L /Library/PostgreSQL/9.1/bin/psql
/Library/PostgreSQL/9.1/bin/psql:
        @loader_path/../lib/libpq.5.dylib (compatibility version 5.0.0, current version 5.4.0)
        @loader_path/../lib/libssl.dylib (compatibility version 1.0.0, current version 1.0.0)
        @loader_path/../lib/libedit.0.dylib (compatibility version 1.0.0, current version 1.37.0)
        /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.4)

it's odd that three versions are mentioned in the crash report.

> The references to /Library/PostgreSQL/9.1/ make me guess that you're
> using EDB's version?

that's correct.

> If so, they broke something.  In any case,
> I'm thinking this is a build error and not anything to do with the
> Postgres source code.

hopefully, they'll notice and fix it.

>             regards, tom lane

cheers,
raf

Re: postgresql-9.1.4 macosx-10.6.8 (hostssl) psql -h hostname crashes

От
Sachin Srivastava
Дата:
On Thu, Aug 2, 2012 at 6:34 AM, raf <raf@raf.org> wrote:

> Tom Lane wrote:
>
> > raf <raf@raf.org> writes:
> > > i've just upgraded to 9.1.4 on macosx-10.6.8 and psql crashes
> > > whenever the -h option is used (either with "localhost" or any
> > > other hostname). i only have hostssl connections.
> >
> > > attached is a macosx crash report in case it helps.
> >
> > [ squint ... ]  There's something awfully fishy about this link map;
> > it looks like you've linked to three different versions of libssl,
> > and likewise for its crony libcrypto:
> >
> > >        0x1000ad000 -        0x100102fff +libssl.dylib ??? (???)
> <A3839A52-E3DA-5899-2D4B-EAB22611CE56>
> /Library/PostgreSQL/9.1/lib/libssl.dylib
> > >        0x10015b000 -        0x100187fff  libssl.0.9.7.dylib 0.9.7
> (compatibility 0.9.7) <AB9DB3A1-FBE8-5FAE-5691-E5BCDD6DB211>
> /usr/lib/libssl.0.9.7.dylib
> > >        0x100199000 -        0x10027ffe7  libcrypto.0.9.7.dylib 0.9.7
> (compatibility 0.9.7) <BA5E5276-8696-906D-0A37-0FFEF022B482>
> /usr/lib/libcrypto.0.9.7.dylib
> > >        0x1002d7000 -        0x10043efdf +libcrypto.1.0.0.dylib ???
> (???) <DC3B6ADA-E9AF-77BE-8E24-61B34C53F6DD>
> /Library/PostgreSQL/9.1/lib/libcrypto.1.0.0.dylib
> > >     0x7fff84f65000 -     0x7fff85084fe7  libcrypto.0.9.8.dylib 0.9.8
> (compatibility 0.9.8) <14115D29-432B-CF02-6B24-A60CC533A09E>
> /usr/lib/libcrypto.0.9.8.dylib
> > >     0x7fff850fd000 -     0x7fff8513aff7  libssl.0.9.8.dylib 0.9.8
> (compatibility 0.9.8) <F743389F-F25A-A77D-4FCA-D6B01AF2EE6D>
> /usr/lib/libssl.0.9.8.dylib
>
> there are a lot of libssl's here (system, xcode, macports, plus other
> application-specific ones i didn't list):
>
>   /Developer/SDKs/MacOSX10.5.sdk/usr/lib/libssl.0.9.7.dylib
>   /Developer/SDKs/MacOSX10.5.sdk/usr/lib/libssl.0.9.dylib
>   /Developer/SDKs/MacOSX10.5.sdk/usr/lib/libssl.dylib
>   /Developer/SDKs/MacOSX10.6.sdk/usr/lib/libssl.0.9.7.dylib
>   /Developer/SDKs/MacOSX10.6.sdk/usr/lib/libssl.0.9.8.dylib
>   /Developer/SDKs/MacOSX10.6.sdk/usr/lib/libssl.0.9.dylib
>   /Developer/SDKs/MacOSX10.6.sdk/usr/lib/libssl.dylib
>   /opt/local/lib/libssl.1.0.0.dylib
>   /opt/local/lib/libssl.a
>   /opt/local/lib/libssl.dylib
>   /opt/local/lib/nss/libssl3.dylib
>   /usr/lib/libssl.0.9.7.dylib
>   /usr/lib/libssl.0.9.8.dylib
>   /usr/lib/libssl.0.9.dylib
>   /usr/lib/libssl.dylib
>   /Library/PostgreSQL/9.1/lib/libssl.1.0.0.dylib
>   /Library/PostgreSQL/9.1/lib/libssl.a
>   /Library/PostgreSQL/9.1/lib/libssl.dylib
>   /Library/PostgreSQL/9.1/pgAdmin3.app/Contents/Frameworks/libssl.dylib
>
> the working version of psql from 9.1.3 is using the system's libssl-0.9.7:
>
> $ otool -L /Library/PostgreSQL/9.1/bin/psql
> /Library/PostgreSQL/9.1/bin/psql:
>         @loader_path/../lib/libpq.5.dylib (compatibility version 5.0.0,
> current version 5.4.0)
>         /usr/lib/libssl.0.9.7.dylib (compatibility version 0.9.7, current
> version 0.9.7)
>         @loader_path/../lib/libedit.0.dylib (compatibility version 1.0.0,
> current version 1.37.0)
>         /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
> version 111.1.4)
>
> the non-working version from 9.1.4 is using the libssl-1.0.0 in the
> postgres directory:
>
> $ otool -L /Library/PostgreSQL/9.1/bin/psql
> /Library/PostgreSQL/9.1/bin/psql:
>         @loader_path/../lib/libpq.5.dylib (compatibility version 5.0.0,
> current version 5.4.0)
>         @loader_path/../lib/libssl.dylib (compatibility version 1.0.0,
> current version 1.0.0)
>         @loader_path/../lib/libedit.0.dylib (compatibility version 1.0.0,
> current version 1.37.0)
>         /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
> version 111.1.4)
>
> it's odd that three versions are mentioned in the crash report.
>
> > The references to /Library/PostgreSQL/9.1/ make me guess that you're
> > using EDB's version?
>
> that's correct.
>
> > If so, they broke something.  In any case,
> > I'm thinking this is a build error and not anything to do with the
> > Postgres source code.
>

I tried the same on my Mac 10.6.8,  using PostgreSQL 9.1.5, my settings are:

pg_hba.conf
hostssl    all             all             127.0.0.1/32            md5

Laptop17:9.1 sachin$ PGSSLMODE=require bin/psql -h 127.0.0.1 -U postgres -p
5434 -d postgres
Password for user postgres:
psql (9.1.5)
SSL connection (cipher: DHE-RSA-AES256-SHA, bits: 256)
Type "help" for help.

postgres=# SELECT version();
                                                                version


----------------------------------------------------------------------------------------------------------------------------------------
 PostgreSQL 9.1.5 on x86_64-apple-darwin, compiled by
i686-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5666) (dot 3),
64-bit
(1 row)

Laptop17:~ sachin$ otool -L /Library/PostgreSQL/9.1/bin/psql
/Library/PostgreSQL/9.1/bin/psql:
@loader_path/../lib/libpq.5.dylib (compatibility version 5.0.0, current
version 5.4.0)
@loader_path/../lib/libssl.dylib (compatibility version 1.0.0, current
version 1.0.0)
@loader_path/../lib/libedit.0.dylib (compatibility version 1.0.0, current
version 1.37.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version
111.1.4)
Laptop17:~ sachin$

So things seems to work just fine with PG 9.1.5,  Can you try to upgrade to
9.1.5 and see if the error/crash is still there.



>
> hopefully, they'll notice and fix it.
>
> >                       regards, tom lane
>
> cheers,
> raf
>
>
> --
> Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-bugs
>



--
Regards,
Sachin Srivastava
EnterpriseDB, India