2-2、安装Filebeat

安装filebeat
第1步:安装Filebeat
开始之前:如果尚未安装Elastic Stack,请立即执行此操作。 请参阅Getting started with the Elastic Stack.
要下载并安装Filebeat,请使用适用的系统的命令(deb for Debian/Ubuntu, rpm for Redhat/Centos/Fedora, mac for OS X, docker for any Docker platform, and win for Windows
注意:如果使用Apt或Yum,可以从install Filebeat from our repositories更轻松地更新到最新版本。
有关其他安装选项,请参阅 download page ,例如32位镜像。
deb:
curl -L -O https://artifacts.elastic.co/downloads/beats/filebeat/filebeat-6.3.2-amd64.deb sudo dpkg -i filebeat-6.3.2-amd64.deb
rpm:
curl -L -O https://artifacts.elastic.co/downloads/beats/filebeat/filebeat-6.3.2-x86_64.rpm sudo rpm -vi filebeat-6.3.2-x86_64.rpm
mac:
curl -L -O https://artifacts.elastic.co/downloads/beats/filebeat/filebeat-6.3.2-darwin-x86_64.tar.gz tar xzvf filebeat-6.3.2-darwin-x86_64.tar.gz
docker:
docker pull docker.elastic.co/beats/filebeat:6.3.2
win:
    1. 从 downloads page.下载Filebeat Windows zip文件。
    2. 将zip文件的内容解压缩到C:Program Files。
    3. 将filebeat- <version> -windows目录重命名为Filebeat。
    4. 以管理员身份打开PowerShell提示符(右键单击PowerShell图标,然后选择“以管理员身份运行”)。
    5. 在PowerShell提示符下,运行以下命令将Filebeat安装为Windows服务:
PS > cd 'C:Program FilesFilebeat' PS C:Program FilesFilebeat> .install-service-filebeat.ps1
注意:如果在系统上禁用了脚本执行,则需要为当前会话设置执行策略以允许脚本运行。 例如:PowerShell.exe -ExecutionPolicy UnRestricted -File .install-service-filebeat.ps1.
参考链接:
原文地址:https://www.cnblogs.com/jmucai/p/9583923.html