Red Hat Bugzilla – Bug 835483
Make segfaults or hangs with RH patches applied
Last modified: 2016-05-10 17:13:59 EDT
Description of problem:
We are running a compilation and it seems that make either causes the system to hang, or segfaults.
We have rebuild the version 3.81-20 RPM without patches 8,11 and 14 applied and this seems to allow our build to complete successfully, also using a compiled from vanilla source make binary allows the build to complete successfully.
We are still working on narrowing it down but it seems that patch 8 (rlimit patch) causes the freeze, while 11(fdleak) or 14 (copy-on-expand) cause the segfault.
For reference this build works successfully everytime on Debian or Ubuntu based systems, but we prefer to use RHEL.
Also for reference the build process we are going through is a modified version of the Android Source tree.
Version-Release number of selected component (if applicable):
Redhat RPM 3.81-20
Vanilla source 3.81
Steps to Reproduce:
1.use default make from RHEL
3.Crash and/or segfault
Non completed build
Would you be so kind as to provide stack backtrace of the crash? In the mean time I'll try to reproduce the problem with existing Android tree. All the patches are there for a reason. There might be unintended consequences, but we can't simply turn them off.
As soon as we can provide any backtraces etc we will do,
Agreed about not turning them off, I guess this was more of a "work in progress/ we've found a bug has anyone else ticket"
Our main reason for disabling the patches was due to the fact this stuff compiles successfully on an Ubuntu box so we looked at the source used to generate their make package and found it to not contain said patches, running our compile with a version of make compiled from the debian sources was successful.
Am I missing something, or does that involve cross-compilation?
(In reply to comment #2)
> Would you be so kind as to provide stack backtrace of the crash?
Or better yet, core dump.
(In reply to comment #3)
> Our main reason for disabling the patches was due to the fact this stuff
> compiles successfully on an Ubuntu box so we looked at the source used to
Understood, thanks for the effort, at least now we know approximately where to look.
(In reply to comment #4)
> Am I missing something, or does that involve cross-compilation?
By this do you mean the Android build? yes it does involve cross compile, we have the relevant toolchains provided.
> (In reply to comment #2)
> > Would you be so kind as to provide stack backtrace of the crash?
> Or better yet, core dump.
We don't seem to be getting a dump, it seems to be truncated.
So just an update on this:
I have re-rolled the make RPM without patch 8 applied (rlimit) and this seems to resolve the issues we are seeing.
(In reply to comment #7)
> I have re-rolled the make RPM without patch 8 applied (rlimit) and this
> seems to resolve the issues we are seeing.
Good, that messes with memory limits, so segmentation violations might occur. Maybe we are somehow calling rlimit (to restore the original stack limit) from a context where there's a lot of stack used. I'll take a look at code paths, but a stack trace might be useful. Can you reproduce the failure from gdb?
(In reply to comment #6)
> > Or better yet, core dump.
> We don't seem to be getting a dump, it seems to be truncated.
Does 'ulimit -c unlimited' fix this by any chance?
Yeah, the problem does seem to be caused by limitations caused by that patch. Some of the process issues generally occur around java compile processes.
The ulimit command doesn't seem to have an effect as we are running these builds as users. even making changes to /etc/security/limits.conf doesn't seem to have an effect, although I haven't given it too much time/effort.
OK so the "Patch 8" fix seemed to be a smokescreen.
It seemed to resolve the issues we were seeing, but didn't realise it was causing issues elsewhere.
Seems to have had a positive effect.
so we're now running from the original 3.81-20 make rpm(all rhel patches applied) with that patch applied.
Further to this:
So Patch 8 is still causing segfaults with java compilations.
The Savanah patch is required to resolve a different issue that we were seeing, but looked to be all one problem.
I have now re-rolled the Make RPM with patch 8 removed and the Savanah patch applied..
We haven't had a segfault yet and our builds seem to run to completion each time.
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated
in the current release, Red Hat is unable to address this
request at this time.
Red Hat invites you to ask your support representative to
propose this request, if appropriate, in the next release of
Red Hat Enterprise Linux.
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.