Search Postgresql Archives

Re: Initdb panic: invalid record offset at 0/0 creating template1]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



DANTE ALEXANDRA <ALEXANDRA.DANTE@xxxxxxxx> writes:
> We have generated a new rpm as we haven't found a 8.1.0 rpm for IA-64 on 
> Red Hat Enterprise Linux 4 on the PostGreSQL web site. We have compiled 
> PostGreSQL v8.1.0 and generated the rpm with the intel compiler "icc".
> In the spec file, we have used these options for ./configure :
> ./configure CC=/opt/intel_cc_80/bin/icc CFLAGS="-no-gcc -O2 -w 
> -ansi_alias -D__ICC".

Do you know that this compiler generates trustworthy code with those
options?  The contents of the pg_control file are clearly good according
to the dump from pg_controldata, and yet we have

> LOG:  invalid primary checkpoint link in control file
> PANIC:  invalid record offset at 0/0

The easiest explanation I can see for this is that the compiler has
gotten the XRecOffIsValid test at the top of ReadCheckpointRecord
(in src/backend/access/transam/xlog.c, line 4854 as of 8.1.2) backwards.
The first time through, with the perfectly valid primary checkpoint
location (0/20) it mistakenly decides the value is not valid and prints
the LOG message.  This leads to a second call with the invalid prior
checkpoint location (0/0), when it mistakenly falls through and calls
ReadRecord, which properly PANICs.  Given that ReadRecord is using the
exact same macro to decide the offset is invalid (line 2668), it's hard
to conclude anything except a compiler bug.

			regards, tom lane


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux