Thread: Fwd: Re: Complete breakdown of pgadmin when trying to connect to server or modify properties of tables of views

Hi Dave,

Once more my mail from yesterday. It was stalled by the admin - I suppose 
because of the attached log file mentioned above. If you wish I could send it 
to your private mail address...
Now the answer from yesterday:

Many thanks for quick answer!

> - Run pgAdmin from the command line, with a command like:
>  G_SLICE=always-malloc pgadmin3 &
This works fine 

> - Recompile pgAdmin.
That's what I tried, too. Sorry, forgot to mention it. I downloaded the 
source-rpm for my distribution and installed it. Controlling all the 
requirements mentioned in the INSTALL file I found installed
GTK 2.12.5
automake 1.9.6
autoconf 2.60
gcc 4.1.3

wxGTK 2.6.8
libxml2 2.6.30
libxslt  1.1.22
Postgresql 8.1.11
So I thought that all requirements were fullfilled and I tried to compile it 
with rpmbuild but unfortunately it stopped at the first step (suppose the 
configure-process). The error message was:

checking for C compiler default output file name... configure: error: C 
compiler cannot create executables
See `config.log' for more details.

Attached you find the config.log. Perhaps it helps to determine the problem...
Michael


-------------------------------------------------------


Hi Michael

On Sat, Mar 8, 2008 at 9:23 AM, Michael Eschweiler
<Michael.Eschweiler@t-online.de> wrote:
> Hi Dave,
>
> Once more my mail from yesterday. It was stalled by the admin - I suppose
> because of the attached log file mentioned above. If you wish I could send it
> to your private mail address...

You're welcome to CC me on any replies - in fact thats the custom on
these lists. However, as I am the list admin I have seen and released
your message, it just didn't get to the top of my todo list until now
:-)

> Many thanks for quick answer!

You're welcome.

> > - Run pgAdmin from the command line, with a command like:
> >  G_SLICE=always-malloc pgadmin3 &
> This works fine

Good, so we have a workaround and know for sure what the problem is.

> > - Recompile pgAdmin.
> That's what I tried, too. Sorry, forgot to mention it. I downloaded the
> source-rpm for my distribution and installed it. Controlling all the
> requirements mentioned in the INSTALL file I found installed

Did you compile wxwidgets your self, or is that a package for Suse
10.2? It's quite probable that needs to be recompiled against the
newer GTK libraries as well (sorry, didn't cross my mind yesterday)

> checking for C compiler default output file name... configure: error: C
> compiler cannot create executables
> See `config.log' for more details.

That's a standard configure test that's failing. The important part of
the log is this:

configure:2279: checking for C compiler default output file name
configure:2282: gcc -O2 -g -m32 -march=i586 -mtune=i686
-fmessage-length=0 -D_FORTIFY_SOURCE=2   conftest.c -lldap >&5
/usr/lib/gcc/i586-suse-linux/4.1.2/../../../../i586-suse-linux/bin/ld:
cannot find -lldap
collect2: ld returned 1 exit status
configure:2285: $? = 1
configure: failed program was:
| /* confdefs.h.  */
|
| #define PACKAGE_NAME "pgadmin3"
| #define PACKAGE_TARNAME "pgadmin3"
| #define PACKAGE_VERSION "1.8.2"
| #define PACKAGE_STRING "pgadmin3 1.8.2"
| #define PACKAGE_BUGREPORT "pgadmin-support@postgresql.org"
| #define PACKAGE "pgadmin3"
| #define VERSION "1.8.2"
| /* end confdefs.h.  */
|
| int
| main ()
| {
|
|   ;
|   return 0;
| }
configure:2324: error: C compiler cannot create executables


Basically it's trying to compile the very short program shown and
failing with the error:

/usr/lib/gcc/i586-suse-linux/4.1.2/../../../../i586-suse-linux/bin/ld:
cannot find -lldap

That appears to be because further down in the log we see the LIBS
variable is set to -lldap which causes the linker to try to import
libldap.. I don't know why that is the case - it's certainly not
something pgAdmin does. I would clear the variable, and try again. If
you find it's being set by rpmbuild, try installing libldap - it won't
hurt pgAdmin.

