Bug #43410 --skip-core-file has no effect if core file size is set
Submitted: 5 Mar 2009 12:35 Modified: 10 Mar 2009 14:32
Reporter: Davi Arnaut (OCA) Email Updates:
Status: Closed Impact on me:
None 
Category:Tools: MTR / mysql-test-run Severity:S3 (Non-critical)
Version:5.1 6.0 OS:Any
Assigned to: Bjørn Munch CPU Architecture:Any

[5 Mar 2009 12:35] Davi Arnaut
Description:
The problem is that intentionally crashing the server will cause a core dump even if --skip-core-file is supplied to MTR. This happens if the resource limit for core file sizes (ulimit -c) is not disabled.

How to repeat:
Execute crash_commit_before test and look for the core file.

Suggested fix:
Spawn mysqld processes with rlimit core size set to zero if --skip-core-file is supplied.
[5 Mar 2009 12:55] Guilhem Bichot
affects Maria tests too (which crash the server intentionally)
[6 Mar 2009 15:14] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/68511

2763 Bjorn Munch	2009-03-06
      Bug #43410 --skip-core-file has no effect if core file size is set
      Would not prevent mysqld from core dumping
      Passes --nocore arg to safe_process, which then sets rlimit core to 0 for child
      modified:
        mysql-test/lib/My/SafeProcess.pm
        mysql-test/lib/My/SafeProcess/safe_process.cc
        mysql-test/mysql-test-run.pl
[9 Mar 2009 13:32] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/68650

2766 Bjorn Munch	2009-03-09
      Bug #43410 --skip-core-file has no effect if core file size is set
      Would not prevent mysqld from core dumping
      Passes --nocore arg to safe_process, which then sets rlimit core to 0 for child
      modified:
        mysql-test/lib/My/SafeProcess.pm
        mysql-test/lib/My/SafeProcess/safe_process.cc
        mysql-test/mysql-test-run.pl
[9 Mar 2009 22:24] Bjørn Munch
Pushed to 6.0-mtr and 5.1-mtr
[10 Mar 2009 13:53] Bugs System
Pushed into 6.0.11-alpha (revid:bjorn.munch@sun.com-20090310133716-5qpotn2sggp621s1) (version source revid:bjorn.munch@sun.com-20090310133716-5qpotn2sggp621s1) (merge vers: 6.0.11-alpha) (pib:6)
[10 Mar 2009 13:56] Bugs System
Pushed into 5.1.33 (revid:bjorn.munch@sun.com-20090310134806-wnurk6dobx9u605b) (version source revid:bjorn.munch@sun.com-20090310134806-wnurk6dobx9u605b) (merge vers: 5.1.33) (pib:6)
[10 Mar 2009 14:32] Paul DuBois
Test suite change. No changelog entry needed.
[12 Mar 2009 14:29] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/69046

2769 Bjorn Munch	2009-03-12
      Bug #43597 Fix for Bug #43410 breaks build on Power Mac due to incomplete sys/resource.h
      Added include of sys/time.h
      modified:
        mysql-test/lib/My/SafeProcess/safe_process.cc
[9 May 2009 16:47] Bugs System
Pushed into 5.1.34-ndb-6.2.18 (revid:jonas@mysql.com-20090508185236-p9b3as7qyauybefl) (version source revid:jonas@mysql.com-20090508100057-30ote4xggi4nq14v) (merge vers: 5.1.33-ndb-6.2.18) (pib:6)
[9 May 2009 17:44] Bugs System
Pushed into 5.1.34-ndb-6.3.25 (revid:jonas@mysql.com-20090509063138-1u3q3v09wnn2txyt) (version source revid:jonas@mysql.com-20090508175813-s6yele2z3oh6o99z) (merge vers: 5.1.33-ndb-6.3.25) (pib:6)
[9 May 2009 18:41] Bugs System
Pushed into 5.1.34-ndb-7.0.6 (revid:jonas@mysql.com-20090509154927-im9a7g846c6u1hzc) (version source revid:jonas@mysql.com-20090509073226-09bljakh9eppogec) (merge vers: 5.1.33-ndb-7.0.6) (pib:6)