0

I need to install the unaccent extension in a postgresql server 9.0.8 running over a RHEL6 box which doesn't have the contrib package. So I need to install postgresql-crontrib first.

Facts:

  • Server doesn't have internet access so the yum option from the server is not available.
  • I couldn't find the proper rpm package (and its dependencies for postgresql 9.0.8 and RHEL6) on internet to download.
  • I found other versions of the that require newer versions of postgresql and an upgrade is no-go.
  • Server is in production and we can't upgrade it.

Thanks

Luke
  • 121
  • 3

1 Answers1

2

You can grab the source code for 9.0.8, then install the module from source:

tar xf postgresql-9.0.8.tar.gz
cd postgresql-9.0.8/contrib/unaccent
PATH=/usr/bin/pgsql-9.0/bin:$PATH make USE_PGXS=1
sudo PATH=/usr/bin/pgsql-9.0/bin:$PATH make USE_PGXS=1 install

Of course this requires the correct headers to be present, in particular the postgresql-devel package. If it isn't, then you're stuffed, this is a social problem not a technical one.

Preventing DB servers from having at least on-request Internet access for updates, or at least a local yum mirror, is the height of stupidity in policy. It prevents you from patching your server to update to new important bug fix releases that might fix potential data integrity issues. This is a fight you need to take up with your networking team, and not take no for an answer. Demand at least a yum mirror of RHEL's repos and of yum.postgresql.org, or (better) access to a restricted HTTP proxy srever.

Craig Ringer
  • 11,083
  • 9
  • 40
  • 61
  • Well, as expected, I've no such package (`postgresql-devel`). I'll reach IT guys but I think that I'll not have good news about that (they're a large finance company). – Luke Aug 15 '14 at 16:33
  • Well, then it's time to start bringing package files in on USB keys. – Craig Ringer Aug 15 '14 at 16:54
  • Yes, that's the way I was trying to do, but the main issue is that I couldn't find the `postgres-contrib` package for `postgresql 9.0.8` and `RHEL6` over internet. – Luke Aug 15 '14 at 17:18
  • @Luke Ouch, good point, RHEL packages aren't just easily grabbed. God install media anywhere? Otherwise, it's back to plan A: "educating" your company's woefully misguided networking staff. – Craig Ringer Aug 15 '14 at 17:35