-- 
Dave Page
EnterpriseDB UK Ltd: http://www.enterprisedb.com
PostgreSQL UK 2008 Conference: http://www.postgresql.org.uk


Hi,

> Did you compile wxwidgets your self, or is that a package for Suse
> 10.2? It's quite probable that needs to be recompiled against the
> newer GTK libraries as well (sorry, didn't cross my mind yesterday)
No, I tried it with the package provided by opensuse, but now I compiled it 
myself (The wx-GTK part)
>
> That appears to be because further down in the log we see the LIBS
> variable is set to -lldap which causes the linker to try to import
> libldap.. I don't know why that is the case - it's certainly not
> something pgAdmin does. I would clear the variable, and try again. If
> you find it's being set by rpmbuild, try installing libldap - it won't
> hurt pgAdmin.
Ok - I installed some openldap-packages hoping this would solve the problem.
Then I tried to compile once more and found that the compiler was mixing up 
the newer libc library with an older one I had installed. So I uninstalled 
the older libc library. 
Now the configure procedure ends up reclaiming: 
configure: error: Could not find your PostgreSQL installation 
in /usr/local/pgsql
error: Bad exit status from /var/tmp/rpm-tmp.89311 (%build)

My Postgresql installation is the standard installation with the packages 
provides from opensuse - with one exception: For easier backup purposes i 
changed the data-directory to /home/pgsql. Nevertheless with the postgresql 
installation from opensuse there is no directory /usr/local/psql, I think the 
main directories are

/usr/lib (for some libraries)
/usr/lib/postgresql
/var/lib/psql (the original 'home directory for the postgres admin)
/usr/include/pgsql (the devel package)

So I tried to change the psql directory in the pgadmin3.conf but configure 
keeps on complaining that it can't find my Postgresql installation. When 
looked into the pgadmin3.conf I found the line --with-wx=/usr/local/wxwindows
I wonder if there is lurking another problem because I didn't find the 
directory 'wxwindows' on my machine. Is this because I need something more 
than the wx-GTK?

Sorry for this larger explanation. I am only a 'normal' user without greater 
programming skills...

Michael

> --
> Dave Page
> EnterpriseDB UK Ltd: http://www.enterprisedb.com
> PostgreSQL UK 2008 Conference: http://www.postgresql.org.uk




On Sun, Mar 9, 2008 at 5:04 PM, Michael Eschweiler
<Michael.Eschweiler@t-online.de> wrote:
> > Can you find the pg_config and wx-config programs on your machine?
>  > Where are they?
>  I found them:
>  /usr/bin/pg_config
>  /usr/local/bin/wx-config

OK, so try running configure with something like the following options:

./configure --with-pgsql=/usr --with-wx=/usr/local

If it still cannot find PostgreSQL (or wxWidgets), perhaps you need to
install some -dev packages to get the headers and libraries?

Of course an easier option would be to use Redhat or CentOS :-p

-- 
Dave Page
EnterpriseDB UK Ltd: http://www.enterprisedb.com
PostgreSQL UK 2008 Conference: http://www.postgresql.org.uk


First I tried once more with 

> ./configure --with-pgsql=/usr --with-wx=/usr/local

but configure now stops with:

checking for strchr... yes
checking for PQexec in libpq.a... present
checking for SSL_connect in libpq.a... present
checking for krb5_free_principal in libpq.a... present
checking libpq-fe.h usability... yes
checking libpq-fe.h presence... yes
checking for libpq-fe.h... yes
checking PostgreSQL in /usr... ok
checking for PQgetOutResult in libpq.a... not present
checking wxWidgets version... ok
checking wxWidgets in /usr/local... failed
configure: error: Your wxWidgets installation cannot support pgAdmin in the 
sele
cted configuration. This may be because it was configured without 
the --enable-u
nicode option, or the combination of dynamic/static linking and 
debug/non-debug
libraries selected did not match any installed wxWidgets libraries.
error: Bad exit status from /var/tmp/rpm-tmp.39796 (%build)
>
> If it still cannot find PostgreSQL (or wxWidgets), perhaps you need to
> install some -dev packages to get the headers and libraries?

I compiled the wxWidgets with the -enable-unicode option. Therefore I followed 
your advice and controlled if the devel packages are installed.
The postgresql- and gtk2-devels are installed but as I compiled the wxWidget 
from the tarball I think the sources of this package are not (and I didn't 
install the devel from the distribution because I suppose that there would be 
some considerable differences). 
As I don't know how to install sources from a tarball I tried to create a 
source.rpm in order to install it but then configure complained:

error: Failed build dependencies: gtk+-2.0-devel is needed by 
wx-gtk2-unicode-2.8.7-0.i586

although gtk2-devel is installed. Sorry, but I must confess that this is going 
beyond my installation-skills...
>
> Of course an easier option would be to use Redhat or CentOS :-p
For pgadmin I suppose this is right, but recently I tried Fedora 8 and for 
other purposes I found some inconveniences so I decided to stick to OSS...
I never tried seriously other distributions because of lack of time. 
Michael


On Tue, Mar 11, 2008 at 2:10 PM, Michael Eschweiler
<Michael.Eschweiler@t-online.de> wrote:

> I compiled the wxWidgets with the -enable-unicode option. Therefore I followed
> your advice and controlled if the devel packages are installed.
> The postgresql- and gtk2-devels are installed but as I compiled the wxWidget
> from the tarball I think the sources of this package are not (and I didn't
> install the devel from the distribution because I suppose that there would be
> some considerable differences).
> As I don't know how to install sources from a tarball I tried to create a
> source.rpm in order to install it but then configure complained:

A simple 'make install' will install the right bits of wxWidgets. In
fact, if you're building your own anyway, you can just follow all the
pgAdmin build instructions and it should do everything you need - just
just in the 'rpm way'.

> error: Failed build dependencies: gtk+-2.0-devel is needed by
> wx-gtk2-unicode-2.8.7-0.i586
>
> although gtk2-devel is installed. Sorry, but I must confess that this is going
> beyond my installation-skills...


> > Of course an easier option would be to use Redhat or CentOS :-p
> For pgadmin I suppose this is right, but recently I tried Fedora 8 and for
> other purposes I found some inconveniences so I decided to stick to OSS...
> I never tried seriously other distributions because of lack of time.
> Michael

Yeah, I wasn't seriously suggesting you change OS just for pgAdmin :-)

Unfortunately though, Suse seems to be the one RPM based linux distro
where a) we don't have anyone building packages and b) things never
seem to go smoothly :-(


-- 
Dave Page
EnterpriseDB UK Ltd: http://www.enterprisedb.com
PostgreSQL UK 2008 Conference: http://www.postgresql.org.uk


Without wanting to start a religious debate on the merits of various 
Linux distro's, I'm still going to ask the subjective question, which is 
probably a recurring one, and perhaps not suitable for this forum.

Which Linux distro's support Postgres releases the best?  Which are best 
suited in a server vs. development suite of tools? 

Somewhat related but off on a tangent, for at least the last year up 
until the purchase of MySQL, Sun has been championing Postgres on their 
recently opened sourced Solaris OS.  I do not appreciate what the extent 
of Sun's support of the Postgres community has been, but a presentation 
I attended last year seemed to indicate that they were doing quite a bit 
in performance and profiling enhancements, particularly in tuning the DB 
to the Solaris OS.

How does Solaris with Postgres stack up against the various Linux 
distro's with Postgres?  Also, will Sun as far as anyone is aware of 
their intentions, continue to have the same level of interest in 
Postgres following the MySQL acquisition?  And will they continue to 
champion Postgres like they had been doing over the previous twelve months?

Cheers,

Andy


Dave Page wrote:
> Yeah, I wasn't seriously suggesting you change OS just for pgAdmin :-)
>
> Unfortunately though, Suse seems to be the one RPM based linux distro
> where a) we don't have anyone building packages and b) things never
> seem to go smoothly :-(
>
>
>   



> Which Linux distro's support Postgres releases the best?  Which are best 
> suited in a server vs. development suite of tools?

Andrew, I've always had excellent luck with CentOS, which is a clone of 
RedHat Enterprise Linux.  The RPM's for RHEL that you find on the Postgres 
website drop right in without issue.

http://www.centos.org

Cheers,
-J



Andrew,

We've had zero problems with a highly-customized (optimized) Fedora 6
distro.
That server serves 1000's of requests per minute and still performant.
We've also used it with FC7 and 8 with no issues whatsoever...
Josh is right: those RPMs sink right in... ;-) (although we've
recompiled pgsql)

Regards,
Pedro.

On Tue, 2008-03-11 at 22:53 -0400, Josh wrote:
> > Which Linux distro's support Postgres releases the best?  Which are best
> > suited in a server vs. development suite of tools?
>
> Andrew, I've always had excellent luck with CentOS, which is a clone of
> RedHat Enterprise Linux.  The RPM's for RHEL that you find on the Postgres
> website drop right in without issue.
>
> http://www.centos.org
>
> Cheers,
> -J
>
>

On Wed, 12 Mar 2008 02:18:45 pm Pedro Doria Meunier wrote:
> Andrew,
>
> We've had zero problems with a highly-customized (optimized) Fedora 6
> distro.
> That server serves 1000's of requests per minute and still performant.
> We've also used it with FC7 and 8 with no issues whatsoever...
> Josh is right: those RPMs sink right in... ;-) (although we've
> recompiled pgsql)
>
> Regards,
> Pedro.
>
> On Tue, 2008-03-11 at 22:53 -0400, Josh wrote:
> > > Which Linux distro's support Postgres releases the best?  Which are
> > > best suited in a server vs. development suite of tools?
> >
> > Andrew, I've always had excellent luck with CentOS, which is a clone of
> > RedHat Enterprise Linux.  The RPM's for RHEL that you find on the
> > Postgres website drop right in without issue.
> >
> > http://www.centos.org
> >
> > Cheers,
> > -J

