Bug #6395
closedcannot tune segkpsize up
100%
Description
It's not possible to tune segkpsize up, the system panics with 'startup: cannot attach segkp' due to overlapping segments. The reason is that layout_kernel_va() builds a segment layout based on the value of segkpsize before /etc/system is read. So if the value gets increased through /etc/system afterwards, the system tries to create a segment that doesn't fit anymore into the calculated layout.
Also, the sanity checks for segkpsize are done before the value is read.
It has been broken by
commit 35b1ab9964f57b69ba8f03d2962f94036aa78c57 Author: josephb <none@none> Date: Wed Aug 8 11:14:39 2007 -0700 6582841 boot_/final_kerneheap and kernelheap_extend() nonsense needs to be ripped out 6507265 amd64 Solaris will fail on more than 1 Terabyte of memory
which moved the layout part from after kmem_init() to before it. kmem_init() reads /etc/system through mod_read_system_file().
Updated by Alasdair Lumsden almost 3 years ago
Arne Jansen wrote:
It's not possible to tune segkpsize up, the system panics with 'startup: cannot attach segkp'...
Hit the same issue when attempting to up the number of threads, as 88k LWPS on a modern 1TB RAM system is too low.
To work around this we've compiled a custom SmartOS image but doing this for every release is going to be tedious.
Should the default value just be upped as a quick fix?
Updated by Carlos Neira over 2 years ago
- Status changed from New to In Progress
- % Done changed from 0 to 20
Updated by Electric Monk about 2 years ago
- Status changed from In Progress to Closed
- % Done changed from 90 to 100
git commit 860b5cc8ca1cde8ee07c510e06bf21ad9103bb69
commit 860b5cc8ca1cde8ee07c510e06bf21ad9103bb69 Author: cneira <cneirabustos@gmail.com> Date: 2021-05-13T04:10:03.000Z 6395 cannot tune segkpsize up Reviewed by: Robert Mustacchi <rm@fingolfin.org> Reviewed by: Andy Fiddaman <andy@omnios.org> Approved by: Dan McDonald <danmcd@joyent.com>