Bug 467072 - mysqld fails on shmget call for hugetlb
mysqld fails on shmget call for hugetlb
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: selinux-policy-targeted (Show other bugs)
9
All Linux
medium Severity high
: ---
: ---
Assigned To: Daniel Walsh
Ben Levenson
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-10-15 12:03 EDT by Andrig Miller
Modified: 2008-10-16 17:31 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-10-15 16:19:53 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Andrig Miller 2008-10-15 12:03:01 EDT
Description of problem:

mysqld fails on the shmget system call for hugetlb when SELinux is in enforcing mode.


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

selinux-policy-targeted-3.3.1-95.fc9


How reproducible:

Every time you start mysqld with the targeted policy in enforcing mode.


Steps to Reproduce:
1. Setup hugetlb in Fedora 9
2. Setup mysqld to use hugetlb (large_pages = true) in my.cnf
3. Start mysqld
  
Actual results:

081014 12:29:09  mysqld started
InnoDB: HugeTLB: Warning: Failed to allocate 2147500032 bytes. errno 12
InnoDB HugeTLB: Warning: Using conventional memory pool

Expected results:

081015 09:47:15  mysqld started
081015  9:47:17  InnoDB: Started; log sequence number 3 3625525224
081015  9:47:17 [Note] /usr/libexec/mysqld: ready for connections.

No error on attaching to the hugetlb (shared memory segment)

/proc/meminfo looks like this:

HugePages_Total:  3072
HugePages_Free:   3071
HugePages_Rsvd:   1028
HugePages_Surp:      0
Hugepagesize:     2048 kB


Additional info:

This is a re-occurrence of bug 426877 that was fixed in Fedora 8.  Somehow this bug didn't make it upstream or was dropped along the way somewhere.
Comment 1 Daniel Walsh 2008-10-15 16:19:53 EDT
sesearch -s mysqld_t --allow | grep huge
   allow mysqld_t hugetlbfs_t : file { ioctl read write getattr lock append }; 
   allow mysqld_t hugetlbfs_t : dir { getattr search }; 

rpm -q selinux-policy
selinux-policy-3.3.1-99.fc10.noarch

They seem to be there in 99?
Comment 2 Andrig Miller 2008-10-15 18:43:41 EDT
As you can see I'm not using Fedora 10, but 9.  Is this 3.3.1-99 also going to be coming out for 9?
Comment 3 Daniel Walsh 2008-10-16 13:57:46 EDT
THe same thing.  99 should be out for F9.  Originally built on F10 machine but it is f9 policy.
Comment 4 Andrig Miller 2008-10-16 17:31:53 EDT
Okay, thanks.

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