postgres 9.0 crash when bringing up hot standby

postgres 9.0 crash when bringing up hot standby

am 06.08.2010 15:10:15 von Alanoly Andrews

--_000_09B23E7BF70425478C1330D893A722C602FEC019BDMailSVRinve ra_
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable


Hello,

OS=20level ==20AIX=205.3=20ML-8
Postgres=20version ==209.0=20beta-4

I'm=20testing=20"hot=20standby"=20using=20"streaming=20WAL=2 0records".=20On=
=20trying=20to=20bring=20up=20the=20hot=20standby,=20I=20see =20the=20follow=
ing=20error=20in=20the=20log:

LOG: database=20system=20was=20interrupted;=20last=20kn own=20up=20at=
=202010-08-05=2014:46:36=20EDT
LOG: entering=20standby=20mode
LOG: restored=20log=20file=20"000000010000000000000007" =20from=20archi=
ve
LOG: redo=20starts=20at=200/7000020
LOG: consistent=20recovery=20state=20reached=20at=200/8 000000
LOG: database=20system=20is=20ready=20to=20accept=20rea d=20only=20conn=
ections
cp:=20/pgarclog/pg1/000000010000000000000008:=20A=20file=20o r=20directory=
=20in=20the=20path=20name=20does=20not=20exist.
LOG: WAL=20receiver=20process=20(PID=201073206)=20was=2 0terminated=20b=
y=20signal=2011
LOG: terminating=20any=20other=20active=20server=20proc esses

There=20is=20a=20core=20dump.=20The=20debugger=20indicates=2 0the=20crash=20=
sequence=20as=20follows:

(dbx)=20where
_alloc_initial_pthread(??)=20at=200x90000000049567c
__pth_init(??)=20at=200x900000000493ba4
uload(??,=20??,=20??,=20??,=20??,=20??,=20??,=20??)=20at=200 x9fffffff0001954
load_64.load(??,=20??,=20??)=20at=200x90000000004686c
loadAndInit()=20at=200x90000000047bd7c
dlopen(??,=20??)=20at=200x90000000011cc4c
internal_load_library(libname ==20"/apps/pg_9.0_b4/lib/p ostgresql/libpq=
walreceiver.so"),=20line=20234=20in=20"dfmgr.c"
load_file(filename ==20"libpqwalreceiver",=20restricted= 20= '\0'),=
=20line=20156=20in=20"dfmgr.c"
WalReceiverMain(),=20line=20248=20in=20"walreceiver.c"
AuxiliaryProcessMain(argc ==202,=20argv ==200x0fffff ffffffa8b8),=20=
line=20428=20in=20"bootstrap.c"
StartChildProcess(type ==20WalReceiverProcess),=20line=2 04405=20in=20"p=
ostmaster.c"
sigusr1_handler(postgres_signal_arg ==2030),=20line=2042 27=20in=20"post=
master.c"
__fd_select(??,=20??,=20??,=20??,=20??)=20at=200x90000000011 805c
postmaster.select(__fds ==205,=20__readlist ==200x0f ffffffffffd0a8,=
=20__writelist ==20(nil),=20__exceptlist ==20(nil),= 20__timeout=20=
= 0x0ffffffffffff0c0),=20line=20229=20in=20"time.h"
unnamed=20block=20in=20ServerLoop(),=20line=201391=20in=20"p ostmaster.c"
unnamed=20block=20in=20ServerLoop(),=20line=201391=20in=20"p ostmaster.c"
ServerLoop(),=20line=201391=20in=20"postmaster.c"
PostmasterMain(argc ==201,=20argv ==200x00000001102a a4b0),=20line=
=201092=20in=20"postmaster.c"
main(argc ==201,=20argv ==200x00000001102aa4b0),=20l ine=20188=20in=
=20"main.c"


Any=20pointers=20on=20how=20to=20resolve=20the=20issue=20wil l=20be=20much=
=20appreciated.

Thanks.

Alanoly=20Andrews=20(alanolya@invera.com)
Senior=20Software=20Engineer
Invera=20Inc.
Montreal,=20QC

****************************************************
This=20e-mail=20may=20be=20privileged=20and/or=20confidentia l,=20and=20the=
=20sender=20does=20not=20waive=20any=20related=20rights=20an d=20obligations=
..=20Any=20distribution,=20use=20or=20copying=20of=20this=20 e-mail=20or=20th=
e=20information=20it=20contains=20by=20other=20than=20an=20i ntended=20recip=
ient=20is=20unauthorized.=20If=20you=20received=20this=20e-m ail=20in=20erro=
r,=20please=20advise=20me=20(by=20return=20e-mail=20or=20oth erwise)=20immed=
iately.
=20
Ce=20courriel=20est=20confidentiel=20et=20prot=E9g=E9.=20L'e xp=E9diteur=20n=
e=20renonce=20pas=20aux=20droits=20et=20obligations=20qui=20 s'y=20rapporten=
t. Toute=20diffusion,=20utilisation=20ou=20copie=20de=20 ce=20message=20=
ou=20des=20renseignements=20qu'il=20contient=20par=20une=20p ersonne=20autre=
=20que=20le=20(les)=20destinataire(s)=20d=E9sign=E9(s)=20est =20interdite.=
=20Si=20vous=20recevez=20ce=20courriel=20par=20erreur,=20veu illez=20m'en=20=
aviser=20imm=E9diatement,=20par=20retour=20de=20courriel=20o u=20par=20un=20=
autre=20moyen.
****************************************************


--_000_09B23E7BF70425478C1330D893A722C602FEC019BDMailSVRinve ra_
Content-Type: text/html; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

microsoft-com:office:office"=20xmlns:w=3D"urn:schemas-micros oft-com:office:=
word"=20xmlns:m=3D"http://schemas.microsoft.com/office/2004/ 12/omml"=20xmln=
s=3D"http://www.w3.org/TR/REC-html40">


ascii">
edium)">








 



