For this deployment, we will be using Elasticsearch version 6.5 (which is the latest version at the time of writing). This means that all subsequent components must be the same version. The base OS will be CentOS 7.6. While this specific deployment will be implemented on a local virtual machine (VM) setup, the concepts can still be applied to the cloud.
Elasticsearch will be deployed using 2 nodes on 2 vCPU VMs with 4 GB of RAM each (in Chapter 11, Designing an ELK Stack, we established that the minimum RAM required is about 2.5 GB). The underlying storage for the VMs is non-volatile memory express (NVMe), so some considerations need to be taken when replicating the setup somewhere else. In terms of space, the Elasticsearch nodes will have 64 GB of disk space each; the nodes will have the 64 GB disk mounted to the /var/lib/elasticsearch directory.
Logstash...