Hi @Shoeb_Masum,
First of all a big complement for you to want to learn how to set everything up and doing it thoughtfully. All these answers are assuming a 1 node elastic cluster.
You could use a single instance but I'd recommend doing two. One instance for the APM integration (read Elastic Agent), and the other for Elasticsearch and Kibana.
It really depends how much data you are going to be sending and saving, but elastic says to try 4GB when running locally in docker. Personally, I'd start at 8G. Sounds like you are using VMs so adding more space shouldn't be a big deal, but start at 500G. CPU should be fine at normal defaults.
If it is just APM it's going to look like: c * a * o = bandwidth, where c is the number of apm clients, a is the amount of data each client sends in a given time period, and o is a constant to factor in the network communication overhead. In reality though starting small and adding one or two apm clients at a time will give you the concreate numbers you can use to project bandwidth (and infrastructure resources).
From my understanding the apm agents are going to talk to Elastic Agent (either through fleet or installed as a stand alone program). The elastic agent will then send all the data on to the elastic cluster from there. Therefore adding more apm agents should just cause a slight increase in resources at the elastic agent host. Speaking of that here's what I recommend:
- VM instance 1 (elastic & kibana), 8GB memory, 500GB storage.
- VM instance 2 (Elastic agent), 8GB memory, 50GB storage. Probably can get away with less storage.
I think you'll need to decide if you are going to install elastic agent with fleet, or as a standalone install.
As your needs grow you can add dedicated master nodes, additional data nodes, split out kibana to it's own vm instances, etc.
Good luck!