font-family:
"Garamond","serif"'>Hello,



font-family:
"Garamond","serif";color:black'> 



font-family:
"Garamond","serif"'>OS=20level ==20AIX=205.3=20ML-8 b>



font-family:
"Garamond","serif"'>Postgres=20version ==209.0=20beta-4 n>



t-family:"Times=20New=20Roman","serif";
color:black'> 



font-family:
"Garamond","serif"'>I’m=20testing=20“hot=20standby”=20usi=
ng=20“streaming=20WAL=20records”.=20On
trying=20to=20bring=20up=20the=20hot=20standb=
y,=20I=20see=20the
following=20error=20in=20the=20log:



font-family:
"Garamond","serif"'> 



t-family:"Courier=20New"'>LOG: 
database=20system=20was=20interrupted;=20last=20known=20up=2 0at=202010-08-0=
5=2014:46:36=20EDT style=3D'color:black;background:black;mso-highlight:black'> n>



t-family:"Courier=20New"'>LOG: 
entering=20standby=20mode highlight:
black'>



t-family:"Courier=20New"'>LOG: 
restored=20log=20file=20"000000010000000000000007"=20from=20archi=
ve style=3D'color:black;background:black;mso-highlight:black'> n>



t-family:"Courier=20New"'>LOG: 
redo=20starts=20at=200/7000020 ;mso-highlight:
black'>



t-family:"Courier=20New"'>LOG: 
consistent=20recovery=20state=20reached=20at=200/8000000 lor:black;
background:black;mso-highlight:black'>



t-family:"Courier=20New"'>LOG: 
database=20system=20is=20ready=20to=20accept=20read=20only=2 0connections an=20style=3D'color:
black;background:black;mso-highlight:black'>



t-family:"Courier=20New"'>cp:
/pgarclog/pg1/000000010000000000000008:=20A=20file=20or=20di rectory=20in=20=
the=20path=20name
does=20not=20exist. ght:black'>



t-family:"Courier=20New"'>LOG: 
WAL=20receiver=20process=20(PID=201073206)=20was=20terminate d=20by=20signal=
=2011 style=3D'color:black;background:black;mso-highlight:black'> n>



t-family:"Courier=20New"'>LOG: 
terminating=20any=20other=20active=20server=20processes or:black;
background:black;mso-highlight:black'>



font-family:
"Garamond","serif"'> 



font-family:
"Garamond","serif"'>There=20is=20a=20core=20dump.=20The=20de bugger=20indica=
tes=20the=20crash=20sequence
as=20follows:



font-family:
"Garamond","serif"'> 



t-family:"Courier=20New"'>(dbx)
where p>



t-family:"Courier=20New"'>_alloc_initial_pthread(??)
at=200x90000000049567c hlight:
black'>



