Hitachi Content Platform​

 HCI, SOLR & Swappiness

  • Object Storage
  • Hitachi Content Intelligence HCI
Hedde van der Hoeven's profile image
Hedde van der Hoeven posted 02-16-2018 14:08

Dear community,

I think high memory usage on the OS  is inherent to the memory intensive requirement of SOLR. I've observed SOLR wanting to swap on the OS when performing queries.

Is it recommended to try to prevent the system swapping by reducing the value swappiness in RedHat?

For example, at the moment our SOLR instances are swapping and swappiness it set to 30, which basically means that when less than 30% memory is available the OS is inclined to swap. I don't think it's advisable to set it to 0, but my understanding is that setting it to 5 would make the OS less likely to swap.

Any thought/experience with this?

-Hedde


#HitachiContentIntelligenceHCI
Jared Cohen's profile image
Jared Cohen

Hedde,

I think you are absolutely correct that setting swappiness to 0 isn't generally advisable as it risks an OOMKill if memory pressure gets too high.

Setting the swappiness to 1 would imply that the OS should only ever use swap when absolutely necessary. This seems to be a somewhat common practice from what I see.

It can be tough to guess how exactly changing these settings will affect performance, but you can certainly try different values and see how performance is improved or hurt.