I have the strangest of problems on one of my installations. I have a custom server based on Karaf 2.3.0. I have installed it in several places with no problem. But, on one of our virtual servers running Windows Server 2003 SP2, I cannot start Karaf correctly due to the following:
log4j:ERROR A "org.apache.log4j.TTCCLayout" object is not assignable to a "org.apache.log4j.Layout" variable. log4j:ERROR The class "org.apache.log4j.Layout" was loaded by log4j:ERROR [org.apache.felix.framework.BundleWiringImpl@73305c] whereas object of type log4j:ERROR "org.apache.log4j.TTCCLayout" was loaded by [sun.misc.Launcher$AppClassLoader@360be0]. log4j:ERROR A "org.apache.log4j.TTCCLayout" object is not assignable to a "org.apache.log4j.Layout" variable. log4j:ERROR The class "org.apache.log4j.Layout" was loaded by log4j:ERROR [org.apache.felix.framework.BundleWiringImpl@73305c] whereas object of type log4j:ERROR "org.apache.log4j.TTCCLayout" was loaded by [sun.misc.Launcher$AppClassLoader@360be0]. log4j:ERROR A "org.apache.log4j.TTCCLayout" object is not assignable to a "org.apache.log4j.Layout" variable. log4j:ERROR The class "org.apache.log4j.Layout" was loaded by log4j:ERROR [org.apache.felix.framework.BundleWiringImpl@73305c] whereas object of type log4j:ERROR "org.apache.log4j.TTCCLayout" was loaded by [sun.misc.Launcher$AppClassLoader@360be0]. I then tried with a standard Karaf 2.3.0 and got the exact same error. The above errors only show up in the console since the logging system cannot initialize properly. It seems like a strange classloading issue but I fail to understand how it can happen. It looks like the JVM itself has loaded log4j classes making them incompatible with the "real" ones. Has anyone seen this before? Any clues? It's 32 bit Windows and I've tried with java 1.6.0_29 as well as 1.6.0_37. /Bengt