t-family:"Courier=20New"'>__pth_init(??)
at=200x900000000493ba4 hlight:
black'>



t-family:"Courier=20New"'>uload(??,
??,=20??,=20??,=20??,=20??,=20??,=20??)=20at=200x9fffffff000 1954 le=3D'color:black;
background:black;mso-highlight:black'>



t-family:"Courier=20New"'>load_64.load(??,
??,=20??)=20at=200x90000000004686c lack;
mso-highlight:black'>



t-family:"Courier=20New"'>loadAndInit()
at=200x90000000047bd7c hlight:
black'>



t-family:"Courier=20New"'>dlopen(??,
??)=20at=200x90000000011cc4c so-highlight:
black'>



t-family:"Courier=20New"'>internal_load_library(libname
= "/apps/pg_9.0_b4/lib/postgresql/libpqwalreceiver.so"),=20li=
ne=20234=20in
"dfmgr.c" ght:
black'>



t-family:"Courier=20New"'>load_file(filename
= "libpqwalreceiver",=20restricted ==20'\0'),=20line=2015=
6=20in
"dfmgr.c" ght:
black'>



t-family:"Courier=20New"'>WalReceiverMain(),
line=20248=20in=20"walreceiver.c" kground:black;
mso-highlight:black'>



t-family:"Courier=20New"'>AuxiliaryProcessMain(argc
= 2,=20argv ==200x0fffffffffffa8b8),=20line=20428=20 in=20 "boot=
strap.c" style=3D'color:black;background:black;mso-highlight:black'> n>



t-family:"Courier=20New"'>StartChildProcess(type
= WalReceiverProcess),=20line=204405=20in=20"postmaster.c " an
style=3D'color:black;background:black;mso-highlight:black'> n>



t-family:"Courier=20New"'>sigusr1_handler(postgres_signal_ar g
= 30),=20line=204227=20in=20"postmaster.c" lor:black;
background:black;mso-highlight:black'>



t-family:"Courier=20New"'>__fd_select(??,
??,=20??,=20??,=20??)=20at=200x90000000011805c background:black;
mso-highlight:black'>



t-family:"Courier=20New"'>postmaster.select(__fds
= 5,=20__readlist ==200x0fffffffffffd0a8,=20__writel ist ==20(ni=
l),=20__exceptlist =
(nil),=20__timeout ==200x0ffffffffffff0c0),=20line=20229 =20in=20 "t=
ime.h" style=3D'color:black;background:black;mso-highlight:black'> n>



t-family:"Courier=20New"'>unnamed
block=20in=20ServerLoop(),=20line=201391=20in=20"postmaster.c " an
style=3D'color:black;background:black;mso-highlight:black'> n>



t-family:"Courier=20New"'>unnamed
block=20in=20ServerLoop(),=20line=201391=20in=20"postmaster.c " an
style=3D'color:black;background:black;mso-highlight:black'> n>



t-family:"Courier=20New"'>ServerLoop(),
line=201391=20in=20"postmaster.c" kground:black;
mso-highlight:black'>



t-family:"Courier=20New"'>PostmasterMain(argc
= 1,=20argv ==200x00000001102aa4b0),=20line=201092=2 0in=20 "pos=
tmaster.c" style=3D'color:black;background:black;mso-highlight:black'> n>



t-family:"Courier=20New"'>main(argc
= 1,=20argv ==200x00000001102aa4b0),=20line=20188=20 in=20 "main=
..c" style=3D'color:black;background:black;mso-highlight:black'> n>



font-family:
"Garamond","serif"'> 



font-family:
"Garamond","serif"'> 



font-family:
"Garamond","serif"'>Any=20pointers=20on=20how=20to=20resolve =20the=20issue=
=20will=20be=20much
appreciated.



font-family:
"Garamond","serif"'> 



font-family:
"Garamond","serif"'>Thanks.



font-family:
"Garamond","serif"'> 



font-family:
"Garamond","serif"'>Alanoly=20Andrews=20( acom">alanolya@invera.com)



font-family:
"Garamond","serif"'>Senior=20Software=20Engineer



font-family:
"Garamond","serif"'>Invera=20Inc.



font-family:
"Garamond","serif"'>Montreal,=20QC










