On 16.7.2021. 20:02, Hrvoje Popovski wrote:
> Hi all,
> 
> with source fetched few minutes ago i wanted to test bluhm@ diff
> https://marc.info/?l=openbsd-tech&m=162645141414262&w=2
> I've found out that with or without bluhm@ diff i'm getting panic. panic
> in attachment.
> 
> I'm sending traffic over ipsec tunnel from r620-1 box to x3550m4 box. If
> at one point while sending traffic over tunnel i hit "enter" over serial
> console on x3550m4, that box panic with this log:


with WITNESS ..


x3550m4# panic: malloc: out of space in kmem_map
Stopped at      db_enter+0x10:  popq    %rbp
    TID    PID    UID     PRFLAGS     PFLAGS  CPU  COMMAND
*289105  63905      0    0x100003          0    1K ksh
db_enter() at db_enter+0x10
panic(ffffffff81ea2c88) at panic+0xbf
malloc(10000,7f,1) at malloc+0x7b4
ufs_readdir(ffff800026e84c10) at ufs_readdir+0xf8
VOP_READDIR(fffffd887f03d460,ffff800026e84c78,fffffd887f7d7c60,ffff800026e84cbc)
at VOP_READDIR+0x50
sys_getdents(ffff800026f2b508,ffff800026e84d30,ffff800026e84d90) at
sys_getdents+0x161
syscall(ffff800026e84e00) at syscall+0x3a9
Xsyscall() at Xsyscall+0x128
end of kernel
end trace frame: 0x7f7ffffd7000, count: 7
https://www.openbsd.org/ddb.html describes the minimum info required in
bug reports.  Insufficient info makes it difficult to find and fix bugs.
ddb{1}>


ddb{1}> show locks
exclusive rrwlock inode r = 0 (0xfffffd887ec1dc48)
#0  witness_lock+0x333
#1  rw_enter+0x27f
#2  rrw_enter+0x56
#3  VOP_LOCK+0x5b
#4  vn_lock+0xad
#5  sys_getdents+0xfe
#6  syscall+0x3a9
#7  Xsyscall+0x128
exclusive kernel_lock &kernel_lock r = 0 (0xffffffff82306b40)
#0  witness_lock+0x333
#1  syscall+0x29e
#2  Xsyscall+0x128



ddb{1}> show reg
rdi                                0
rsi                             0x14
rbp               0xffff800026e848d0
rbx                          0x10000    __ALIGN_SIZE+0xf000
rdx               0xfe00000000000003
rcx                            0x282
rax                             0x28
r8                 0x101010101010101
r9                                 0
r10                                0
r11               0xe254fbd981f43f47
r12               0xffff8000219baa00
r13                          0x10000    __ALIGN_SIZE+0xf000
r14                                0
r15               0xffffffff81ea2c88    apollo_udma100_tim+0xc745
rip               0xffffffff8139d200    db_enter+0x10
cs                               0x8
rflags                         0x286
rsp               0xffff800026e848d0
ss                              0x10
db_enter+0x10:  popq    %rbp


ddb{1}> ps
   PID     TID   PPID    UID  S       FLAGS  WAIT          COMMAND
 38747  389002  68287     68  3        0x90  select        isakmpd
 68287  379577      1      0  3        0x80  netio         isakmpd
