Bug 518055

Summary: grubby recieved SIGSEGV! Backtrace (6):
Product: [Fedora] Fedora Reporter: udo <udovdh>
Component: grubbyAssignee: Peter Jones <pjones>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: urgent Docs Contact:
Priority: urgent    
Version: 11CC: hdegoede, kutekunal, matt_domsch, pjones, wtogami
Target Milestone: ---Flags: kutekunal: needinfo?
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-06-28 14:09:58 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description udo 2009-08-18 15:56:26 UTC
Description of problem:
grubby recieved SIGSEGV!  Backtrace (6): while `make modules_install install` to install a linux kernel (2.6.30.5).


Version-Release number of selected component (if applicable):
6.0.87-1.fc11

How reproducible:
Install/upgrade FC11, get 2.6.30.5 kernel  source, compile, install with make modules_install install

Steps to Reproduce:
1. make bzImage modules 
2. make modules_install install
3. bingo
  
Actual results:
sh /usr/src/linux-2.6.30/arch/x86/boot/install.sh 2.6.30.5 arch/x86/boot/bzImage \
		System.map "/boot"
grubby recieved SIGSEGV!  Backtrace (6):
/sbin/grubby[0x40793f]
/lib64/libc.so.6[0x3a62e33370]
/sbin/grubby[0x40211c]
/sbin/grubby[0x407392]
/lib64/libc.so.6(__libc_start_main+0xfd)[0x3a62e1ea2d]
/sbin/grubby[0x4018f9]


Expected results:
Installed kernel, no error

Additional info:

Comment 1 udo 2009-08-22 16:44:31 UTC
Why mkinitrd when I see:

# bash -x /sbin/new-kernel-pkg --mkinitrd --depmod --install 2.6.30.5
+ PATH=/sbin:/bin:/usr/lib64/qt-3.3/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/lib64/ccache:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin
+ lilo=/sbin/lilo
+ kernelName=vmlinuz
+ '[' -x ./grubby ']'
+ grubby=/sbin/grubby
+ '[' -f /etc/sysconfig/kernel ']'
+ . /etc/sysconfig/kernel
++ UPDATEDEFAULT=yes
++ DEFAULTKERNEL=kernel
+ cfgGrub=
+ cfgLilo=
+ runLilo=
+ grubConfig=
++ uname -m
+ ARCH=x86_64
+ '[' x86_64 = ia64 ']'
+ '[' x86_64 = ppc64 -o x86_64 = ppc ']'
+ '[' x86_64 = sparc -o x86_64 = sparc64 ']'
+ '[' x86_64 = s390 -o x86_64 = s390x ']'
+ liloConfig=/etc/lilo.conf
++ readlink -f /etc/grub.conf
+ grubConfig=/boot/grub/grub.conf
+ bootPrefix=/boot
+ liloFlag=lilo
+ isx86=yes
+ mode=
+ version=
+ initrd=
+ initrdfile=
+ moddep=
+ verbose=
+ makedefault=
+ package=
+ mbkernel=
+ mbargs=
+ '[' 4 -gt 0 ']'
+ case $1 in
+ initrd=make
+ shift
+ '[' 3 -gt 0 ']'
+ case $1 in
+ moddep=make
+ shift
+ '[' 2 -gt 0 ']'
+ case $1 in
+ '[' -z '' ']'
+ mode=--install
+ shift
+ '[' 1 -gt 0 ']'
+ case $1 in
+ '[' -z --install ']'
+ '[' -z '' ']'
+ version=2.6.30.5
+ shift
+ '[' 0 -gt 0 ']'
+ '[' --install '!=' --install -a --install '!=' --remove -a --install '!=' --update -a --install '!=' --rpmposttrans ']'
+ '[' -z 2.6.30.5 ']'
+ '[' --install '!=' --install -a '' ']'
++ echo
++ cut -d . -f 1,2
+ kernelmajor=
+ '[' x86_64 = ppc64 -o x86_64 = ppc ']'
+ '[' -z '' ']'
++ uname -m
+ '[' x86_64 = ia64 ']'
+ initrdfile=/boot/initrd-2.6.30.5.img
+ '[' -n '' ']'
+ '[' --install == --install -a yes == yes -a -n '' -a -n kernel -a '' == kernel ']'
+ '[' make == make ']'
+ doDepmod
+ '[' -n '' ']'
+ depmod -ae -F /boot/System.map-2.6.30.5 2.6.30.5
+ '[' make == make ']'
+ mkinitrd
+ '[' -n '' ']'
+ /sbin/mkinitrd --allow-missing -f /boot/initrd-2.6.30.5.img 2.6.30.5
+ rc=0
+ '[' 0 '!=' 0 ']'
+ '[' '!' -x /sbin/grubby ']'
+ '[' -n /boot/grub/grub.conf ']'
+ '[' -f /boot/grub/grub.conf ']'
+ cfgGrub=1
+ '[' -n /etc/lilo.conf ']'
+ '[' -f /etc/lilo.conf ']'
+ '[' -n '' -a -n yes ']'
+ '[' --install == --install ']'
+ install
+ '[' '!' -f /boot/vmlinuz-2.6.30.5 ']'
+ INITRD=
+ '[' -f /boot/initrd-2.6.30.5.img ']'
+ '[' -n '' ']'
+ INITRD='--initrd /boot/initrd-2.6.30.5.img'
+ '[' -d /proc/iSeries ']'
++ awk '{ if ($1 !~ /^[ \t]*#/ && $2 == "/") { print $1; }}' /etc/fstab
+ rootdevice=/dev/myvg/rootlv
++ echo /dev/myvg/rootlv
++ cut -d= -f1
+ short=/dev/myvg/rootlv
+ '[' /dev/myvg/rootlv == LABEL -o /dev/myvg/rootlv == UUID ']'
+ '[' -n '' -a -n '' -a lilo '!=' elilo ']'
+ '[' -n 1 ']'
+ '[' -n '' ']'
+ '[' -n '' ']'
+ '[' -f /etc/redhat-release ']'
++ sed 's/ release.*$//'
+ title='Fedora (2.6.30.5)'
+ /sbin/grubby --add-kernel=/boot/vmlinuz-2.6.30.5 --initrd /boot/initrd-2.6.30.5.img --copy-default --title 'Fedora (2.6.30.5)' '--args=root=/dev/myvg/rootlv ' '--remove-kernel=TITLE=Fedora (2.6.30.5)'
grubby recieved SIGSEGV!  Backtrace (6):
/sbin/grubby[0x40793f]
/lib64/libc.so.6[0x3a62e33370]
/sbin/grubby[0x40211c]
/sbin/grubby[0x407392]
/lib64/libc.so.6(__libc_start_main+0xfd)[0x3a62e1ea2d]
/sbin/grubby[0x4018f9]
+ '[' -n '' ']'
+ '[' -n '' ']'
+ exit 0
#