This=20e-mail=20may=20be=20privileged=20and/or=20confidentia l,=20and=20the=
=20sender=20does=20not=20waive=20any=20related=20rights=20an d=20obligations=
..=20Any=20distribution,=20use=20or=20copying=20of=20this=20 e-mail=20or=20th=
e=20information=20it=20contains=20by=20other=20than=20an=20i ntended=20recip=
ient=20is=20unauthorized.=20If=20you=20received=20this=20e-m ail=20in=20erro=
r,=20please=20advise=20me=20(by=20return=20e-mail=20or=20oth erwise)=20immed=
iately.

=20
Ce=20courriel=20est=20confidentiel=20et=20prot=E9g=E9.=20L'e xp=E9diteur=20n=
e=20renonce=20pas=20aux=20droits=20et=20obligations=20qui=20 s'y=20rapporten=
t. Toute=20diffusion,=20utilisation=20ou=20copie=20de=20 ce=20message=20=
ou=20des=20renseignements=20qu'il=20contient=20par=20une=20p ersonne=20autre=
=20que=20le=20(les)=20destinataire(s)=20d=E9sign=E9(s)=20est =20interdite.=
=20Si=20vous=20recevez=20ce=20courriel=20par=20erreur,=20veu illez=20m'en=20=
aviser=20imm=E9diatement,=20par=20retour=20de=20courriel=20o u=20par=20un=20=
autre=20moyen.



Mail=20sent=20via=20the=20Abaca=
=20EPG










--_000_09B23E7BF70425478C1330D893A722C602FEC019BDMailSVRinve ra_--

Re: postgres 9.0 crash when bringing up hot standby

am 06.08.2010 16:31:03 von Fujii Masao

On Fri, Aug 6, 2010 at 10:10 PM, Alanoly Andrews wrot=
e:
> I=92m testing =93hot standby=94 using =93streaming WAL records=94. On try=
ing to bring
> up the hot standby, I see the following error in the log:

Thanks for the report!

> LOG:=A0 database system was interrupted; last known up at 2010-08-05 14:4=
6:36
> LOG:=A0 entering standby mode
> LOG:=A0 restored log file "000000010000000000000007" from archive
> LOG:=A0 redo starts at 0/7000020
> LOG:=A0 consistent recovery state reached at 0/8000000
> LOG:=A0 database system is ready to accept read only connections
> cp: /pgarclog/pg1/000000010000000000000008: A file or directory in the pa=
th
> name does not exist.
> LOG:=A0 WAL receiver process (PID 1073206) was terminated by signal 11
> LOG:=A0 terminating any other active server processes
>
> There is a core dump. The debugger indicates the crash sequence as follow=
s:
>
> (dbx) where
> _alloc_initial_pthread(??) at 0x90000000049567c
> __pth_init(??) at 0x900000000493ba4
> uload(??, ??, ??, ??, ??, ??, ??, ??) at 0x9fffffff0001954
> load_64.load(??, ??, ??) at 0x90000000004686c
> loadAndInit() at 0x90000000047bd7c
> dlopen(??, ??) at 0x90000000011cc4c
> internal_load_library(libname =3D
> "/apps/pg_9.0_b4/lib/postgresql/libpqwalreceiver.so"), line 234 in "dfmgr=
..c"
> load_file(filename =3D "libpqwalreceiver", restricted =3D '\0'), line 156=
in
> "dfmgr.c"
> WalReceiverMain(), line 248 in "walreceiver.c"
> AuxiliaryProcessMain(argc =3D 2, argv =3D 0x0fffffffffffa8b8), line 428 in
> "bootstrap.c"
> StartChildProcess(type =3D WalReceiverProcess), line 4405 in "postmaster.=
c"
> sigusr1_handler(postgres_signal_arg =3D 30), line 4227 in "postmaster.c"
> __fd_select(??, ??, ??, ??, ??) at 0x90000000011805c
> postmaster.select(__fds =3D 5, __readlist =3D 0x0fffffffffffd0a8, __write=
list =3D
> (nil), __exceptlist =3D (nil), __timeout =3D 0x0ffffffffffff0c0), line 22=
9 in
> "time.h"
> unnamed block in ServerLoop(), line 1391 in "postmaster.c"
> unnamed block in ServerLoop(), line 1391 in "postmaster.c"
> ServerLoop(), line 1391 in "postmaster.c"
> PostmasterMain(argc =3D 1, argv =3D 0x00000001102aa4b0), line 1092 in
> "postmaster.c"
> main(argc =3D 1, argv =3D 0x00000001102aa4b0), line 188 in "main.c"
>
> Any pointers on how to resolve the issue will be much appreciated.

