在Debian上配置Filebeat网络设置步骤如下:
安装Filebeat
sudo apt update
sudo apt install filebeat
编辑配置文件
修改 /etc/filebeat/filebeat.yml,关键网络配置包括:
server.port(默认5044)。network.host 为特定IP(如 192.168.1.100)。output.elasticsearch.hosts)。xpack.security.transport.ssl.keystore.path 等)。http.proxy.host 和 http.proxy.port 指定代理。配置防火墙
若使用ufw,开放Filebeat端口(默认5044):
sudo ufw allow 5044/tcp
重启服务并验证
sudo systemctl restart filebeat
sudo tail -f /var/log/filebeat/filebeat # 查看日志确认运行状态
说明:具体配置需根据实际网络环境调整,如需监控网络流量,需在 filebeat.inputs 中启用 packetbeat 模块并指定端口。详细文档可参考Filebeat官方指南。