[PORTS] AIX Permission weirdness

Chris Browne <[email protected]>
Newsgroups gmane.comp.db.postgresql.ports
Organization cbbrowne Computing Inc
Message-ID <[email protected]>
In the interests of helping others that might run into this, and so
that if we ever Google for this, we may find it...  :-)

We recently ran into fairly weird regressions on AIX.  Shared
libraries wouldn't load, which assortedly meant that:
- plpgsql couldn't be loaded
- Slony-I stored functions couldn't work
- regression tests wouldn't work

The typical result:

-bash-3.00$ /opt/dbs/pgsql748-afilias-AIX53-2005-10-19/bin/createlang plpgsql template1
ERROR:  could not load library "/opt/dbs/pgsql748-afilias-AIX53-2005-10-19/lib/plpgsql.so": A memory address is not in the address space for the process.
createlang: language installation failed: ERROR:  could not load library "/opt/dbs/pgsql748-afilias-AIX53-2005-10-19/lib/plpgsql.so": A memory address is not in the address space for the process.

The evident problem is actually on the permissions...

After modifying plpgsql.so to have "777" permissions (which was
doubtless more open than necessary, but hey, it took 2 seconds to
think of it :-)), the library loaded in fine.

It is very worthwhile to have this note around because we did a lot of
searching around as to possible issues with dlopen() which didn't
report anything even vaguely suggestive that permissions were not set
permissively enough...
-- 
"cbbrowne","@","acm.org"
http://cbbrowne.com/info/linuxxian.html
"MSDOS didn't get as bad as it  is overnight -- it took over ten years
of careful development."  -- <[email protected]>

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

               http://www.postgresql.org/docs/faq
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.