Sorry, I have no idea what's wrong :(

Is the simple LOAD command successful on your AIX?

Regards,

--=20
Fujii Masao
NIPPON TELEGRAPH AND TELEPHONE CORPORATION
NTT Open Source Software Center

--=20
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Re: postgres 9.0 crash when bringing up hot standby

am 06.08.2010 17:17:03 von Alanoly Andrews

Thanks. Yes, the LOAD command does work, on another database cluster on the=
same AIX machine.

-----Original Message-----
From: Fujii Masao [mailto:masao.fujii@gmail.com]=20
Sent: Friday, August 06, 2010 10:31 AM
To: Alanoly Andrews
Cc: pgsql-admin@postgresql.org; PostgreSQL-development
Subject: Re: [ADMIN] postgres 9.0 crash when bringing up hot standby

On Fri, Aug 6, 2010 at 10:10 PM, Alanoly Andrews wrot=
e:
> I'm testing "hot standby" using "streaming WAL records". On trying to bri=
ng
> up the hot standby, I see the following error in the log:

Thanks for the report!

> LOG:=A0 database system was interrupted; last known up at 2010-08-05 14:4=
6:36
> LOG:=A0 entering standby mode
> LOG:=A0 restored log file "000000010000000000000007" from archive
> LOG:=A0 redo starts at 0/7000020
> LOG:=A0 consistent recovery state reached at 0/8000000
> LOG:=A0 database system is ready to accept read only connections
> cp: /pgarclog/pg1/000000010000000000000008: A file or directory in the pa=
th
> name does not exist.
> LOG:=A0 WAL receiver process (PID 1073206) was terminated by signal 11
> LOG:=A0 terminating any other active server processes
>
> There is a core dump. The debugger indicates the crash sequence as follow=
s:
>
> (dbx) where
> _alloc_initial_pthread(??) at 0x90000000049567c
> __pth_init(??) at 0x900000000493ba4
> uload(??, ??, ??, ??, ??, ??, ??, ??) at 0x9fffffff0001954
> load_64.load(??, ??, ??) at 0x90000000004686c
> loadAndInit() at 0x90000000047bd7c
> dlopen(??, ??) at 0x90000000011cc4c
> internal_load_library(libname =3D
> "/apps/pg_9.0_b4/lib/postgresql/libpqwalreceiver.so"), line 234 in "dfmgr=
..c"
> load_file(filename =3D "libpqwalreceiver", restricted =3D '\0'), line 156=
in
> "dfmgr.c"
> WalReceiverMain(), line 248 in "walreceiver.c"
> AuxiliaryProcessMain(argc =3D 2, argv =3D 0x0fffffffffffa8b8), line 428 in
> "bootstrap.c"
> StartChildProcess(type =3D WalReceiverProcess), line 4405 in "postmaster.=
c"
> sigusr1_handler(postgres_signal_arg =3D 30), line 4227 in "postmaster.c"
> __fd_select(??, ??, ??, ??, ??) at 0x90000000011805c
> postmaster.select(__fds =3D 5, __readlist =3D 0x0fffffffffffd0a8, __write=
list =3D
> (nil), __exceptlist =3D (nil), __timeout =3D 0x0ffffffffffff0c0), line 22=
9 in
> "time.h"
> unnamed block in ServerLoop(), line 1391 in "postmaster.c"
> unnamed block in ServerLoop(), line 1391 in "postmaster.c"
> ServerLoop(), line 1391 in "postmaster.c"
> PostmasterMain(argc =3D 1, argv =3D 0x00000001102aa4b0), line 1092 in
> "postmaster.c"
> main(argc =3D 1, argv =3D 0x00000001102aa4b0), line 188 in "main.c"
>
> Any pointers on how to resolve the issue will be much appreciated.

Sorry, I have no idea what's wrong :(

Is the simple LOAD command successful on your AIX?

Regards,

