Error Launching pgdbg GUI on Opeteron AMD

Hi,
I cannot get the pgdgb gui to run on my Opteron AMD computer.
I have installed the java binary jre1.5.0_06 and set the variable PGI_JAVA to point to the binary. I have set the LD_LIBRARY_PATH to point to /usr/pgi/linux86-64/6.1/lib. I have unset LANG. The program works with the -text option. This is the output from the GUI window when I type: pgdbg a.out

PGDBG 6.1-1 x86-64 (Workstation, 4 CPU)
Copyright 1989-2000, The Portland Group, Inc. All Rights Reserved.
Copyright 2000-2005, STMicroelectronics, Inc. All Rights Reserved.
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at splashLoader$1.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.UnsatisfiedLinkError: /usr/pgi/linux86-64/6.1/lib/libjpgdbg.so: /usr/pgi/linux86-64/6.1/lib/libjpgdbg.so: cannot restore segment prot after reloc: Permission denied
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(Unknown Source)
at java.lang.ClassLoader.loadLibrary(Unknown Source)
at java.lang.Runtime.load0(Unknown Source)
at java.lang.System.load(Unknown Source)
at jpgdbg.main(Unknown Source)
… 6 more

I cannot figure out the permission denied reference. Do I need a different user status or the ability to write to the lib directory to run the GUI?

Thanks for interest

Bruce.

Hi,

Is there any reason why you are not using the JRE that is bundled with the PGI package? Under your pgi installation there should be a jre directory. If you do not see this directory, then perhaps the PGI package was not installed correctly.

You should not have to set the PGI_JAVA environment variable if you are using the JRE bundled with the pgi installation. For PGI releases prior to 6.1, we told some users to install a 1.5 jre in place of the one we include due to some known problems. We are not aware of any problems that force users to install their own JRE for PGI 6.1. Please try running PGDBG without setting the PGI_JAVA environment variable.

With that said, your problem resembles something we have seen before. Any chance did you install the java JRE (64bit) for AMD Opteron? We do not support this JRE. You need to use the default linux 32-bit jre (we include this with our release). You can still use the PGI_JAVA environment variable to point to another JRE (version 1.5 or higher), but it needs to be 32-bit.

-Mark

Hi Mark,
I tried using both the pgi-installed-jre (in /usr/pgi/linux86-64/6.1/jre/bin) and the 32-bit 1.5-version that I installed myself. I did not install pgi myself; it was installed by the system administrator. I can get it reinstalled - is there anything in particular that has to be noted during the installation?

Thanks for the help,

Bruce.

Hi Bruce,

As long as the PGI package was installed with the included “install” script, everything should install correctly. Please verify that /usr/pgi/linux86-64/6.1/lib/libjpgdbg.so exists in your installation. Also which linux release are you using (e.g., distribution, kernel revision, glibc version, etc.)?

Thanks,

-Mark

Hi Mark,
Here are the details:
<Please verify that /usr/pgi/linux86-64/6.1/lib/libjpgdbg.so exists in your installation:
-r-xr-xr-x 1 909 1004 5405 Jan 9 12:31 /usr/pgi/linux86-64/6.1/lib/libjpgdbg.so

<Also which linux release are you using (e.g., distribution, kernel revision, glibc version, etc):
Linux bora.eos.ubc.ca 2.6.11-1.1369_FC4smp #1 SMP Thu Jun 2 23:16:33 EDT 2005 x86_64 x86_64 x86_64 GNU/Linux
Fedora Core release 4 (Stentz)
gcc (GCC) 4.0.0 20050519 (Red Hat 4.0.0-8)
GNU C Library development release version 2.3.5,

Bruce.

Hi Bruce,

Sorry for the delay in getting back to you. This error is caused by your system’s use of SELinux security. There are two work arounds: disable SELinux by setting SELINUX=disabled in your system’s /etc/sysconfig/selinux file and reboot, or use the chcon command to change the permissions on the libjpgdbg.so library in your installation. The latter is probably the better route to go. Unfortunately, we do not have any linux boxes running SELinux in house. So, I could not try these work arounds for myself. However, I did a quick google search on “cannot restore segment prot after reloc: Permission denied” and found a couple articles that provide some hints on how to do this:

http://www.rsinc.com/services/techtip.asp?ttid=3092

Hope this helps,

Mark

Hi Mark,

Thanks for the help. This is what was done and the GUI works fine:
sudo chcon -t shlib_t /usr/pgi/linux86-64/6.1/lib/libjpgdbg.so;
sudo chcon -u system_u /usr/pgi/linux86-64/6.1/lib/libjpgdbg.so

Excellent job and thanks again.

Bruce.