Bug 117527 - yum update of kernel package fails
yum update of kernel package fails
Status: CLOSED WORKSFORME
Product: Fedora
Classification: Fedora
Component: yum (Show other bugs)
rawhide
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Jeff Johnson
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2004-03-04 17:42 EST by Josh Boyer
Modified: 2014-01-21 17:49 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2004-04-11 21:41:38 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 Josh Boyer 2004-03-04 17:42:33 EST
Description of problem:

When I do a yum update of the kernel package, it fails with the
following error:

[root@localhost root]# yum -C update kernel

Unable to find pid
Gathering header information file(s) from server(s)
Server: Fedora Core 1.90 - Development Tree
Finding updated packages
Downloading needed headers
Resolving dependencies
Dependencies resolved
I will do the following:
[install: kernel 2.6.3-1.118.i686]
Is this ok [y/N]: y
Downloading Packages
Running test transaction:
/etc/security/selinux/src/policy/file_contexts/file_contexts: No such
file or directory
memory alloc (4 bytes) returned NULL.
[root@localhost root]#


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

[root@localhost root]# rpm -q yum
yum-2.0.5.20040229-1
[root@localhost root]#

How reproducible:

Always, since kernel 2.6.3-1.110

Steps to Reproduce:
1.  yum -y update kernel
2.
3.
  
Actual results:

Failure in test transaction

Expected results:

kernel package updated

Additional info:

I don't think the box is actually running out of RAM, so I am not sure
why it is failing with that message.  machine specs:

P4 1.4 GHz
256 MB RDRAM
60 GB IBM Deskstar HD
Comment 1 Seth Vidal 2004-03-04 17:46:51 EST
I'm not certain but I don't think yum is spitting out that error about
malloc'd memory. 
Jeff, does anything like that come out of rpm? Or is this a new, fun
selinux thing?
Comment 2 Josh Boyer 2004-03-05 09:31:24 EST
I didn't have any of the policy packages installed until last night
around 9.

also, i tried using just plain old rpm to install the kernel from
/var/cache/yum/development/packages/ and that worked fine.

right now the kernel is at 2.6.3-1.118.  i will try yum again when a
new kernel update comes out and see if i get the same results.
Comment 3 Josh Boyer 2004-03-05 16:54:25 EST
same thing after updating to today's yum.  i do have swap turned on,
so like i said, i doubt the box is running out of memory.

is there anything else i could do or provide that would help?  i could
do an strace if someone wanted and attach that here...

[root@localhost root]# yum update kernel
Gathering header information file(s) from server(s)
Server: Fedora Core 1.90 - Development Tree
Finding updated packages
Downloading needed headers
Resolving dependencies
Dependencies resolved
I will do the following:
[install: kernel 2.6.3-2.1.238.i686]
Is this ok [y/N]: y
Downloading Packages
Getting kernel-2.6.3-2.1.238.i686.rpm
kernel-2.6.3-2.1.238.i686 100% |=========================|  14 MB    01:39
Running test transaction:
memory alloc (4 bytes) returned NULL.
[root@localhost root]# rpm -q yum
yum-2.0.5.20040303-1
[root@localhost root]#
Comment 4 Seth Vidal 2004-03-05 16:56:00 EST
Have you run a memory test on this machine?
memtest86 might be a good thing to install.
Comment 5 Josh Boyer 2004-03-06 09:01:16 EST
i ran memtest86 with all tests overnight and it didn't report any errors.

i am going to do an strace today and see if i can make any sense out
of it.  i'll attach it later
Comment 6 Jeff Johnson 2004-03-06 09:11:06 EST
The message comes from rpm, yes.

malloc should not be returning NULL for a 4 byte request.
Something else is wrong.

selinux has nothing to do with the problem unless you've
turned selinux on. If so, try booting with selinux=0.

You might want to watch the memory footprint of
yum (or rpm) while running using top. See if you're
running out of swap, 256 MB is a tad small sometimes.

Comment 7 Josh Boyer 2004-03-06 10:56:10 EST
watched top while attempting to do the update and swap appeared to be
fine.  max usage was ~55%.

did the strace and it seems that mmap2 is returning -ENOMEM toward the
end.  i can attach the trace if anyone wants, but it's pretty large
(~13MiB).

anything else i can do that you guys can think of?
Comment 8 Jeff Johnson 2004-03-19 06:28:27 EST
If mmap2 is returning -ENOMEM, user land tools like
rpm have got to believe that is accurate and true answer.

No idea why mmap2 should return ENOMEM on a 4 byte memory request,
but rpm is accurately and faithfully reporting what the kernel
is returning, as you have verified strace shows.

NEEDINFO so I don't have to stare at the bug. I'm not sure what
else is needed ...
Comment 9 Josh Boyer 2004-04-11 21:41:38 EDT
did a fresh install of FC2 test2 and the problem seems to have gone
away.  chalking this up to user error for now.  thx for the help.
Comment 10 Richard Schaal 2005-01-02 13:55:14 EST
Running FC-2 and trying to get yum to update the kernel - I see the
same set of messages.  However, I have more info...  Using TOP to view
activity of the programs, you can see yum begin to rapidly allocate
memory until the system memory is exhausted.  I've seen more than
800MB in resident memory allocated for yum.  

[root@snowwhite root]# yum update kernel kernel-smp
                                                                     
          
Unable to find pid
Gathering header information file(s) from server(s)
Server: Fedora Core 2 - i386 - Base
Server: Fedora Core 2 - i386 - Released Updates
Finding updated packages
Downloading needed headers
Resolving dependencies
Dependencies resolved
I will do the following:
[install: kernel 2.6.9-1.6_FC2.i686]
[install: kernel-smp 2.6.9-1.6_FC2.i686]
Is this ok [y/N]: y
Downloading Packages
Running test transaction:
memory alloc (4 bytes) returned NULL.
You have new mail in /var/spool/mail/root
[root@snowwhite root]#

I am seeing the same memory alloc failure running up2date on this
system when the kernel is to be updated.  Since I'm running ECC
memory, it is highly unlikely that we're seeing a memory failure.
Comment 11 Seth Vidal 2005-01-02 17:04:39 EST
how many kernels and kernel-smp do you have installed?

rpm -q kernel kernel-smp
Comment 12 Josh Boyer 2005-01-02 22:14:15 EST
Some additional info on my part:

IIRC, I had about 8-9 kernels installed when I hit the problem.  As I
said before, I eventually did a fresh install of FC2 test2 (which was
current at the time) and the problem went away.

Since then, I've been removing kernels that are back-leveled by about
2 or 3 releases before doing upgrades and haven't seen the problem since.
Comment 13 Seth Vidal 2005-01-03 00:44:54 EST
You're hitting the oom killer in the kernel b/c of the number of
kernels you have installed. b/c kernels are installed not updated the
old ones have to be checked to make sure there are no file conflicts
with them. This happens in the rpm transaction test and it consumes
and enormous amount of memory b/c of all the files it has to juggle
and track.



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