--=20
Fujii Masao
NIPPON TELEGRAPH AND TELEPHONE CORPORATION
NTT Open Source Software Center
****************************************************
This e-mail may be privileged and/or confidential, and the sender does not =
waive any related rights and obligations. Any distribution, use or copying =
of this e-mail or the information it contains by other than an intended rec=
ipient is unauthorized. If you received this e-mail in error, please advise=
me (by return e-mail or otherwise) immediately.
=20
Ce courriel est confidentiel et prot=E9g=E9. L'exp=E9diteur ne renonce pas =
aux droits et obligations qui s'y rapportent. Toute diffusion, utilisation =
ou copie de ce message ou des renseignements qu'il contient par une personn=
e autre que le (les) destinataire(s) d=E9sign=E9(s) est interdite. Si vous =
recevez ce courriel par erreur, veuillez m'en aviser imm=E9diatement, par r=
etour de courriel ou par un autre moyen.
****************************************************


--=20
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Re: [HACKERS] postgres 9.0 crash when bringing up hot standby

am 06.08.2010 21:53:55 von Heikki Linnakangas

On 06/08/10 17:31, Fujii Masao wrote:
> On Fri, Aug 6, 2010 at 10:10 PM, Alanoly Andrews =
wrote:
>> I=92m testing =93hot standby=94 using =93streaming WAL records=94. On =
trying to bring
>> (dbx) where
>> _alloc_initial_pthread(??) at 0x90000000049567c
>> __pth_init(??) at 0x900000000493ba4
>> uload(??, ??, ??, ??, ??, ??, ??, ??) at 0x9fffffff0001954
>> load_64.load(??, ??, ??) at 0x90000000004686c
>> loadAndInit() at 0x90000000047bd7c
>> dlopen(??, ??) at 0x90000000011cc4c
>> internal_load_library(libname =3D
>> "/apps/pg_9.0_b4/lib/postgresql/libpqwalreceiver.so"), line 234 in "df=
mgr.c"
>> load_file(filename =3D "libpqwalreceiver", restricted =3D '\0'), line =
156 in
>> "dfmgr.c"
>> WalReceiverMain(), line 248 in "walreceiver.c"
>> AuxiliaryProcessMain(argc =3D 2, argv =3D 0x0fffffffffffa8b8), line 42=
8 in
>> "bootstrap.c"
>> StartChildProcess(type =3D WalReceiverProcess), line 4405 in "postmast=
er.c"
>> sigusr1_handler(postgres_signal_arg =3D 30), line 4227 in "postmaster.=
c"
>> __fd_select(??, ??, ??, ??, ??) at 0x90000000011805c
>> postmaster.select(__fds =3D 5, __readlist =3D 0x0fffffffffffd0a8, __wr=
itelist =3D
>> (nil), __exceptlist =3D (nil), __timeout =3D 0x0ffffffffffff0c0), line=
229 in
>> "time.h"
>> unnamed block in ServerLoop(), line 1391 in "postmaster.c"
>> unnamed block in ServerLoop(), line 1391 in "postmaster.c"
>> ServerLoop(), line 1391 in "postmaster.c"
>> PostmasterMain(argc =3D 1, argv =3D 0x00000001102aa4b0), line 1092 in
>> "postmaster.c"
>> main(argc =3D 1, argv =3D 0x00000001102aa4b0), line 188 in "main.c"
>>
>> Any pointers on how to resolve the issue will be much appreciated.

So, loading libpqwalreceiver library crashes. It looks like it might be=20
pthread-related. Perhaps something wrong with our makefiles, causing=20
libpqwalreceiver to be built with wrong flags? Does contrib/dblink work?=20
If you look at the build log, what is the command line used to compile=20
libpqwalreceiver, and what is the command line used to build other=20
libraries, like contrib/dblink?

--=20
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com

--=20
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Re: [HACKERS] postgres 9.0 crash when bringing up hot standby

am 11.08.2010 16:12:54 von Robert Haas

On Fri, Aug 6, 2010 at 3:53 PM, Heikki Linnakangas
wrote:
> So, loading libpqwalreceiver library crashes. It looks like it might be
> pthread-related. Perhaps something wrong with our makefiles, causing
> libpqwalreceiver to be built with wrong flags? Does contrib/dblink work? If
> you look at the build log, what is the command line used to compile
> libpqwalreceiver, and what is the command line used to build other
> libraries, like contrib/dblink?

I haven't seen any response to this from the OP, but it seems
worrisome. Has anyone else tested a Hot Standby configuraration -
successfully or otherwise - on AIX?

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise Postgres Company

