Welcome to Oracle Communities
Register and Participate in Oracle's online communities. Learn from thousands of experts, get answers to your questions and share knowledge with peers.
When you look at AWS, it has a possibility to create rather easily an Elastic Search Cluster. With a few simple clicks you have a cluster up and running.
Unfortunately the Oracle Cloud Infrastructure doesn't have this feature yet, but that doesn't mean you can't setup Elastic Search on OCI . Using the magic Terraform wand magic is about to happen...
On github there is an OCI ELK plugin available on https://github.com/cloud-partners/oci-elasticsearch, so perform an easy
git clone https://github.com/cloud-partners/oci-elasticsearch.git
for a local repository download, which leaves you with a bunch of files:
in the env-vars you will have tot set your region, compartment and userid, and also you fingerprint and ssh keypairs which wasj generated with
ssh-keygen -b 2048 -t rsa
and left the keypairs in the .ssh directory, so the env-vars would look like this
Some other files could acquire my attention:
other files specified loadbalancer, compute nodes, storage etc.
Next run the env-vars script, another way is to put it into your bash_profile
Immediately it returned some errors like:
error: oci_core instance.Bastion Host: "image": required field is not set
To debug this error, I set the terraform loglevel to trace
Still, this did not bring me al lot of new information, until I performed terraform version, which gave the out put that the current version for this provider was outdated.
To upgrade the provided, the binary had to be dowloaded and replaced
sudo cp -p terraform /usr/local/bin/
and in the directory of the oci elk provider:
which upgraded the provider.
Finally, explicitly the version had to be set in the provider.tf:
When ready the terraform plan and terraform apply went well and gave me a fully running ELK cluster on OCI.
In part 2, I will dive deeper in how to setup Elasic Search, Kibana and Logstash.