log-pilot
log-pilot copied to clipboard
Collect logs for docker containers
--label aliyun.logs.catalina=stdout --label aliyun.logs.access=/usr/local/tomcat/logs/localhost_access_log.*.txt 如上面 修改成 --label aliyun.logs.appname=stdout --label aliyun.logs.appname=/usr/local/tomcat/logs/localhost_access_log.*.txt 是不是 上面 的label 是有一个生效
虽然看到在filebeat中的prospectors配置了如下参数,保证可以清理state信息 ``` tail_files: false close_inactive: 2h close_eof: false close_removed: true clean_removed: true close_renamed: false ``` 但是有个问题就是,这个目录下的prospectors.d下的文件是动态生成的,在destory container 时候,该config文件会被删除,而registry状态信息文件一直在增加
Hi team, This PR is an alternative for #244 , we have been tried to use the #244 PR proposed configuration way, however, it didn't work well in my cluster....
As the PR title said, this PR is going to add a handler for container envs which has prefix with `COM_ALIYUN_META_ENVS_`, those envs will be processed, and the name which...
如题,比如我想把pod分配得到的IP作为elk录入日志记录的一个tag,目前是很难做到的,因为一般是我在启动容器之后才能知道拿到了哪个IP,log-pilot目前这块我看到是写死了一部分 [代码](https://github.com/AliyunContainerService/log-pilot/blob/af6da63aa35e3377c8e44dc951c4ea8ffe7c0bb5/pilot/pilot.go#L324) 。 能否支持像自定义配置那样,自定义把哪些env或者label作为采集到elk日志的tags的一部分?这样的话,比如pod ip我可以通过如下方式映射到env,然后再指定让log-pilot消费该env作为tag: ``` - name: MY_POD_IP valueFrom: fieldRef: fieldPath: status.podIP ``` 谢谢!
环境版本:kubernetes1.16.3,log-pilot版本0.9.6/0.9.7,ELK版本6.8.4。 只有设置容器环境变量,elk才能接受到日志
无法提交`json`格式的数据到阿里云日志服务,我确定这个不是log-pilot 的bug就是阿里云日志服务的问题,因为日志格式改成`none`后可以正常提交。劳烦大佬们有空帮解答一下。 控制台输出错误信息为: ```shell 2019-06-06 16:10:49 +0800 [error]: #0 Could not puts logs to aliyun sls: LogException: { ErrorCode: PostBodyInvalid ErrorMessage: fail to parse protobuf RequestId: ["5CF8CA891DD1282C5BA272C4"] } ``` 目标日志收集服务docker-compose代码:...
我理解的sidecar模式就是在一个pod中有个agent作为采集日志的镜像,我不知道log-pilot是否支持
{"@timestamp":"2020-01-17T09:26:21.652Z","@metadata":{"beat":"filebeat","type":"doc","version":"6.1.1"},"beat":{"version":"6.1.1","name":"1d305b0ae23a","hostname":"1d305b0ae23a"},"offset":20831,"index":"honeylog","prospector":{"type":"log"},"docker_container":"honey-log","topic":"honeylog","docker_app":"compose","source":"/host/logs/v3/honeyLog/honeyLog.log","json":{},"message":"09:26:16.613 [AsyncResolver-bootstrap-executor-0] INFO c.n.d.s.r.aws.ConfigClusterResolver - Resolving eureka endpoints via configuration","docker_service":"honey-log"} 这时间跟上海时间差了8个小时。是不是因为时间不对,日志才不能输入到es中? docker-compose.yml version: '3' services: honey-log: container_name: honey-log image: registry.cn-hangzhou.aliyuncs.com/img-etest/honey-log:v3.0-e81761a ports: - 8051:8051 volumes: - /logs/v3/honeyLog:/logs/v3/honeyLog labels: - "aliyun.logs.honeylog=/logs/v3/honeyLog/honeyLog.log" -...
 用的是elasticsearch7.4版本,elasticsearch一直报错,采集不到日志信息