--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Re: [HACKERS] postgres 9.0 crash when bringing up hot standby

am 11.08.2010 16:20:31 von Alanoly Andrews

Ok..in response to the questions from Heikki,

1. Yes, "contrib/dblink" does work. Here's the output from the command used=
to "make" dblink:
postgres:thimar> /usr/bin/gmake -C contrib/dblink install
gmake: Entering directory `/dinabkp/faouzis/postgresql-9.0beta1/contr=
ib/dblink'
/bin/sh ../../config/install-sh -c -d '/dinabkp/faouzis/local2/pgsql/=
lib'
/bin/sh ../../config/install-sh -c -d '/dinabkp/faouzis/local2/pgsql/=
share/contrib'
/bin/sh ../../config/install-sh -c -m 755 dblink.so '/dinabkp/faouzi=
s/local2/pgsql/lib/dblink.so'
/bin/sh ../../config/install-sh -c -m 644 ./uninstall_dblink.sql '/di=
nabkp/faouzis/local2/pgsql/share/contrib'
/bin/sh ../../config/install-sh -c -m 644 dblink.sql '/dinabkp/faouzi=
s/local2/pgsql/share/contrib'
gmake: Leaving directory `/dinabkp/faouzis/postgresql-9.0beta1/contri=
b/dblink'

2. I don't have records of the build logs for the regular postgres executab=
les (which contains the libpqwalreceiver) but can do a new compile/make if =
that is required. But they were compiled and installed using the regular ma=
ke files supplied along with the postgres source code. The following flags =
were added during the compilation:

--without-readline --without-zlib --enable-debug --enable-cassert --e=
nable-thread-safety

Thanks.

Alanoly.

-----Original Message-----
From: Robert Haas [mailto:robertmhaas@gmail.com]=20
Sent: Wednesday, August 11, 2010 10:13 AM
To: Heikki Linnakangas
Cc: Alanoly Andrews; pgsql-admin@postgresql.org; PostgreSQL-development
Subject: Re: [HACKERS] [ADMIN] postgres 9.0 crash when bringing up hot stan=
dby

On Fri, Aug 6, 2010 at 3:53 PM, Heikki Linnakangas
wrote:
> So, loading libpqwalreceiver library crashes. It looks like it might be
> pthread-related. Perhaps something wrong with our makefiles, causing
> libpqwalreceiver to be built with wrong flags? Does contrib/dblink work? =
If
> you look at the build log, what is the command line used to compile
> libpqwalreceiver, and what is the command line used to build other
> libraries, like contrib/dblink?

I haven't seen any response to this from the OP, but it seems
worrisome. Has anyone else tested a Hot Standby configuraration -
successfully or otherwise - on AIX?

--=20
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise Postgres Company
****************************************************
This e-mail may be privileged and/or confidential, and the sender does not =
waive any related rights and obligations. Any distribution, use or copying =
of this e-mail or the information it contains by other than an intended rec=
ipient is unauthorized. If you received this e-mail in error, please advise=
me (by return e-mail or otherwise) immediately.
=20
Ce courriel est confidentiel et prot=E9g=E9. L'exp=E9diteur ne renonce pas =
aux droits et obligations qui s'y rapportent. Toute diffusion, utilisation =
ou copie de ce message ou des renseignements qu'il contient par une personn=
e autre que le (les) destinataire(s) d=E9sign=E9(s) est interdite. Si vous =
recevez ce courriel par erreur, veuillez m'en aviser imm=E9diatement, par r=
etour de courriel ou par un autre moyen.
****************************************************


--=20
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Re: [HACKERS] postgres 9.0 crash when bringing up hot standby

am 11.08.2010 16:25:58 von Robert Haas

