fluentbit changes for replicaset
Update the td-agent-bit.conf
Update container.conf file in this path: /etc/opt/microsoft/omsagent//conf/omsagent.d restart omsagent: /opt/microsoft/omsagent/bin/service_control restart
Start fluent-bit with this conf file: /opt/td-agent-bit/bin/td-agent-bit -c /etc/td-agent-bit/td-agent-bit.conf
To build an output plugin:
You will need an so file generated.
Install and configure go using this link:
https://www.linode.com/docs/development/go/install-go-on-ubuntu/ ( make sure to install version 1.10 and above or it will fail with string errors)
(or https://medium.com/@patdhlk/how-to-install-go-1-9-1-on-ubuntu-16-04-ee64c073cd79)
follow the first link to configure paths properly.
Create folder in
#install fluentbit on omsagent's pod
wget -qO - https://packages.fluentbit.io/fluentbit.key | sudo apt-key add -
sudo echo "deb https://packages.fluentbit.io/ubuntu/xenial xenial main" >> /etc/apt/sources.list
sudo apt-get update
sudo apt-get install td-agent-bit sqlite3 libsqlite3-dev
#start fluent-bit
/opt/td-agent-bit/bin/td-agent-bit -c /etc/td-agent-bit/td-agent-bit.conf -e
#To run multiple plugins, /opt/td-agent-bit/bin/td-agent-bit -c /etc/td-agent-bit/td-agent-bit.conf -e -e <path to another .so file>
#To forward to a port and get the output from the input plugin, make the changes in the conf file - td-agent-bit.conf and container.conf Make sure to run the fluentbit before restarting the omsagent. If the fluentbit is not running when the omsagent is restarted things dont work as expected.