Skip to content
Dipsy Kapoor edited this page Aug 11, 2017 · 16 revisions
  1. Cannot Compile Karma

    Things to check:

    • You have the correct version of Java (see installation instructions)
    • Recreate your Maven repository cache, by removing the m2 directory. The files are in the following places:
    • Unix/Mac OS X – ~/.m2
    • Windows – C:\Documents and Settings\{your-username}\.m2
  2. I get Fatal error compiling: invalid target release: 1.7 when I try to run Karma

    Make sure you have JDK 1.7 and JAVA_HOME environment variable points to it.

  3. It says "Failed to execute goal org.eclipse.jetty:jetty-maven-plugin:9.0.5.v20130815:run (default-cli) on project webkarma: Failure: Address already in use"

    Karma uses the default port of 8080 which may already be in use by your system. Try a different port say 9999 using mvn -Djetty.port=9999 jetty:run

  4. I get java.lang.ClassNotFoundException: com.mysql.jdbc.Driver when I load a table from MySQL

    Add the dependency for the mysql connector to karma-jdbc/pom.xml, karma-web/pom.xml and karma-offline/pom.xml:

    <dependency>
      <groupId>mysql</groupId>
      <artifactId>mysql-connector-java</artifactId>
      <version>X.Y.Z</version>
    </dependency>
    

    where X.Y.Z is the version of the library obtained from MySQL/Oracle. Example:

    <dependency>
      <groupId>mysql</groupId>
      <artifactId>mysql-connector-java</artifactId>
      <version>5.1.17</version>
    </dependency>
    
  5. In Windows, when I re-publish my model or JSON or any other file, it gives me an Error and is not able to perform the operation.

    This is because of an issue with Jetty opening files using memory-map in windows that locks the files and hence Karma is not able to overwrite them. To turn this feature off in Windows, edit karma-web\src\main\webapp\WEB-INF\web.xml. Search "Uncomment this for Windows" and uncomment the <servlet> tag under the comment. This is how your web.xml should look like:

    <servlet>
     <servlet-name>R2RMLMappingTripleStoreServlet</servlet-name>
     <servlet-class>edu.isi.karma.webserver.R2RMLMappingTripleStoreServlet</servlet-class>
    </servlet>
    
    <!-- Uncomment this for Windows, This is to fix an issue with
    Jetty opening files using memory map in Windows that creates lock
    and then Karma cannot overwrite those files -->
    <servlet>
      <servlet-name>default</servlet-name>
      <servlet-class>org.eclipse.jetty.servlet.DefaultServlet</servlet-class>
      <init-param>
        <param-name>useFileMappedBuffer</param-name>
        <param-value>false</param-value>
      </init-param>
      <load-on-startup>1</load-on-startup>
     </servlet>
       
    <servlet-mapping>
     <servlet-name>KarmaServlet</servlet-name>
     <url-pattern>/KarmaServlet</url-pattern>
    </servlet-mapping>
    

Now restart Karma and the issue should be resolved

Clone this wiki locally