Bug 192321 - Issuing ctladm getsync for non existing lun caused crash and reboot
Summary: Issuing ctladm getsync for non existing lun caused crash and reboot
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: 10.0-STABLE
Hardware: amd64 Any
: --- Affects Some People
Assignee: freebsd-bugs mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-08-01 22:30 UTC by Nikolay Denev
Modified: 2014-08-06 08:26 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nikolay Denev 2014-08-01 22:30:15 UTC
Here's a transcript of a shell session and after the last command for a non existing LUN the box rebooted.

[0:18][root@nas:ndenev]#ctladm devlist
LUN Backend       Size (Blocks)   BS Serial Number    Device ID       
  0 block             976707584  512 MYSERIAL   0     MYDEVID   0     
  1 block             976773168  512 MYSERIAL   1     MYDEVID   1     
  2 block             536870912  512 MYSERIAL   2     MYDEVID   2     
[0:18][root@nas:ndenev]#ctladm getsync 0:0
0:0: sync interval: 0
[0:18][root@nas:ndenev]#ctladm getsync 0:1
0:1: sync interval: 0
[0:18][root@nas:ndenev]#ctladm getsync 0:2
0:2: sync interval: 0
[0:18][root@nas:ndenev]#ctladm getsync 0:3


OS : FreeBSD nas.home.lan 10.0-STABLE FreeBSD 10.0-STABLE #9 r269182: Wed Jul 30 23:18:23 UTC 2014     root@nas.home.lan:/usr/obj/usr/src/sys/NAS  amd64

Console transcript of the crash :

instruction pointer     = 0x20:0xffffffff802b2a06                               
stack pointer           = 0x28:0xfffffe0096031700                               
frame pointer           = 0x28:0xfffffe0096031990                               
code segment            = base rx0, limit 0xfffff, type 0x1b                    
                        = DPL 0, pres 1, long 1, def32 0, gran 1                
processor eflags        = interrupt enabled, resume, IOPL = 0                   
current process         = 1200 (ctladm)                                         
trap number             = 12                                                    
panic: page fault                                                               
cpuid = 1                                                                       
KDB: stack backtrace:                                                           
#0 0xffffffff80510570 at kdb_backtrace+0x60                                     
#1 0xffffffff804d51d5 at panic+0x155    ??                                      
#2 0xffffffff806eadff at trap_fatal+0x38??                                      
#3 0xffffffff806eb118 at trap_pfault+0x308                                      
#4 0xffffffff806ea7c0 at trap+0x4a0                                             
#5 0xffffffff806d0f82 at calltrap+0x8                                           
#6 0xffffffff803d2cb4 at devfs_ioctl_f+0x114                                    
#7 0xffffffff80527405 at kern_ioctl+0x255                                       
#8 0xffffffff8052715c at sys_ioctl+0x13c                                        
#9 0xffffffff806eb731 at amd64_syscall+0x351                                    
#10 0xffffffff806d126b at Xfast_syscall+0xfb                                    
Uptime: 5m11s                                                                   
Automatic reboot in 15 seconds - press a key on the console to abort