Questions tagged [serilog-sinks-elasticsearch]
16 questions
8
votes
1 answer
Serilog Elasticsearch 8 sink - Exception: Action/metadata line [1] contains an unknown parameter [_type]
Caught exception while performing bulk operation to ElasticSearch:
Elasticsearch.Net.ElasticsearchClientException: Request failed to execute. Call: Status code 400 from: POST /_bulk. ServerError: Type: illegal_argument_exception Reason:…

pkofos
- 109
- 1
- 6
3
votes
0 answers
Customize Serilog configuration after ReadFrom.Configuration
I have a ASP.NET Core 5 Web API application in which I am using Serilog like this:
public static class Program
{
public static void Main(string[] args)
{
Log.Logger = new LoggerConfiguration()
.WriteTo.Console()
…

alexbrina
- 131
- 6
2
votes
0 answers
ElasticSearch : Failure Sink always running
The logs are always being written to both Elastic Search and Local Log Files (when used as a Failure Sink) . This should not be the case. Local Log Files should be created only when the application fails to write logs to Elasticsearch
…

Adesh Agarwal
- 21
- 2
2
votes
1 answer
"Message" field is not send by Serilog ElasticSearch sink
I configured application to send logs to elastic search. I use https://www.elastic.co/cloud/
Everything seems to work fine except one thing: logs appear to not have "message" field (messageTemplate is there). I checked fiddler and it seems that…

Denys Isaev
- 91
- 5
2
votes
0 answers
How to force serilog to write log level as int in ElasticSearch
Currently, I'm using Serilog in my ASP.NET 5 project to log all my logs, and 2 Sinks: SQL Server and ElasticSearch.
Each log has a field "Level" by default, and in SQL Server it is written as integer, but it tries to write it as text to…

Fedir Katushonok
- 391
- 5
- 13
1
vote
1 answer
Serilog Logz.io not logging
I've been asked to add to my current Serilog sinks also Logz.io(I never used it), I normally use Seq from DataLust.
Here's my configuration part
{
"Name": "LogzIo",
"Args": {
"authToken": "sometoken",
…

advapi
- 3,661
- 4
- 38
- 73
1
vote
1 answer
How do I add the failureSink to elasticsearchSink
I add FileSink as failureSink to ElasticsearchSink from appSettings.json. But "Cannot create instance of type 'Serilog.Core.ILogEventSink' because it is either abstract or an interface." I get an error. How do I fixed it?
"Serilog": {
"Using": […

rdmzcn
- 151
- 1
- 3
- 13
1
vote
0 answers
serilog on ElasticsearchSinkOptions mapper_parsing_exception
when try to use elastic search with serilog show me this error on log some data
Failed to store event with template 'HttpClient Request: {RequestName} {@Request}' into Elasticsearch. Elasticsearch reports for index logs the following:…

Mehrdad
- 21
- 4
1
vote
1 answer
How to change Serilog field name posted to Elastic Search
I have gotten my serilog elastic search sink working. My problem now is I am looking for a way to override or remove the default out of the box fields naming convention when logs are posted to elastic search.
Sample in my…

Janus Torres
- 13
- 2
0
votes
1 answer
Resend failed messages with Serilog.Sinks.Elasticsearch
I'm using the Serilog.Sinks.Elasticsearch nuget package and Elasticsearch was missing shards for a while. As a result I've got a lot of failed messages saved as invalid-**.json files.
How do I resend those files?

Karsten
- 8,015
- 8
- 48
- 83
0
votes
0 answers
Serilog Elastic Search Sink better error message when can't communicate?
We are having an issue with identifying a problem with the serilog elastic search sink library. We end up with a stack trace and error message that provides nothing meaningful. I was able to test with different credentials and everything worked.…

grim
- 1
- 2
0
votes
1 answer
How to configure Elasticsearch sink with appsettings.json?
I am configuring Serilog for my application. The intent is to configure Serilog completely through appsettings.json. My problem is, everywhere on the web, Elasticsearch's configuration is explained with C# code.
Meanwhile, I have this in…

Ramayasket
- 11
- 5
0
votes
1 answer
Get Log Stream from Serilog in Elasticstack
I'm currently evaluating the Serilog.Sinks.Elasticsearch sink for Serilog in a .NET Core web service.
I successfully managed to pump some log messages through that sink using the following config (through JSON rather than code):
...
…

Tim Meyer
- 12,210
- 8
- 64
- 97
0
votes
0 answers
How to configure Serilog.Sinks.Elasticsearch to make it case insensitive in term queries?
The log in Elasticsearch has a property named level, the values are Error, Information, and so on. When searching the log use term query with "Error", the result is empty, but with "error", there is a list of loges.
How to make it case insensitive…

Think_ya
- 1
- 1
0
votes
1 answer
Override fields.RequestId in ElasticSearch logs from ASP.NET Core app
I have a simple ASP.NET Core console app with Serilog logging which writes logs to ElasticSearch:
private static void ConfigureLogging(bool isTestEnvironment)
{
var configuration = new ConfigurationBuilder()
.AddAppSettingsConfig()
…

Maxim
- 1,995
- 1
- 19
- 24