title: Spring log4j:WARN No appenders could be found for logger (com.classname). log4j:WARN Please initialize the log4j system properly
body: <p>When I am running my springboot application, I am getting this error</p>
  <pre><code>log4j:WARN No appenders could be found for logger (com.system.Config).
  log4j:WARN Please initialize the log4j system properly.
  </code></pre>
  <p>I added log4j2.xml in the src/main/resources and I added the below configurations also.</p>
  <pre><code>&lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-web&lt;/artifactId&gt;
              &lt;exclusions&gt;
                  &lt;exclusion&gt;
                      &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
                      &lt;artifactId&gt;spring-boot-starter-logging&lt;/artifactId&gt;
                  &lt;/exclusion&gt;
              &lt;/exclusions&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-log4j2&lt;/artifactId&gt;
          &lt;/dependency&gt;
  </code></pre>
  <p>Still my logs are not getting read.</p>