Обсуждение: Floating point exception in initdb
Hello Guys,
I am getting an floating exception while running initdb from custom built postgresql . I am using suse linux for installing postgresql.
initDB.sh: line 14: 20285 Floating point exception$pgsql_home/bin/initdb -A password -U postgres --pwfile="pwFile" -E UTF8 -D postgresql/data /log/initDB.log
--Warning. PostgreSQL database can't be initialized successfully, please manually create schema or migrate encyclopedia DB after initialized the
Same thing works on redhat machine without any issues.Following link says:
Work around gcc bug that causes "floating-point exception" instead of "division by zero" on some platforms (Tom)
http://www.postgresql.org/docs/8.4/static/release-8-4-1.html
I am not able to located description about this bug. Please also let me know where I can look at this bug description
Thanks & Regards,
Vikram
"Vikram Patil" <vpatil@actuate.com> writes: > I am getting an floating exception while running initdb from custom > built postgresql . I am using suse linux for installing postgresql. > initDB.sh: line 14: 20285 Floating point exception$pgsql_home/bin/initdb > -A password -U postgres --pwfile="pwFile" -E UTF8 -D postgresql/data > /log/initDB.log Hm, dunno what's causing that ... > Work around gcc bug that causes "floating-point exception" instead of > "division by zero" on some platforms (Tom) ... but I'm quite sure that patch won't fix it for you, because it was in code that wouldn't get executed during initdb. What compiler are you using, for what hardware? Did you use any nondefault configure or compiler switches? Have you modified the Postgres sources at all? Which step of initdb gets the failure? Try running that step under gdb so you can get a stack trace pointing at the failure location. regards, tom lane
Thanks for reply Tom. I am having source code form 8.4.1 version which is released on 09-09-2009. I was able to install it on Redhat machine without any issues. But I am facing this issue while running initdb on Suse Ent. 9 machine.( Linux 2.6.5-7.97-smp #1 SMP Fri Jul 2 14:21:59 UTC 2004 i686 i686 i386 GNU/Linux ) Source code was compiled in following environment: Gcc : version 4.1.2 20071124 (Red Hat 4.1.2-42) Kernel Version: 2.6.18-8.el5 #1 SMP With Configure string: ./configure --prefix=$BIN_DIR --without-zlib --without-readline I built debug build using CFLAGS="-g" for configuring and now trying to step through for finding failure location. Thanks & Regards, Vikram -----Original Message----- From: Tom Lane [mailto:tgl@sss.pgh.pa.us] Sent: Monday, March 29, 2010 4:45 PM To: Vikram Patil Cc: pgsql-general@postgresql.org Subject: Re: [GENERAL] Floating point exception in initdb "Vikram Patil" <vpatil@actuate.com> writes: > I am getting an floating exception while running initdb from custom > built postgresql . I am using suse linux for installing postgresql. > initDB.sh: line 14: 20285 Floating point exception$pgsql_home/bin/initdb > -A password -U postgres --pwfile="pwFile" -E UTF8 -D postgresql/data > /log/initDB.log Hm, dunno what's causing that ... > Work around gcc bug that causes "floating-point exception" instead of > "division by zero" on some platforms (Tom) ... but I'm quite sure that patch won't fix it for you, because it was in code that wouldn't get executed during initdb. What compiler are you using, for what hardware? Did you use any nondefault configure or compiler switches? Have you modified the Postgres sources at all? Which step of initdb gets the failure? Try running that step under gdb so you can get a stack trace pointing at the failure location. regards, tom lane
"Vikram Patil" <vpatil@actuate.com> writes: > Thanks for reply Tom. I am having source code form 8.4.1 version which > is released on 09-09-2009. > I was able to install it on Redhat machine without any issues. But I am > facing this issue while running initdb on Suse Ent. 9 machine.( Linux > 2.6.5-7.97-smp #1 SMP Fri Jul 2 14:21:59 UTC 2004 i686 i686 i386 > GNU/Linux ) > Source code was compiled in following environment: > Gcc : version 4.1.2 20071124 (Red Hat 4.1.2-42) > Kernel Version: 2.6.18-8.el5 #1 SMP [ squint... ] This isn't totally clear, but are you saying you compiled on some semi-recent Red Hat platform and are trying to run the resulting executables on an old SUSE platform? I wouldn't really expect that to work. glibc's API changes from time to time. Would be better to compile on the same release you're planning to run on. regards, tom lane
Tom, Thanks for guidelines. I checked glibc versions. I am currently using glibc libarary 2.3.3 on SUSE platform while build machine I used has glibc library 2.5 . I will try to install it on SUSE machine with glibc library 2.5. Thanks & Regards, Vikram -----Original Message----- From: Tom Lane [mailto:tgl@sss.pgh.pa.us] Sent: Monday, March 29, 2010 5:29 PM To: Vikram Patil Cc: pgsql-general@postgresql.org Subject: Re: [GENERAL] Floating point exception in initdb "Vikram Patil" <vpatil@actuate.com> writes: > Thanks for reply Tom. I am having source code form 8.4.1 version which > is released on 09-09-2009. > I was able to install it on Redhat machine without any issues. But I am > facing this issue while running initdb on Suse Ent. 9 machine.( Linux > 2.6.5-7.97-smp #1 SMP Fri Jul 2 14:21:59 UTC 2004 i686 i686 i386 > GNU/Linux ) > Source code was compiled in following environment: > Gcc : version 4.1.2 20071124 (Red Hat 4.1.2-42) > Kernel Version: 2.6.18-8.el5 #1 SMP [ squint... ] This isn't totally clear, but are you saying you compiled on some semi-recent Red Hat platform and are trying to run the resulting executables on an old SUSE platform? I wouldn't really expect that to work. glibc's API changes from time to time. Would be better to compile on the same release you're planning to run on. regards, tom lane