I was running the command in the directory named trunk. I made another attempt trying to run it in the directory named target, where giraph-0.2-SNAPSHOT-for-hadoop-0.20.203.0-jar-with-dependencies.jar is.

When I tried

hadoop jar giraph-0.2-SNAPSHOT-for-hadoop-0.20.203.0-jar-with-dependencies.jar org.apache.giraph.examples.SimpleShortestPathsVertex shortestPathsInputGraph shortestPathsOutputGraph 0 3

I got this:

Exception in thread "main" java.lang.NoSuchMethodException: org.apache.giraph.examples.SimpleShortestPathsVertex.main([Ljava.lang.String;)
    at java.lang.Class.getMethod(Class.java:1605)
    at org.apache.hadoop.util.RunJar.main(RunJar.java:150)

When I tried

hadoop jar giraph-0.2-SNAPSHOT-for-hadoop-0.20.203.0-jar-with-dependencies.jar org.apache.giraph.GiraphRunner org.apache.giraph.examples.SimpleShortestPathsVertex -if org.apache.giraph.lib.JsonBase64VertexInputFormat -ip shortestPathsInputGraph -of org.apache.giraph.lib.JsonBase64VertexOutputFormat -op shortestPathsOutputGraph -w 3

I got this:

Exception in thread "main" java.lang.ClassNotFoundException: org.apache.giraph.lib.JsonBase64VertexInputFormat
    at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:169)
    at org.apache.giraph.GiraphRunner.run(GiraphRunner.java:164)
    at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:65)
    at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:79)
    at org.apache.giraph.GiraphRunner.main(GiraphRunner.java:247)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.hadoop.util.RunJar.main(RunJar.java:156)


What do these errors mean?
Did anyone have success in running this example?
If yes, could you help me, please?




2012/9/29 rodrigo zerbini <rodrigo.zerbini@gmail.com>
Hello. I'm trying to run the Shortest Paths Example but it doesn't work.

I'm doing:

hadoop jar giraph-0.2-SNAPSHOT-for-hadoop-0.20.203.0-jar-with-dependencies.jar org.apache.giraph.examples.SimpleShortestPathsVertex shortestPathsInputGraph shortestPathsOutputGraph 0 3

I got this error:

Exception in thread "main" java.io.IOException: Error opening job jar:
giraph-0.2-SNAPSHOT-for-hadoop-0.20.203.0-jar-with-dependencies.jar
at org.apache.hadoop.util.RunJar.main(RunJar.java:90)
Caused by: java.util.zip.ZipException: error in opening zip file
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.<init>(ZipFile.java:127)
 at java.util.jar.JarFile.<init>(JarFile.java:135)
at java.util.jar.JarFile.<init>(JarFile.java:72)
 at org.apache.hadoop.util.RunJar.main(RunJar.java:88)

Could anyone help me, please? 
Thanks in advance.
Rodrigo Zerbini
Computer science student in University of São Paulo