The LogLevel section in the appsettings.json file does not affect the .NET Framework tracing mechanism, which is used by XPO to log the queries, still we have a few work arounds for a Netcore app

  1. We can implement our own logger as shown here
  2. We can set the value of the logging switch by reflection using the following snippet
private static void EnableXpoDebugLog()
    FieldInfo xpoSwitchF = typeof(ConnectionProviderSql).GetField("xpoSwitch", System.Reflection.BindingFlags.Static | System.Reflection.BindingFlags.NonPublic);
    TraceSwitch xpoSwitch = (TraceSwitch)xpoSwitchF.GetValue(null);
    xpoSwitch.Level = TraceLevel.Info;

I actually use the second work around in my own projects.

If you want to learn more about the logging mechanism of XPO you can take a look to the following articles