title: Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/log4j/ProvisionNode
body: <p>I'm running some very old legacy code, which has worked in the past. This time, it's giving me the following error</p>
  
  <pre><code>Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/log4j/ProvisionNode
  </code></pre>
  
  <p>The line that causes the error is</p>
  
  <pre><code>public static org.apache.log4j.Logger getLogger(java.lang.String name) { /* compiled code */ }
  </code></pre>
  
  <p>in the Logger class defined by log4j. I have log4j 1.2.17 included in the code, which is the most up-to-date version according to <a href="http://mvnrepository.com/artifact/log4j/log4j" rel="nofollow">maven</a>.</p>
  
  <p>Has anyone else seen this error? Any idea what it could be? Thanks!!</p>
  
  <p>Please note this problem has now been solved, the solution accepted below solves the problem. This is a specific issue with the <code>ProvisionNode</code> class, which is found in only certain log4j libraries. It should be left here and NOT marked as duplicate for others who encounter the same problem.</p>