You need to install the filebeat on instances where you want to collect the logs only. In your case you dont need to install the filebeat where your ELK is installled (server 3).
server 1 (filebeat) collect the logs and can send to logstash or directly elasticsearch <server 3>.
Server 2 (Filebeat) collect the logs and can send to logstash or directly elasticsearch <server 3>.
If you want to collect the logs of server 3 you can directly collect the same through logstash.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.