I've tried to write a c# program that logs to splunk via serilog logger.
I've tried to set up splunk to listen for the logging.
All running on my local machine.
My guess would be that I have not configured Splunk correctly.
Log.Logger = new LoggerConfiguration()
.WriteTo
.SplunkViaTcp(
new Serilog.Sinks.Splunk.SplunkTcpSinkConnectionInfo("127.0.0.1", 19000)
)
.CreateLogger();
while (true)
{
Log.Logger.Debug("Hello world");
Thread.Sleep(1000);
}
Splunk setup (Splunk is monitoring and showing windows events just fine): Data Inputs, Added 'TCP', 'set source type'=manual, 'source type'=log4net_xml
I've tried variations of 'source type' with no luck.
Any suggestions? Thanks, Anders