WARNING: no logs are available with the 'fluentd' log driver

1,269 views
Skip to first unread message

Sandeep 768

unread,
Jan 29, 2021, 5:17:43 AM1/29/21
to Fluentd Google Group
Hi Team,

I have created one container running java application producing logs to Console.
Created one Fluentd container which is configured to listen to above log driver.
I am getting 
WARNING: no logs are available with the 'fluentd' log driver

Please find below files for reference
In docker-compose.yml
version: '3'
###  Follow the deployment instructions in the Getting Started Readme. ###
services:
  demoapp:
    build: .
    restart: unless-stopped
    logging:
      driver: "fluentd"
      options:
        fluentd-address: localhost:24224
        fluentd-async-connect: "true"
        tag: demoservice
    links:
      - fluentd
    networks:
      - demo   
      
  fluentd:
    build: ./demo-fluentd
    restart: unless-stopped
#    volumes:
#      - webauth-logs:/opt/osp/tomcat/logs
    networks:
      - demo      
    ports:
      - "24224:24224"
      - "24224:24224/udp"
networks:
  demo:
    driver: bridge

fluent.cnf
<match demoservice>
  @type stdout
</match>


If required, I can share my java program as well which logs some messages to Console output in every 5 seconds

Regards,
Sandeep Pradhan

D OC

unread,
Jan 29, 2021, 4:49:30 PM1/29/21
to Fluentd Google Group
I'm having exactly the same problem.

Mr. Fiber

unread,
Feb 1, 2021, 2:34:33 AM2/1/21
to Fluentd Google Group
`localhost` can refer other containers? docker-compose support it?
Generally, `localhost` refers to container itself.

In addition, you need to add forward input plugin configuration to your fluentd configuration.

--
You received this message because you are subscribed to the Google Groups "Fluentd Google Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fluentd+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fluentd/0e4d0650-b40b-43ba-8d53-f8933a40e3f6n%40googlegroups.com.

D OC

unread,
Feb 1, 2021, 1:46:59 PM2/1/21
to Fluentd Google Group
For what it's worth, yesterday I realised that my setup was actually working, but the error is still happening.

I think the warning is more related to the output to the console than to the actual logging by fluentd.

Sandeep 768

unread,
Feb 3, 2021, 12:56:24 AM2/3/21
to Fluentd Google Group
Hi @repeatedly, thank for your reply.
Now I am able to collect logs both from Console Logger and File Logger.

There was some wrong configuration.
For log driver in Docker compose, if I use below source, it works fine.

<source>
  @type  forward
  port  24224
  bind 0.0.0.0  
</source>


Reply all
Reply to author
Forward
0 new messages