raspberrypi / linux

Kernel source tree for Raspberry Pi-provided kernel builds. Issues unrelated to the linux kernel should be posted on the community forum at https://forums.raspberrypi.com/
Other
10.89k stars 4.89k forks source link

nfsd4: kernel oops #704

Closed raffipl closed 7 years ago

raffipl commented 9 years ago

Hello,

I am getting kernel oops during sending files to raspberry pi via nfs. My raspberry pi works as home wifi router (hostapd) and backup server (nfsd).

REPRODUCTION

PRECONDITIONS

Software on raspberrypi:

Laptop with mounted backup folder; /etc/fstab content: (...) router:/mnt/Backup /mnt/Backup nfs rw,hard,intr,async,fsc 0 0 (...)

STEPS

  1. Start data transfer via nfs (in my case this is backup of my laptop's files) <- high load of wifi and nfs
  2. Start iperf server on raspberry pi
  3. Start iperf client on laptop to test communication speed between raspberry and laptop <- additional load of wifi

    OOPS LOG

[ 4608.600412] Unable to handle kernel NULL pointer dereference at virtual address 00000008
[ 4608.637067] pgd = c0004000
[ 4608.669477] [00000008] *pgd=00000000
[ 4608.762596] Internal error: Oops: 17 [#1] PREEMPT ARM

Entering kdb (current=0xda01cb00, pid 2530) Oops: (null)
due to oops @ 0xbf24bb94

dCPU: 0 PID: 2530 Comm: nfsd Not tainted 3.12.28+ #709
dtask: da01cb00 ti: d92ca000 task.ti: d92ca000
PC is at set_nfsv4_acl_one+0x8/0x90 [nfsd]
LR is at nfsd4_set_nfs4_acl+0x12c/0x140 [nfsd]
pc : [<bf24bb94>]    lr : [<bf24c4c4>]    psr: 60000013
sp : d92cbe80  ip : 01f4e27e  fp : bf274dcc
r10: bf274a9c  r9 : da0e5130  r8 : da0e5020
r7 : 00000000  r6 : dadda518  r5 : 00000000  r4 : 00000000
r3 : 00004000  r2 : bf271714  r1 : 00000000  r0 : ccf17908
Flags: nZCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment kernel
Control: 00c5387d  Table: 17518008  DAC: 00000015
dCPU: 0 PID: 2530 Comm: nfsd Not tainted 3.12.28+ #709
[<c001444c>] (unwind_backtrace+0x0/0xec) from [<c0011730>] (show_stack+0x10/0x14)
[<c0011730>] (show_stack+0x10/0x14) from [<c00820a4>] (kdb_dumpregs+0x28/0x50)
[<c00820a4>] (kdb_dumpregs+0x28/0x50) from [<c0085180>] (kdb_main_loop+0x370/0x6bc)
[<c0085180>] (kdb_main_loop+0x370/0x6bc) from [<c0087980>] (kdb_stub+0x164/0x380)
more>
Only 'q' or 'Q' are processed at more prompt, input ignored
[<c0087980>] (kdb_stub+0x164/0x380) from [<c007e984>] (kgdb_handle_exception+0x380/0x748)
[<c007e984>] (kgdb_handle_exception+0x380/0x748) from [<c0013bbc>] (kgdb_notify+0x24/0x50)
[<c0013bbc>] (kgdb_notify+0x24/0x50) from [<c0446728>] (notifier_call_chain+0x44/0x84)
[<c0446728>] (notifier_call_chain+0x44/0x84) from [<c04467e8>] (atomic_notifier_call_chain+0x34/0x48)
[<c04467e8>] (atomic_notifier_call_chain+0x34/0x48) from [<c0446834>] (notify_die+0x38/0x44)
[<c0446834>] (notify_die+0x38/0x44) from [<c00117fc>] (die+0xc8/0x390)
[<c00117fc>] (die+0xc8/0x390) from [<c043cf1c>] (__do_kernel_fault.part.10+0x54/0x74)
[<c043cf1c>] (__do_kernel_fault.part.10+0x54/0x74) from [<c0446468>] (do_page_fault+0x250/0x428)
[<c0446468>] (do_page_fault+0x250/0x428) from [<c0008394>] (do_DataAbort+0x34/0x98)
[<c0008394>] (do_DataAbort+0x34/0x98) from [<c0444bf8>] (__dabt_svc+0x38/0x60)
Exception stack(0xd92cbe38 to 0xd92cbe80)
be20:                                                       ccf17908 00000000
be40: bf271714 00004000 00000000 00000000 dadda518 00000000 da0e5020 da0e5130
more>
Only 'q' or 'Q' are processed at more prompt, input ignored
be60: bf274a9c bf274dcc 01f4e27e d92cbe80 bf24c4c4 bf24bb94 60000013 ffffffff
[<c0444bf8>] (__dabt_svc+0x38/0x60) from [<bf24bb94>] (set_nfsv4_acl_one+0x8/0x90 [nfsd])
[<bf24bb94>] (set_nfsv4_acl_one+0x8/0x90 [nfsd]) from [<00000000>] (  (null))

kdb>
popcornmix commented 9 years ago

What does "uname -a" report? Any non-default cmdline.txt options?

raffipl commented 9 years ago
pi@rapi1 ~ $ cat /boot/cmdline.txt
dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA0,115200 console=tty1 root=/dev/sda4 rootfstype=ext4 elevator=deadline rootwait rootdelay=5
pi@rapi1 ~ $ uname -a
Linux rapi1 3.12.28+ #709 PREEMPT Mon Sep 8 15:28:00 BST 2014 armv6l GNU/Linux
raffipl commented 9 years ago

Hello,

I've seen this issue also on Banana Pi - the same reproduction steps. I think this is a bug in nfsd.

Regards, Rafał Szklarski

popcornmix commented 9 years ago

Does it occur with 3.18 kernel? You can upgrade with:

sudo BRANCH=next rpi-update

See: http://www.raspberrypi.org/forums/viewtopic.php?f=29&t=93015

Ruffio commented 7 years ago

@popcornmix please consider to close this, as there has been no response to your question 31 Dec 2014 running 3.18