JRE Shared Libraries with multiple installations
Posted in 2011
Topics: Installation, Setup & Upgrades
Greetings, family. I am about to install and configure two instances of IDS 11.70 on my Ubuntu machine. One is release 11.70.FC1, the innovator edition, and the other is the developer edition, 11.70.FC1DE. I happen to have installed the FC1 release first. Following the machine notes at http://publib.boulder.ibm.com/infocenter/idshelp/v117/index.jsp?topic=/com.ibm.relnotes.doc/relnotes.htm, I see it requires that I add the following two lines (simply directory paths) to /etc/ld.so.conf: <$INFORMIXDIR>/extend/krakatoa/jre/bin <$INFORMIXDIR>/extend/krakatoa/jre/bin/j9vm In my case, that happens to translate to: /var/opt/ifmx/11.70.FC1/extend/krakatoa/jre/bin /var/opt/ifmx/11.70.FC1/extend/krakatoa/jre/bin/j9vm Now what about when I install 11.70.FC1DE? IN this case - both versions of 11.70 (only one operating under a restriction on the server size) I could probably get away with only thee lines. But for anyone with two really different installations, like 11.10 and 11.70 (in separate directories, of course) what is required for the JRE? Just leave one set or are we required to include this pair for each product release installed on the box? If this tidbit is buried somewhere where I have overlooked it, please point me to the appropriate doc/page, besides simply telling me the answer. Thanks mucho! -- JS
On 18/01/2011 06:42, Beau Nanaz wrote: > Greetings, family. > > I am about to install and configure two instances of IDS 11.70 on my > Ubuntu machine. One is release 11.70.FC1, the innovator edition, and > the other is the developer edition, 11.70.FC1DE. I happen to have > installed the FC1 release first. Following the machine notes at > http://publib.boulder.ibm.com/infocenter/idshelp/v117/index.jsp?topic=/com.ibm.relnotes.doc/relnotes.htm, > I see it requires that I add the following two lines (simply directory > paths) to /etc/ld.so.conf: > <$INFORMIXDIR>/extend/krakatoa/jre/bin > <$INFORMIXDIR>/extend/krakatoa/jre/bin/j9vm > > In my case, that happens to translate to: > /var/opt/ifmx/11.70.FC1/extend/krakatoa/jre/bin > /var/opt/ifmx/11.70.FC1/extend/krakatoa/jre/bin/j9vm > > Now what about when I install 11.70.FC1DE? IN this case - both > versions of 11.70 (only one operating under a restriction on the > server size) I could probably get away with only thee lines. But for > anyone with two really different installations, like 11.10 and 11.70 > (in separate directories, of course) what is required for the JRE? > Just leave one set or are we required to include this pair for each > product release installed on the box? > > If this tidbit is buried somewhere where I have overlooked it, please > point me to the appropriate doc/page, besides simply telling me the > answer. Dunno about the proper answer, but leave ld.so.conf for system-wide libs (/lib, /usr/lib and not much else). Just point LD_LIBRARY_PATH as needed for each of your Informix installations.
On Tue, Jan 18, 2011 at 11:50, Richard Harnden <rh.nospam@tiscali-co-uk.invalid> wrote: > On 18/01/2011 06:42, Beau Nanaz wrote: > > I am about to install and configure two instances of IDS 11.70 on my > > Ubuntu machine. One is release 11.70.FC1, the innovator edition, and > > the other is the developer edition, 11.70.FC1DE. I happen to have > > installed the FC1 release first. Following the machine notes at > > > http://publib.boulder.ibm.com/infocenter/idshelp/v117/index.jsp?topic=/com.ibm.relnotes.doc/relnotes.htm > , > > I see it requires that I add the following two lines (simply directory > > paths) to /etc/ld.so.conf: > > <$INFORMIXDIR>/extend/krakatoa/jre/bin > > <$INFORMIXDIR>/extend/krakatoa/jre/bin/j9vm > > > > In my case, that happens to translate to: > > /var/opt/ifmx/11.70.FC1/extend/krakatoa/jre/bin > > /var/opt/ifmx/11.70.FC1/extend/krakatoa/jre/bin/j9vm > > > > Now what about when I install 11.70.FC1DE? IN this case - both > > versions of 11.70 (only one operating under a restriction on the > > server size) I could probably get away with only thee lines. But for > > anyone with two really different installations, like 11.10 and 11.70 > > (in separate directories, of course) what is required for the JRE? > > Just leave one set or are we required to include this pair for each > > product release installed on the box? > > > > If this tidbit is buried somewhere where I have overlooked it, please > > point me to the appropriate doc/page, besides simply telling me the > > answer. > > Dunno about the proper answer, but leave ld.so.conf for system-wide libs > (/lib, /usr/lib and not much else). > > Just point LD_LIBRARY_PATH as needed for each of your Informix > installations. > I agree that whenever possible, you should avoid messing with /etc/ld.so.conf. Unfortunately, LD_LIBRARY_PATH is ignored by setuid programs - and ON-Init is a setuid program. That may mean you have to futz with /etc/ld.so.conf after all. Having said that, I believe IDS loads Krakatoa (the JVM support) by `dl_open()` etc, and that may work 'regardless'. However, because the machine notes suggest otherwise, there's a decent chance that it won't work without butchering /etc/ld.so.conf. One possible alternative might be to create (symbolic) links from under /usr/lib to the libraries in the $INFORMIXDIR, but I'd be very cautious about doing that. -- Jonathan Leffler <jonathan.leffler@gmail.com> #include <disclaimer.h> Guardian of DBD::Informix - v2008.0513 - http://dbi.perl.org "Blessed are we who can laugh at ourselves, for we shall never cease to be amused."
On 1/18/2011 4:56 PM, Jonathan Leffler wrote: > > > On Tue, Jan 18, 2011 at 11:50, Richard Harnden > <rh.nospam@tiscali-co-uk.invalid> wrote: > > On 18/01/2011 06:42, Beau Nanaz wrote: > > I am about to install and configure two instances of IDS 11.70 on my > > Ubuntu machine. One is release 11.70.FC1, the innovator edition, > and > > the other is the developer edition, 11.70.FC1DE. I happen to have > > installed the FC1 release first. Following the machine notes at > > > http://publib.boulder.ibm.com/infocenter/idshelp/v117/index.jsp?topic=/com.ibm.relnotes.doc/relnotes.htm, > > I see it requires that I add the following two lines (simply > > directory paths) to /etc/ld.so.conf: > > <$INFORMIXDIR>/extend/krakatoa/jre/bin > > <$INFORMIXDIR>/extend/krakatoa/jre/bin/j9vm > > > > In my case, that happens to translate to: > > /var/opt/ifmx/11.70.FC1/extend/krakatoa/jre/bin > > /var/opt/ifmx/11.70.FC1/extend/krakatoa/jre/bin/j9vm > > > > Now what about when I install 11.70.FC1DE? IN this case - both > > versions of 11.70 (only one operating under a restriction on the > > server size) I could probably get away with only thee lines. But for > > anyone with two really different installations, like 11.10 and 11.70 > > (in separate directories, of course) what is required for the JRE? > > Just leave one set or are we required to include this pair for each > > product release installed on the box? > > > > If this tidbit is buried somewhere where I have overlooked it, please > > point me to the appropriate doc/page, besides simply telling me the > > answer. > > Dunno about the proper answer, but leave ld.so.conf for system-wide libs > (/lib, /usr/lib and not much else). > > Just point LD_LIBRARY_PATH as needed for each of your Informix > installations. > > > I agree that whenever possible, you should avoid messing with > /etc/ld.so.conf. > > Unfortunately, LD_LIBRARY_PATH is ignored by setuid programs - and > ON-Init is a setuid program. That may mean you have to futz with > /etc/ld.so.conf after all. > > Having said that, I believe IDS loads Krakatoa (the JVM support) by > `dl_open()` etc, and that may work 'regardless'. However, because the > machine notes suggest otherwise, there's a decent chance that it won't > work without butchering /etc/ld.so.conf. > > One possible alternative might be to create (symbolic) links from under > /usr/lib to the libraries in the $INFORMIXDIR, but I'd be very cautious > about doing that. > > -- > Jonathan Leffler <jonathan.leffler@gmail.com > <mailto:jonathan.leffler@gmail.com>> #include <disclaimer.h> > Guardian of DBD::Informix - v2008.0513 - http://dbi.perl.org > "Blessed are we who can laugh at ourselves, for we shall never cease to > be amused." Jonathan, You said two things that, to my poor, befuddled mind, require commentary: > Having said that, I believe IDS loads Krakatoa (the JVM support) by > `dl_open()` etc, and that may work 'regardless'. However, because the > machine notes suggest otherwise, there's a decent chance that it > won't work without butchering /etc/ld.so.conf. Does the above imply that one pair of new directives in /etc/ld.so.conf is sufficient? If so, I suppose the one for the most recent JRE installation should be sufficient. That's a big IF. > One possible alternative might be to create (symbolic) links from > under /usr/lib to the libraries in the $INFORMIXDIR, but I'd be very > cautious about doing that. "From under" /usr/lib? Exactly where would these hypothetical symlinks be? And exactly where would they point? Are these symlinks meant to replace actual files/directories under /usr/lib? Will this guy ever learn to ask a single question? ;-) I imagine one of my former employers, who keeps many servers of differing versions on each machine, would be very interested in this thread and the answers that come of it. Thanks. -- +---------------------------------------------------------------------+ | Men occasionally stumble over the truth, but most of them pick | | themselves up and hurry off as if nothing had happened. | +------------------------------- Sir Winston Churchill --------------+
On 19/01/2011 04:26, Beau Nanaz wrote: > On 1/18/2011 4:56 PM, Jonathan Leffler wrote: >> >> >> On Tue, Jan 18, 2011 at 11:50, Richard Harnden >> <rh.nospam@tiscali-co-uk.invalid> wrote: >> >> On 18/01/2011 06:42, Beau Nanaz wrote: >> > I am about to install and configure two instances of IDS 11.70 on my >> > Ubuntu machine. One is release 11.70.FC1, the innovator edition, >> and >> > the other is the developer edition, 11.70.FC1DE. I happen to have >> > installed the FC1 release first. Following the machine notes at >> > >> http://publib.boulder.ibm.com/infocenter/idshelp/v117/index.jsp?topic=/com.ibm.relnotes.doc/relnotes.htm, >> >> > I see it requires that I add the following two lines (simply >> > directory paths) to /etc/ld.so.conf: >> > <$INFORMIXDIR>/extend/krakatoa/jre/bin >> > <$INFORMIXDIR>/extend/krakatoa/jre/bin/j9vm >> > >> > In my case, that happens to translate to: >> > /var/opt/ifmx/11.70.FC1/extend/krakatoa/jre/bin >> > /var/opt/ifmx/11.70.FC1/extend/krakatoa/jre/bin/j9vm >> > >> > Now what about when I install 11.70.FC1DE? IN this case - both >> > versions of 11.70 (only one operating under a restriction on the >> > server size) I could probably get away with only thee lines. But for >> > anyone with two really different installations, like 11.10 and 11.70 >> > (in separate directories, of course) what is required for the JRE? >> > Just leave one set or are we required to include this pair for each >> > product release installed on the box? >> > >> > If this tidbit is buried somewhere where I have overlooked it, please >> > point me to the appropriate doc/page, besides simply telling me the >> > answer. >> >> Dunno about the proper answer, but leave ld.so.conf for system-wide libs >> (/lib, /usr/lib and not much else). >> >> Just point LD_LIBRARY_PATH as needed for each of your Informix >> installations. >> >> >> I agree that whenever possible, you should avoid messing with >> /etc/ld.so.conf. >> >> Unfortunately, LD_LIBRARY_PATH is ignored by setuid programs - and >> ON-Init is a setuid program. That may mean you have to futz with >> /etc/ld.so.conf after all. >> >> Having said that, I believe IDS loads Krakatoa (the JVM support) by >> `dl_open()` etc, and that may work 'regardless'. However, because the >> machine notes suggest otherwise, there's a decent chance that it won't >> work without butchering /etc/ld.so.conf. >> >> One possible alternative might be to create (symbolic) links from under >> /usr/lib to the libraries in the $INFORMIXDIR, but I'd be very cautious >> about doing that. >> >> -- >> Jonathan Leffler <jonathan.leffler@gmail.com >> <mailto:jonathan.leffler@gmail.com>> #include <disclaimer.h> >> Guardian of DBD::Informix - v2008.0513 - http://dbi.perl.org >> "Blessed are we who can laugh at ourselves, for we shall never cease to >> be amused." > > Jonathan, > You said two things that, to my poor, befuddled mind, require commentary: > > > Having said that, I believe IDS loads Krakatoa (the JVM support) by > > `dl_open()` etc, and that may work 'regardless'. However, because the > > machine notes suggest otherwise, there's a decent chance that it > > won't work without butchering /etc/ld.so.conf. dlopen does ignore LD_LIBRARY_PATH for setuid programs. It'll depend on if its passed the whole path or just the filename. > > Does the above imply that one pair of new directives in /etc/ld.so.conf > is sufficient? If so, I suppose the one for the most recent JRE > installation should be sufficient. That's a big IF. You could add paths for all of your JRE install, but it'll just load the first one in finds. Which is no good at all. ld.so.conf is no use when you've got multiple installs. > > > One possible alternative might be to create (symbolic) links from > > under /usr/lib to the libraries in the $INFORMIXDIR, but I'd be very > > cautious about doing that. > > "From under" /usr/lib? Exactly where would these hypothetical symlinks > be? And exactly where would they point? Are these symlinks meant to > replace actual files/directories under /usr/lib? I can't see how that will help. You want to link to different a lib-with-the-same-name depending on your $INFORMIXDIR. > > Will this guy ever learn to ask a single question? ;-) > > I imagine one of my former employers, who keeps many servers of > differing versions on each machine, would be very interested in this > thread and the answers that come of it. Ahh, I see: # Discontinued onconfig variables # # The following onconfig variables have been discontinued: # # * JVPHOME # * JVPJAVAHOME # * JVPJAVALIB # * JVPJAVAVM If the dlopen call used JVPJAVAHOME/JVPJAVALIB/libfoo.so, then you would've been cool. Maybe it'll search amongst DB_LIBRARY_PATH ... ? Worth a try, anyway.