On Wed, Aug 11, 2010 at 10:20 AM, Alanoly Andrews wro=
te:
> Ok..in response to the questions from Heikki,
>
> 1. Yes, "contrib/dblink" does work. Here's the output from the command us=
ed to "make" dblink:
> =A0 =A0 =A0postgres:thimar> /usr/bin/gmake -C contrib/dblink install
> =A0 =A0 =A0gmake: Entering directory `/dinabkp/faouzis/postgresql-9.0beta=
1/contrib/dblink'
> =A0 =A0 =A0/bin/sh ../../config/install-sh -c -d '/dinabkp/faouzis/local2=
/pgsql/lib'
> =A0 =A0 =A0/bin/sh ../../config/install-sh -c -d '/dinabkp/faouzis/local2=
/pgsql/share/contrib'
> =A0 =A0 =A0/bin/sh ../../config/install-sh -c -m 755 =A0dblink.so '/dinab=
kp/faouzis/local2/pgsql/lib/dblink.so'
> =A0 =A0 =A0/bin/sh ../../config/install-sh -c -m 644 ./uninstall_dblink.s=
ql '/dinabkp/faouzis/local2/pgsql/share/contrib'
> =A0 =A0 =A0/bin/sh ../../config/install-sh -c -m 644 dblink.sql '/dinabkp=
/faouzis/local2/pgsql/share/contrib'
> =A0 =A0 =A0gmake: Leaving directory `/dinabkp/faouzis/postgresql-9.0beta1=
/contrib/dblink'

Unfortunately that only shows the install, not the link - it must have
been built earlier. Can you do "make clean" in that just that one
directory, and then "make install" again?

> 2. I don't have records of the build logs for the regular postgres execut=
ables (which contains the libpqwalreceiver) but can do a new compile/make i=
f that is required. But they were compiled and installed using the regular =
make files supplied along with the postgres source code. The following flag=
s were added during the compilation:
>
> =A0 --without-readline --without-zlib =A0 =A0--enable-debug --enable-cass=
ert --enable-thread-safety

It'd be nice to see the whole build log, if it's not too much trouble
to regenerate it.

--=20
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise Postgres Company

--=20
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Re: [HACKERS] postgres 9.0 crash when bringing up hot standby

am 12.08.2010 22:37:50 von Robert Haas

On Wed, Aug 11, 2010 at 10:25 AM, Robert Haas wrote:
> [request form more information]

Per off-list discussion with Alanoly, we've determined the following:

dblink was compiled with the same flags as libpqwalreciever
dblink works
libpqwalreceiver crashes

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise Postgres Company

--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Re: [HACKERS] postgres 9.0 crash when bringing up hot standby

am 12.08.2010 23:40:20 von Tom Lane

Robert Haas writes:
> Per off-list discussion with Alanoly, we've determined the following:

> dblink was compiled with the same flags as libpqwalreciever
> dblink works
> libpqwalreceiver crashes

I wonder if the problem is not so much libpqwalreceiver as the
walreceiver process. Maybe an ordinary backend process does some
prerequisite initialization that walreceiver is missing. Hard to
guess what, though ... I can't think of anything dlopen() depends on
that should be under our control.

regards, tom lane

--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Re: [HACKERS] postgres 9.0 crash when bringing up hot standby

am 12.08.2010 23:54:49 von Tom Lane

I wrote:
> I wonder if the problem is not so much libpqwalreceiver as the
> walreceiver process. Maybe an ordinary backend process does some
> prerequisite initialization that walreceiver is missing. Hard to
> guess what, though ... I can't think of anything dlopen() depends on
> that should be under our control.

Actually, that idea is easily tested: try doing
LOAD 'libpqwalreceiver';
in a regular backend process.

If that still crashes, it might be useful to truss or strace the backend
while it runs the command, and compare that to the trace of
LOAD 'dblink';

regards, tom lane

--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Re: [HACKERS] postgres 9.0 crash when bringing up hot standby

am 13.08.2010 17:11:19 von Robert Haas

On Thu, Aug 12, 2010 at 5:54 PM, Tom Lane wrote:
> I wrote:
>> I wonder if the problem is not so much libpqwalreceiver as the
>> walreceiver process. =A0Maybe an ordinary backend process does some
>> prerequisite initialization that walreceiver is missing. =A0Hard to
>> guess what, though ... I can't think of anything dlopen() depends on
>> that should be under our control.
>
> Actually, that idea is easily tested: try doing
> =A0 =A0 =A0 =A0LOAD 'libpqwalreceiver';
> in a regular backend process.

Alanoly, is this something you can try?

> If that still crashes, it might be useful to truss or strace the backend
> while it runs the command, and compare that to the trace of
> =A0 =A0 =A0 =A0LOAD 'dblink';

And if necessary, this too?

Thanks for your help debugging this....

--=20
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise Postgres Company

--=20
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin