I tried to log ip address of the incoming request. I tried following configuration but it does not working for me its log in as "DEBUG".
Global.aspx
void Application_BeginRequest(object sender, EventArgs e)
{
log4net.ThreadContext.Properties["addr"] = Request.UserHostAddress;
}
RollingFileAppender
<layout type="log4net.Layout.PatternLayout">
<param name="ConversionPattern" value="%p{addr} %date [%thread] %-5level %logger - %message%newline"/>
</layout>
Log look like this
DEBUG 2018-11-20 06:22:50,328 [40] DEBUG Conference - loging successfully