Cannot find PGXS for Postgresql 8.4 on Ubuntu - postgresql

I am trying to install the contrib/unaccent package for Postgresql 8.4 on my Ubuntu box. But I got the error message when I typed make:
/usr/lib/postgresql/8.4/lib/pgxs/src/makefiles/pgxs.mk: No such file or directory
Apparently PGXS is Postgresql's infrastructure for installing extensions, but I could not find the file pgxs.mk at all on my ubuntu box.
Following some leads on the Internet, I tried installing libpq-dev. Nonetheless, I couldn't find any pgxs.mk even after installing libpq-dev.
What's really frustrating is that I can't even find an example of pgxs.mk anywhere on the Internet. How do I install the PGXS infrastructure?

Probably you need to install postgresql-server-dev-8.4 package, which contains your missing makefile:
/usr/lib/postgresql/8.4/lib/pgxs/src/makefiles/pgxs.mk

Related

Postgresql 12 doesn´t find PostGIS extension on CentOS 8

I´m trying to get PostGIS working, but it seems that Postgresql doesn´t find the extension. My server is running on CentOS 8, the Postgresql is version 12. I installed Postgresql 12 first via dnf module enable postgresql:12 etc..
Afterwards I installed PostGIS and followed the description on the PostGIS website (https://people.planetpostgresql.org/devrim/index.php?/archives/102-Installing-PostGIS-3.0-and-PostgreSQL-12-on-CentOS-8.html). But when I try to run CREATE EXTENSION postgis; I get the error ERROR: could not access file "$libdir/postgis-3": No such file or directory SQL state: 58P01 I figured out that the needed files reside in a subdirectory "bitcode". Therefore I tried to symlink the content in the $libdir directory above - but didn´t help. Even copying them in the directory didn´t - same error. What am I missing?
Thank you and best regards,
Goetz
You have a mix of packages installed: Some from the CentOS distribution, some from the PostgreSQL site. That will lead to trouble.
Uninstall the PostgreSQL packages that do not have PGDG in them and make sure to disable them as shown in the link you show. Then install the PGDG packages for PostGIS

Freeradius 3.0.11 Postgresql

I'm trying to configure freeradius 3.0.11 with postgresql but I'm having an issue with the driver listed in the sql file inside of 'mods-enabled.' The driver I am listing is 'rlm_sql_postgresql.'
When I run 'radiusd -X' I get the error:
Could not link driver rlm_sql_postgresql: dlopen(/usr/local/Cellar/freeradius-
server/3.0.11/lib/rlm_sql_postgresql.dylib, 6): image not found
Make sure it (and all its dependent libraries!) are in the search path of your system's ld
/usr/local/Cellar/freeradius-server/3.0.11/etc/raddb/mods-enabled/sql[20]: Instantiation failed for module "sql"
When I look in the folder 3.0.11/lib there is indeed no such file called rlm_sql_postgresql.dylib.
Any ideas on this? Should I be generating this file somehow?
It means when configure was run for freeradius, it didn't pick up libpq.
Apparently brew install postgresql will pull down libpq and its development headers.
Remove freeradius, install postgresql, install freeradius with brew install --build-from-source freeradius-server
It should (unless the homebrew people have gone out of their way to break things), install the postgresql driver.

ImportError: /lib/libc.so.6: version `GLIBC_2.14' not found (required by /usr/lib/libpq.so.5)

I have to run a tornado webapp on a server using psycopg2 with postgresql as backend. I am working on Red Hat Enterprise Linux Server release 6.5. I set up a virtual environment. Now, on this server, i don't have root access, i can't use pip or yum and i can't copy text from the server(so i can't post the exact error log). I have been manually downloading tar files for the libraries and installing them. When i try to run the webapp, i get the following error:
ImportError: /lib/libc.so.6: version `GLIBC_2.14' not found (required by /usr/lib/libpq.so.5)
The version for libc.so.6 is 2.12. The error is displayed in psycopg2/init.py.
I apologize as this is not much to go on, but the server has a lot of restrictions. Any help will be appreciated.
This error:
ImportError: /lib/libc.so.6: version `GLIBC_2.14' not found \
(required by /usr/lib/libpq.so.5)
means that libpq.so.5 was built on a system with GLIBC-2.14 or above.
Since you claim to not have root privilege on this system, and since /usr/lib is not writable by regular users, we must assume that you've asked the sysadmin on this system to install something for you, and the sysadmin installed a non-working PostgreSQL package.
There is no easy way you can fix this problem yourself.
You should work with your sysadmin to install correct packages for your system.
Alternatively, you can build install and use a newer version of GLIBC in non-default location. This is quite non-trivial. Some details here.

Postgis - Failed to install it on linux mint mate 17

I install postgis via sudo apt-get install postgis postgresql-9.3-postgis-2.1
Then execute CREATE EXTENSION postgis; but got following error tip:
ERROR: could not load library "/usr/lib/postgresql/9.3/lib/postgis-2.1.so":
/usr/lib/postgresql/9.3/lib/postgis-2.1.so: undefined symbol: HeapTupleHeaderGetDatum
I am using postgresql 9.3.4, and postgis-2.1.
I did google for over an hour, but didn't found a solution that really solve my issue.
Any help?
I spend another hour, and finally tried to install it from source code, and succeed like a charm, no single issue occur!
Here is the link provide detail steps to install postgis from source code:
http://trac.osgeo.org/postgis/wiki/UsersWikiPostGIS21Ubuntu1404src
It also works for my Linux mint mate 17, which is base on ubuntu 14.04.
The first two hits seem to say basically the same thing to me:
http://www.postgresql.org/message-id/A9A6BC42-D2E2-471B-BFB0-F6A72EF42911#conundrum.com
https://github.com/pgRouting/pgrouting/issues/271
It sounds to me like your version of postgis was built against a version of postgresql later than 9.3.4 which included a bugfix that included "HeapTupleHeaderGetDatum". So - upgrade your postgresql (you do have something more recent than .4?) and/or make sure you get postgis from the same repo as your postgresql packages.
See if that helps.

Problems installing/compiling DBD::mysql on OpenSuSE 10

I am getting a bunch of compile errors when I try to install the MySQL DBD::mysql Perl library. I am trying to install this library on OpenSuse linux (SUSE Linux Enterprise server 10 (x86_64) version 10, patch level 4)
The install fails when trying to compile dbdimp.h. There are hundreds of complile errors but I have reason to believe they all stem from the first 3:
dbdimp.h:23:49: error: mysql.h: No such file or directory
dbdimp.h:24:45: error: mysqld_error.h: No such file or directory
dbdimp.h:26:49: error: errmsg.h: No such file or directory
I believe that the reason I am getting the errors above is that I have no MySql Client installed. I do not know how to install mysql client (I believe I am supposed to get some version of libmysqlclient).
I am brand new to opensuse and vaguely familar with installing packages on Linux in general have used yum, yast, apt-get on ubuntu + centOS previously but the only package manager tools that seem to be on OpenSuse 10 are rpm and zypper. I have not managed to install the required mysql client using either of these. If anyone knows how to install MySql Client to resolve my issue I would greatly appreciate any recomendations
Thanks
You need to install MySQL or the MySQL client libraries, either through your system's package manager or by following the installation instructions from the source code.
It sounds like your question is really "How do I install MySQL on OpenSuse", which would be more appropriate for one of the other StackExchange sites.
I was able to resolve this to a point. In my original question, I stated that I had tried using YAST but that it had not worked. In fact, I did not fully explore the YAST install option but when I did, I managed to download install the required librarys by following an article I found (http://adminramble.com/install-mysql-yast/#chitika_close_button)
I was able to open the YAST GUI in the terminal window (not an X-window display) and navigate through the "software management" section wherein I was able to do a search for MySql. Amoung the search results were mysql client libraries, which I then selected and hit "Accept". The installation started and completed successully.
In order to complile the PERL DBD::mysql module, I had to create a new makefile with the ccflags specified so that the header files could be found:
perl Makefile.PL --cflags -I/usr/include/mysql
I say "to a point" at the top of this comment because I then ran into further problems compiling but my original issue posted has been partially resolved and getting this far may help someone else who is experiencing the same problem. Will update if I get a solution to the compile problem.