RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1083292 - dynamic library not getting reinitialized on multiple calls to dlopen()
Summary: dynamic library not getting reinitialized on multiple calls to dlopen()
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: glibc
Version: 6.5
Hardware: x86_64
OS: Linux
unspecified
urgent
Target Milestone: rc
: ---
Assignee: Jakub Jelinek
QA Contact: qe-baseos-tools-bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-04-01 20:44 UTC by Dave Johansen
Modified: 2016-11-24 12:04 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-01-15 15:04:44 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Sourceware 16805 0 None None None Never

Description Dave Johansen 2014-04-01 20:44:31 UTC
Description of problem:
Dynamic libraries are not being reinitialized properly on subsequent reloads.

Version-Release number of selected component (if applicable):
4.4.7

How reproducible:
Always

Steps to Reproduce:
See gcc bug report http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60731

Additional info:
Verified to not be a problem in RHEL 5 but is a problem in the RHEL 7 beta.

Comment 2 Dave Johansen 2014-04-03 14:50:09 UTC
It was determined that this was not a bug with gcc but with glibc, so the bug was moved there: https://sourceware.org/bugzilla/show_bug.cgi?id=16805

Comment 3 Jakub Jelinek 2014-04-28 07:26:29 UTC
The only issue are the assumptions about dlclose behavior, dlclose is certainly not required to always unload the library, even before unique symbols often it has been unable to either temporarily (until some other libraries are dlclosed) or permanently unload certain libraries.
If some library relies on that, it is simply buggy.

Comment 4 Dave Johansen 2014-04-28 15:40:21 UTC
This is a bug and there is nothing in the code in the reproducer that should cause dlclose() to not unload the library. clang, icpc and gcc 4.1.2 all do the right thing here, but gcc 4.4.7 does not. It generates code that is not standard compliant and this is a regression from RHEL 5.

Comment 5 Dave Johansen 2015-01-15 15:00:59 UTC
I set the status back to new because as I stated in the previous comment, this is a regression when compared to RHEL 5 and both clang++ and icpc generate code that behaves correctly on RHEL 6.

Comment 6 Jakub Jelinek 2015-01-15 15:04:44 UTC
Nevertheless, it is not a bug.
Assumption that dlclose must always unload the library is just bad assumption, there are many reasons why something can't be unloaded.
You can use -fno-gnu-unique to avoid STB_GNU_UNIQUE symbols if you don't care about violating the C++ standard requirements (which clang++ or icpc don't bother with) with new enough toolchains (e.g. Developer Toolset).

Comment 7 Dave Johansen 2015-01-15 15:11:25 UTC
-fno-gnu-unique is only available in the newer versions of the devtoolset, so unfortunately that doesn't do anything to resolve the issue with the stock version of gcc that comes with RHEL 6.

Honestly, I LOVE that devtoolset is available and it's GREAT resource for the situations where it can be used, but the point of using RHEL is to have a stable platform and forcing users to have to constantly chase new compiler versions doesn't seem to fit into that paradigm of stability.


Note You need to log in before you can comment on or make changes to this bug.