GFS2: Kernel panic at gfs2:gfs2_alloc_meta+0x26/0x19a

Solution Unverified - Updated -

Environment

  • Red Hat Enterprise Linux Server 5 (with the High Availability and Resilient Storage Add Ons)
  • kernel-2.6.18-194.el5

Issue

  • Kernel panic occurs when running an application like nfs service

    Unable to handle kernel NULL pointer dereference at 0000000000000188 RIP:
    [<ffffffff8859af5c>] :gfs2:gfs2_alloc_meta+0x26/0x19a
    PGD bf047067 PUD 0
    Oops: 0000 [1] SMP
    last sysfs file:
    /devices/pci0000:00/0000:00:09.0/0000:09:00.0/0000:0a:04.0/0000:0c:00.1/irq
    CPU 1
    Modules linked in: lock_dlm gfs2 dlm configfs bonding ipv6 xfrm_nalgo
    crypto_api dm_round_robin dm_multipath scsi_dh video backlight sbs power_meter
    hwmon i2c_ec i2c_core dell_wmi wmi button battery asus_acpi acpi_memhotplug ac
    parport_pc lp parport bnx2x hpilo e1000e serio_raw shpchp pcspkr sg dm_raid45
    dm_message dm_region_hash dm_mem_cache dm_snapshot dm_zero dm_mirror dm_log
    dm_mod qla2xxx scsi_transport_fc cciss sd_mod scsi_mod ext3 jbd uhci_hcd
    ohci_hcd ehci_hcd
    Pid: 21252, comm: httpd Not tainted 2.6.18-194.el5 #1
    RIP: 0010:[<ffffffff8859af5c>]  [<ffffffff8859af5c>]
    :gfs2:gfs2_alloc_meta+0x26/0x19a
    RSP: 0018:ffff8102ccb63a38  EFLAGS: 00010292
    RAX: ffff81031e90d400 RBX: ffff8102deb8f368 RCX: 0000000001030af0
    RDX: 000000000000000e RSI: ffff8102ccb63b00 RDI: ffff8102deb8f368
    RBP: ffff8102deb8f368 R08: ffff81000001eb00 R09: 0000000000000000
    R10: ffff81030b9ad000 R11: ffffffff8858d1d5 R12: ffff8102deb8f368
    R13: ffff8102ccb63b00 R14: ffff8102deb8f368 R15: 0000000000000000
    FS:  00002b0ba6361300(0000) GS:ffff81019fc1eac0(0000) knlGS:0000000000000000
    CS:  0010 DS: 0000 ES: 0000 CR0: 000000008005003b
    CR2: 0000000000000188 CR3: 00000002bb544000 CR4: 00000000000006e0
    Process httpd (pid: 21252, threadinfo ffff8102ccb62000, task ffff81031f944100)
    Stack:  00000018be0f04f0 ffff8102deb8e428 ffff8102ccb63af8 ffff8102deb8f368
    ffff8102deb8f368 000000000000000e ffff8102ccb63b00 ffff8102deb8f368
    ffff810132603330 ffffffff88580c9a 0000000000000000 0000000000000000
    Call Trace:
    [<ffffffff88580c9a>] :gfs2:new_leaf+0x18/0xe5
    [<ffffffff885812bb>] :gfs2:dir_split_leaf+0xc1/0x54a
    [<ffffffff8858090e>] :gfs2:gfs2_dirent_search+0xca/0x16e
    [<ffffffff88582322>] :gfs2:gfs2_dir_add+0x39c/0x6f4
    [<ffffffff8858d212>] :gfs2:buf_lo_add+0x3d/0x107
    [<ffffffff88594bae>] :gfs2:gfs2_rename+0x5b3/0x652
    [<ffffffff885946fb>] :gfs2:gfs2_rename+0x100/0x652
    [<ffffffff88594741>] :gfs2:gfs2_rename+0x146/0x652
    [<ffffffff88594766>] :gfs2:gfs2_rename+0x16b/0x652
    [<ffffffff88594799>] :gfs2:gfs2_rename+0x19e/0x652
    [<ffffffff88586f2d>] :gfs2:gfs2_holder_uninit+0xd/0x1f
    [<ffffffff885957ca>] :gfs2:gfs2_permission+0xaf/0xd5
    [<ffffffff80030f3b>] d_splice_alias+0xdc/0xfb
    [<ffffffff8000d947>] permission+0x81/0xc8
    [<ffffffff8002a9cd>] vfs_rename+0x2f4/0x471
    [<ffffffff80036f09>] sys_renameat+0x180/0x1eb
    [<ffffffff80044339>] sys_fchmodat+0xad/0xbe
    [<ffffffff80065c7d>] lock_kernel+0x1b/0x32
    [<ffffffff800b878c>] audit_syscall_entry+0x180/0x1b3
    [<ffffffff8005e28d>] tracesys+0xd5/0xe0
    
    
    Code: 49 8b af 88 01 00 00 4c 8b b0 40 02 00 00 48 8b 55 40 48 39
    RIP  [<ffffffff8859af5c>] :gfs2:gfs2_alloc_meta+0x26/0x19a
    RSP <ffff8102ccb63a38>
    

Resolution

Upgrade to 2.6.18-238 kernel or later.

A gfs2 filesystem check is recommended following encountering this issue.

Root Cause

The panic is caused by a bug in gfs2 module.

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.

Comments