# rctl throttle bug



## CyberCr33p (Dec 13, 2020)

I run this command:

`rctl -a user:test:readiops:throttle=0`

and system becomes unresponsive.

Is this a bug?


----------



## CyberCr33p (Dec 13, 2020)

Fatal trap 18: integer divide fault while in kernel mode

```
cpuid = 4; apic id = 04
instruction pointer     = 0x20:0xffffffff80bb2fb7
stack pointer           = 0x28:0xfffffe00c5b42200
frame pointer           = 0x28:0xfffffe00c5b422a0
code segment            = base 0x0, limit 0xfffff, type 0x1b
                        = DPL 0, pres 1, long 1, def32 0, gran 1
processor eflags        = interrupt enabled, resume, IOPL = 0
current process         = 53057 (bash)
trap number             = 18
panic: integer divide fault
cpuid = 4
time = 1607862919
KDB: stack backtrace:
#0 0xffffffff80c0a8f5 at kdb_backtrace+0x65
#1 0xffffffff80bbeb1b at vpanic+0x17b
#2 0xffffffff80bbe993 at panic+0x43
#3 0xffffffff8108f911 at trap_fatal+0x391
#4 0xffffffff8108ed97 at trap+0x67
#5 0xffffffff81066f38 at calltrap+0x8
#6 0xffffffff80bb03df at racct_add_buf+0x26f
#7 0xffffffff80c6c0ea at breadn_flags+0xda
#8 0xffffffff80c70a5f at vfs_bio_getpages+0x33f
#9 0xffffffff80ed01a7 at ffs_getpages+0x77
#10 0xffffffff8124911b at VOP_GETPAGES_APV+0x7b
#11 0xffffffff80f1c932 at vnode_pager_getpages+0x72
#12 0xffffffff80f13382 at vm_pager_get_pages+0x22
#13 0xffffffff80b78018 at exec_map_first_page+0x2a8
#14 0xffffffff80b76965 at kern_execve+0x2c5
#15 0xffffffff80b7635c at sys_execve+0x4c
#16 0xffffffff810904c7 at amd64_syscall+0x387
#17 0xffffffff8106785e at fast_syscall_common+0xf8
Uptime: 3m41s
```


----------



## PMc (Dec 13, 2020)

I don't think it's a bug. It appears to be a divide by zero, which is undefined by it's very nature.
Is that configuration useful in any way?


----------



## CyberCr33p (Dec 13, 2020)

It's not useful but I believe RCTL should not allow to configure it with zero value.

I submit a bug report here: PR 251803


----------