Similarly, no problems with postgresql over the last four years on Mandriva, 
pclos and fedora. Runnng on various architectures on dev test and prod. Must 
recommend local compilation of pgadmin3, if you use it, on any distro though.  

-- 
regards

Bruce


Hi,

On Wed, 2008-03-12 at 13:27 +1100, Andrew wrote:

> Which Linux distro's support Postgres releases the best?  Which are
> best  suited in a server vs. development suite of tools?

"Best" is a bit debatable, but Ubuntu/Debian and Fedora/RHEL/CentOS have
very good PostgreSQL support. I'm using both of these, and both sides
are doing good jobs.

Debian packaging project:

http://pkg-postgresql.alioth.debian.org/

For Fedora/RHEL/CentOS, there is an RPM repository that you can find 25+
PostgreSQL related package for any supported Fedora/RHEL/CentOS release
+PostgreSQL release combinations.

http://yum.pgsqlrpms.org

Regards,
--
Devrim GÜNDÜZ , RHCE
PostgreSQL Replication, Consulting, Custom Development, 24x7 support
Managed Services, Shared and Dedicated Hosting
Co-Authors: plPHP, ODBCng - http://www.commandprompt.com/

On Wed, Mar 12, 2008 at 8:09 AM, Devrim GÜNDÜZ <devrim@commandprompt.com> wrote:
> Hi,
>
>
>  On Wed, 2008-03-12 at 13:27 +1100, Andrew wrote:
>
>  > Which Linux distro's support Postgres releases the best?  Which are
>  > best  suited in a server vs. development suite of tools?
>
>  "Best" is a bit debatable, but Ubuntu/Debian and Fedora/RHEL/CentOS have
>  very good PostgreSQL support. I'm using both of these, and both sides
>  are doing good jobs.

