Book Image

Solr Cookbook - Third Edition

By : Rafal Kuc
Book Image

Solr Cookbook - Third Edition

By: Rafal Kuc

Overview of this book

Table of Contents (18 chapters)
Solr Cookbook Third Edition
Credits
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
Index

Avoiding swapping


One of the crucial things when running your Solr instances in production is performance. What you want is to give your clients relevant results in the blink of an eye. If your clients have to wait for their results for too long, some of them might choose other vendors or sites that provide similar services. One of the things when running Java application such as Apache Solr is to ensure that the operating system won't write the heap to disk, to ensure that the part of the memory used by Solr won't be swapped at all. This recipe will show you how to achieve this on a Linux operating system.

Getting ready

Note that the following recipe is only valid when you are running Apache Solr on a Linux operating system. In addition to this, be advised that turning off swapping should only be done when you have enough memory to handle all the necessary applications in your system and you want to be sure that there won't be any swapping.

How to do it...

  1. Before turning off swapping, let's...