*63905  289105      1      0  7    0x100003                ksh
 51457  163250      1      0  3    0x100098  poll          cron
 77909  402925  35691     95  3    0x100092  kqread        smtpd
 78088   37152  35691    103  3    0x100092  kqread        smtpd
 62475  202424  35691     95  3    0x100092  kqread        smtpd
 33104  393361  35691     95  3    0x100092  kqread        smtpd
 99817  462713  35691     95  3    0x100092  kqread        smtpd
 49139  379482  35691     95  3    0x100092  kqread        smtpd
 35691  127563      1      0  3    0x100080  kqread        smtpd
 60575  345518      1      0  3        0x88  select        sshd
 42089  129781      1      0  3    0x100080  poll          ntpd
 13806  436163  95467     83  3    0x100092  poll          ntpd
 95467  117285      1     83  3    0x100092  poll          ntpd
 68954  146234  99233     74  3    0x100092  bpf           pflogd
 99233   26243      1      0  3        0x80  netio         pflogd
 46731   44450  83208     73  3    0x100090  kqread        syslogd
 83208  298754      1      0  3    0x100082  netio         syslogd
 24108  326233      1      0  3    0x100080  kqread        resolvd
 86229  481448      0      0  3     0x14200  bored         smr
 90881   31129      0      0  3     0x14200  pgzero        zerothread
  3369  196147      0      0  3     0x14200  aiodoned      aiodoned
 91637   24402      0      0  3     0x14200  syncer        update
 10524  225039      0      0  3     0x14200  cleaner       cleaner
 98418  474258      0      0  3     0x14200  reaper        reaper
  4887  253001      0      0  3     0x14200  pgdaemon      pagedaemon
 72437  269608      0      0  3     0x14200  bored         crynlk
 21023  435965      0      0  3     0x14200  bored         crypto
  3751  454766      0      0  3     0x14200  usbtsk        usbtask
 10715  377531      0      0  3     0x14200  usbatsk       usbatsk
 60934   18965      0      0  3  0x40014200  acpi0         acpi0
 43187  352600      0      0  7  0x40014200                idle11
 21339   40638      0      0  7  0x40014200                idle10
 97154  350372      0      0  7  0x40014200                idle9
 10084  112242      0      0  7  0x40014200                idle8
 30863  355862      0      0  7  0x40014200                idle7
 54728  399670      0      0  7  0x40014200                idle6
 36057  271351      0      0  7  0x40014200                idle5
 11048  423338      0      0  7  0x40014200                idle4
 32384  489043      0      0  7  0x40014200                idle3
 67080  244754      0      0  7  0x40014200                idle2
 20726  364038      0      0  3  0x40014200                idle1
 96812  322959      0      0  3     0x14200  bored         sensors
  5686  387933      0      0  3     0x14200  bored         softnet
 73644  400748      0      0  3     0x14200  bored         systqmp
 35175  298923      0      0  3     0x14200  bored         systq
 23660   24371      0      0  3  0x40014200  bored         softclock
 92986   28837      0      0  7  0x40014200                idle0
     1   25661      0      0  3        0x82  wait          init
     0       0     -1      0  3     0x10200  scheduler     swapper


ddb{1}> trace /t 0t289105
           [143/18336]
uvm_fault(0xfffffd87864fc2e8, 0x2, 0, 1) -> e
kernel: page fault trap, code=0
Faulted in DDB; continuing...


ddb{1}> show malloc
           Type InUse  MemUse  HighUse   Limit  Requests Type Lim
         devbuf 98095  50960K   50971K  78643K     99896        0
            pcb    13      8K       8K  78643K        13        0
         rtable   179      5K       6K  78643K       761        0
         ifaddr   164     21K      23K  78643K       219        0
       counters   274    206K     212K  78643K       322        0
       ioctlops     0      0K       4K  78643K      1937        0
            iov     0      0K       0K  78643K        16        0
          mount     9      9K       9K  78643K         9        0
            log     0      0K      13K  78643K     88672        0
         vnodes  1194     75K      75K  78643K      1210        0
      UFS quota     1     32K      32K  78643K         1        0
      UFS mount    37     87K      87K  78643K        37        0
            shm     2      1K       1K  78643K         2        0
         VM map     2      1K       1K  78643K         2        0
            sem     2      0K       0K  78643K         2        0
        dirhash    30      5K       5K  78643K        57        0
           ACPI  3991    479K     519K  78643K     15335        0
      file desc     2      1K       1K  78643K         5        0
           proc    67     63K     124K  78643K      1469        0
    NFS srvsock     1      0K       0K  78643K         1        0
     NFS daemon     1     16K      16K  78643K         1        0
       in_multi    48      3K       3K  78643K        72        0
    ether_multi    13      0K       0K  78643K        34        0
    ISOFS mount     1     32K      32K  78643K         1        0
  MSDOSFS mount     1     16K      16K  78643K         1        0
           ttys    43    201K     201K  78643K        43        0
           exec     0      0K       3K  78643K      1363        0
     pfkey data     0      0K       2K  78643K       403        0
            tdb     3      1K       2K  78643K         6        0
     xform_data    40      1K   70482K  78643K  13074964        0
        pagedep     1      8K       8K  78643K         1        0
       inodedep     1     32K      32K  78643K         5        0
         newblk     1      0K       0K  78643K         1        0
       indirdep     0      0K      16K  78643K         4        0
        VM swap     7   2326K    2326K  78643K         7        0
       UVM amap   210      7K      89K  78643K      7098        0
       UVM aobj     3      2K       2K  78643K         3        0
            USB    84     28K      28K  78643K        98        0
     USB device    19      1K       1K  78643K        19        0
        witness     1   1600K    1600K  78643K         1        0
        memdesc     1      4K       4K  78643K         1        0
    crypto data     3      1K       1K  78643K         5        0
    IPsec creds     3      0K       0K  78643K        60        0
            NDP    16      0K       0K  78643K        24        0
           temp    53   4238K    4242K  78643K     14722        0
         kqueue    12     19K      45K  78643K        31        0
      SYN cache     2     16K      16K  78643K         2        0


Reply via email to