Ubuntu is the distro that we have the most problems with pgAdmin on.
Apparently there have been distro-specific patches applied to
wxWidgets in the past which haven't played well. It seems better
recently though.

Both the latest Suse and Ubuntu introduce changes in GTK which will
cause pgAdmin to crash if wxWidgets was built against an older version
of GTK. That can be fixed either by recompiling against the new
llbraries, or setting an environment variable which tells GTK to work
the old way. I expect to see this issue in other distros in the
not-to-distant-future.

Personally, I'm using Slackware, Fedora 7 and CentOS 5.1, though I
don't run any production systems these days. Most of my work is on
Windows XP and Mac OS X though.

--
Dave Page
EnterpriseDB UK Ltd: http://www.enterprisedb.com
PostgreSQL UK 2008 Conference: http://www.postgresql.org.uk


On Wednesday 12 March 2008, Dave Page wrote:
> On Wed, Mar 12, 2008 at 8:09 AM, Devrim GÜNDÜZ <devrim@commandprompt.com>
wrote:
> > Hi,
> >
> >
> >  On Wed, 2008-03-12 at 13:27 +1100, Andrew wrote:
> >
> >  > Which Linux distro's support Postgres releases the best?  Which are
> >  > best  suited in a server vs. development suite of tools?
> >
> >  "Best" is a bit debatable, but Ubuntu/Debian and Fedora/RHEL/CentOS
have
> >  very good PostgreSQL support. I'm using both of these, and both sides
> >  are doing good jobs.
>
> Ubuntu is the distro that we have the most problems with pgAdmin on.
> Apparently there have been distro-specific patches applied to
> wxWidgets in the past which haven't played well. It seems better
> recently though.
>
> Both the latest Suse and Ubuntu introduce changes in GTK which will
> cause pgAdmin to crash if wxWidgets was built against an older version
> of GTK. That can be fixed either by recompiling against the new
> llbraries, or setting an environment variable which tells GTK to work
> the old way. I expect to see this issue in other distros in the
> not-to-distant-future.
>
> Personally, I'm using Slackware, Fedora 7 and CentOS 5.1, though I
> don't run any production systems these days. Most of my work is on
> Windows XP and Mac OS X though.
>
> --
> Dave Page
> EnterpriseDB UK Ltd: http://www.enterprisedb.com
> PostgreSQL UK 2008 Conference: http://www.postgresql.org.uk