Comment 2 udo 2009-08-22 17:08:35 UTC
strace of offending grubby call:

[................]
close(3)                                = 0
access("/lib64/bdevid//ata.so", X_OK)   = 0
open("/lib64/bdevid//ata.so", O_RDONLY) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0@\20\0\0\0\0\0\0@"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=11728, ...}) = 0
mmap(NULL, 2107968, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f59bbe46000
mprotect(0x7f59bbe49000, 2093056, PROT_NONE) = 0
mmap(0x7f59bc048000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x2000) = 0x7f59bc048000
close(3)                                = 0
access("/lib64/bdevid//usb.so", X_OK)   = 0
open("/lib64/bdevid//usb.so", O_RDONLY) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0`\20\0\0\0\0\0\0@"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=11600, ...}) = 0
mmap(NULL, 2107840, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f59bbc43000
mprotect(0x7f59bbc46000, 2093056, PROT_NONE) = 0
mmap(0x7f59bbe45000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x2000) = 0x7f59bbe45000
close(3)                                = 0
open("/etc/popt", O_RDONLY)             = -1 ENOENT (No such file or directory)
stat("/etc/popt.d", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
open("/etc/popt.d", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
fcntl(3, F_GETFD)                       = 0x1 (flags FD_CLOEXEC)
getdents(3, /* 2 entries */, 32768)     = 48
getdents(3, /* 0 entries */, 32768)     = 0
close(3)                                = 0
open("/root/.popt", O_RDONLY)           = -1 ENOENT (No such file or directory)
stat("/", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
stat("/boot", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
open("/etc/grub.conf", O_RDONLY|O_CLOEXEC) = 3
read(3, "# grub.conf generated by anaconda"..., 1024) = 1024
read(3, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 1024) = 968
read(3, ""..., 1024)                    = 0
close(3)                                = 0
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
rt_sigaction(SIGSEGV, {SIG_DFL, [SEGV], SA_RESTORER|SA_RESTART, 0x3a62e33370}, {0x407910, [SEGV], SA_RESTORER|SA_RESTART, 0x3a62e33370}, 8) = 0
futex(0x3a6316c600, FUTEX_WAKE_PRIVATE, 2147483647) = 0
futex(0x346f6193b0, FUTEX_WAKE_PRIVATE, 2147483647) = 0
write(2, "grubby recieved SIGSEGV!  Backtra"..., 41grubby recieved SIGSEGV!  Backtrace (6):
) = 41
writev(2, [{"/sbin/grubby"..., 12}, {"[0x"..., 3}, {"40793f"..., 6}, {"]\n"..., 2}], 4/sbin/grubby[0x40793f]
) = 23
writev(2, [{"/lib64/libc.so.6"..., 16}, {"[0x"..., 3}, {"3a62e33370"..., 10}, {"]\n"..., 2}], 4/lib64/libc.so.6[0x3a62e33370]
) = 31
writev(2, [{"/sbin/grubby"..., 12}, {"[0x"..., 3}, {"40211c"..., 6}, {"]\n"..., 2}], 4/sbin/grubby[0x40211c]
) = 23
writev(2, [{"/sbin/grubby"..., 12}, {"[0x"..., 3}, {"407392"..., 6}, {"]\n"..., 2}], 4/sbin/grubby[0x407392]
) = 23
writev(2, [{"/lib64/libc.so.6"..., 16}, {"("..., 1}, {"__libc_start_main"..., 17}, {"+0x"..., 3}, {"fd"..., 2}, {")"..., 1}, {"[0x"..., 3}, {"3a62e1ea2d"..., 10}, {"]\n"..., 2}], 9/lib64/libc.so.6(__libc_start_main+0xfd)[0x3a62e1ea2d]
) = 55
writev(2, [{"/sbin/grubby"..., 12}, {"[0x"..., 3}, {"4018f9"..., 6}, {"]\n"..., 2}], 4/sbin/grubby[0x4018f9]
) = 23
exit_group(1)                           = ?


????

So why mkinitrd?

So grubby fails on grub.conf.
Upon inspection of said file I noticed a bunch of ^@ at the end of the final line (initrd=....).
After moving the ^@'s to a new line the `make modules_install install` ran OK.

So please fix this issue in grubby.

Comment 3 Matt Domsch 2010-04-16 14:59:11 UTC
I received a similar backtrace today, using 
grubby-7.0.13-1.fc13.x86_64

Running Transaction
  Installing     : kernel-2.6.33.2-41.fc13.x86_64                                                                        1/2 
grubby recieved SIGSEGV!  Backtrace (8):
/sbin/grubby[0x40805f]
/lib64/libc.so.6[0x329b4339d0]
/lib64/libc.so.6[0x329b52b5f6]
/sbin/grubby[0x40695e]
/sbin/grubby[0x406ae3]
/sbin/grubby[0x407e58]
/lib64/libc.so.6(__libc_start_main+0xfd)[0x329b41ed2d]
/sbin/grubby[0x401709]
  Cleanup        : kernel-2.6.31.12-174.2.22.fc12.x86_64                                                                 2/2 

Removed:
  kernel.x86_64 0:2.6.31.12-174.2.22.fc12                                                                                    

Installed:
  kernel.x86_64 0:2.6.33.2-41.fc13

Comment 4 udo 2010-04-16 15:10:34 UTC
Does grub.conf contain ^@ at the end of the final
line (initrd=....)?

Comment 5 Matt Domsch 2010-04-16 20:45:09 UTC
udo: no.

# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE:  You have a /boot partition.  This means that
#          all kernel and initrd paths are relative to /boot/, eg.
#          root (hd0,0)
#          kernel /vmlinuz-version ro root=/dev/VolGroup00/LogVol00
#          initrd /initrd-version.img
#boot=/dev/sda
default=0
timeout=5
splashimage=(hd0,0)/grub/splash.xpm.gz
hiddenmenu
title Fedora (2.6.33.1-19.fc13.x86_64)
	root (hd0,0)
	kernel /vmlinuz-2.6.33.1-19.fc13.x86_64 ro root=/dev/VolGroup00/LogVol00 SYSFONT=latarcyrheb-sun16 LANG=en_US.UTF-8 K
EYTABLE=us
	initrd /initramfs-2.6.33.1-19.fc13.x86_64.img
title Fedora (2.6.32.9-70.fc12.x86_64)
	root (hd0,0)
	kernel /vmlinuz-2.6.32.9-70.fc12.x86_64 ro root=/dev/VolGroup00/LogVol00 SYSFONT=latarcyrheb-sun16 LANG=en_US.UTF-8 K
EYTABLE=us
	initrd /initramfs-2.6.32.9-70.fc12.x86_64.img
title Fedora (2.6.32-rc3)
	root (hd0,0)
	kernel /vmlinuz-2.6.32-rc3 ro root=/dev/VolGroup00/LogVol00 rhgb quiet SYSFONT=latarcyrheb-sun16 LANG=en_US.UTF-8 KEY
TABLE=us
	initrd /initramfs-2.6.32-rc3.img

Comment 6 Bug Zapper 2010-04-28 09:49:10 UTC
This message is a reminder that Fedora 11 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 11.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '11'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 11's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 11 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 7 kunal 2010-05-09 06:05:27 UTC
I am getting the following problem, and can not report the bug automatically. So I have copied and pasted the message. I a new user of Fedora, and don't know where and how to report these bug manually. Please help me out. 


[New Thread 2181]
Cannot access memory at address 0x5f667566

Thread 2 (Thread 2181):
#0  0x00a83424 in ?? ()
No symbol table info available.
#1  0xb3520508 in ?? ()
No symbol table info available.
#2  0xffffffff in ?? ()
No symbol table info available.
#3  0x00000001 in ?? ()
No symbol table info available.
#4  0x0051ae46 in ?? ()
No symbol table info available.
#5  0xffffffff in ?? ()
No symbol table info available.
#6  0x00000001 in ?? ()
No symbol table info available.
#7  0x007a82f4 in ?? ()
No symbol table info available.
#8  0xb3521b38 in ?? ()
No symbol table info available.
#9  0xb3520548 in ?? ()
No symbol table info available.
#10 0xb3520568 in ?? ()
No symbol table info available.
#11 0x007935c8 in ?? ()
No symbol table info available.
#12 0xb3520548 in ?? ()
No symbol table info available.
#13 0x00000001 in ?? ()
No symbol table info available.
#14 0xffffffff in ?? ()
No symbol table info available.
#15 0x00000008 in ?? ()
No symbol table info available.
#16 0xb2a00048 in ?? ()
No symbol table info available.
#17 0x02000000 in ?? ()
No symbol table info available.
#18 0xb2a07de0 in ?? ()
No symbol table info available.
#19 0x00000000 in ?? ()
No symbol table info available.

Thread 1 (Thread 1826):
#0  0x00a83424 in ?? ()
No symbol table info available.
#1  0xbf95be20 in ?? ()
No symbol table info available.
#2  0x00000006 in ?? ()
No symbol table info available.
#3  0x00000722 in ?? ()
No symbol table info available.
#4  0x00475a81 in ?? ()
No symbol table info available.
#5  0x005bbff4 in ?? ()
No symbol table info available.
#6  0xbf95bf40 in ?? ()
No symbol table info available.
#7  0xbf95bf48 in ?? ()
No symbol table info available.
#8  0x0047734a in ?? ()
No symbol table info available.
#9  0x00000006 in ?? ()
No symbol table info available.
#10 0xbf95bec0 in ?? ()
No symbol table info available.
#11 0x00000000 in ?? ()
No symbol table info available.
Cannot access memory at address 0x5f667566
No symbol "__abort_msg" in current context.
No symbol "__glib_assert_msg" in current context.
eax            0x0	0
ecx            0x722	1826
edx            0x6	6
ebx            0x722	1826
esp            0xbf95be08	0xbf95be08
ebp            0xbf95be20	0xbf95be20
esi            0x911ec88	152169608
edi            0x5bbff4	6012916
eip            0xa83424	0xa83424
eflags         0x200206	[ PF IF ID ]
cs             0x73	115
ss             0x7b	123
ds             0x7b	123
es             0x7b	123
fs             0x0	0
gs             0x33	51
No function contains program counter for selected frame.

Comment 8 Bug Zapper 2010-06-28 14:09:58 UTC
Fedora 11 changed to end-of-life (EOL) status on 2010-06-25. Fedora 11 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.