I am new in December to the Postgres/pgadmin suite and have been running
both on SuSE 10.0 and 10.3.  The RPM's for Postgres I have had no problems
with, and the recent 8.2.6 security update came through the SuSE update
service without incident on 10.3.  I have never bothered with RPM's for
pgadmin3 because I have no trouble compiling and installing it, so I
always get a more recent version.

I would like the opportunity to give this list a little background on how
we got where we are, through one set of eyes.

I am, I suppose at this point in my 53 year life, "Old School", having cut
my teeth on Microlite Unix in '86 (AT&T man pages were the only
documentation) followed by SCO Unix.  After I learned Unix, I was exposed
to MS-DOS, and needless to say it came across as trivially easy.  MS-DOS
was the last operating system that "they" marketed that worked well, and
they didn't even develop the core package.  In May of 2001, a vice
president of Microsoft declared war on the free software movement when
Linux had hit a deeply threatening 1% market share.  On the day I learned
of this, my Win95 box was retired and I installed Caldera Linux and have
not looked back.  When Caldera went away I chose SuSE for its superior
documentation and have frankly not look seriously at other distros because
it proverbially does what I need ... everything.

Many of you people out there on this list are using any of many variants of
Linux.  Each distribution of Linux is like a priceless jewel in the crown
of human cooperation, cooperation that you have few other models for in
this world.  By all means, debate the merit of each distribution, but I
must say that Linux is the most beautiful thing that ever happened to
computing, and if your distro has trouble with a widget, there will be a
fix soon.

I feel greatly enriched since I discovered Postgres and pgadmin and what is
to me a new programming paradigm of putting the business logic in the
database.  Everytime I download one of these freely available packages, I
marvel.

Arthur Knight Hammer