[OSM-talk] FW: Re: New to osmosis and it won't work for me

scottn at omnitechsolutions.co.uk scottn at omnitechsolutions.co.uk
Fri Feb 29 17:19:12 GMT 2008


Hi,

Better but I now get:
esys at esys-desktop:~/osmosis-0.24$ sh do_it
Exception in thread "main" java.lang.ClassFormatError: com.bretth.osmosis.core.Osmosis (unrecognized class file version)
   at java.lang.VMClassLoader.defineClass(libgcj.so.70)
   at java.lang.ClassLoader.defineClass(libgcj.so.70)
   at java.security.SecureClassLoader.defineClass(libgcj.so.70)
   at java.net.URLClassLoader.findClass(libgcj.so.70)
   at java.lang.ClassLoader.loadClass(libgcj.so.70)
   at java.lang.ClassLoader.loadClass(libgcj.so.70)
   at gnu.java.lang.MainThread.run(libgcj.so.70)
esys at esys-desktop:~/osmosis-0.24$ 

Contents of do_it:
java -mx1024m -jar osmosis.jar --read-xml file=uk-080227.osm \
--bounding-polygon file="MyArea.txt" --write-xml \
file="MyArea.osm"

Thanks and Regards,

Nathan


On Fri, February 29, 2008 17:28, scottn at omnitechsolutions.co.uk wrote:
> Hi,
>
>
> I am trying to get osmosis to work for me for the first time.  I'm not
> sure I have it installed properly because I try this :
>
> java -mx1024m -jar osmosis.jar --read-xml file=uk-080227.osm
> --bounding-polygon file="MyArea.txt" --write-xml
> file="MyArea.osm"

Those three lines are seperate lines in the script called "do_it", right?
Please add a backslash after the first two lines, otherwise the shell
assumes that it has to run three commands, one calles "java", the next
called "--bounding-polygon" and the third called "file=".

Your script should look like:

--- cut here ---
java -mx1024m -jar osmosis.jar --read-xml file=uk-080227.osm \
--bounding-polygon file="MyArea.txt" --write-xml \
file="MyArea.osm"
--- cut here ---

> And I get:
> esys at esys-desktop:~/osmosis-0.24$ sh do_it
> ...
> gnu.java.lang.MainThread.run(libgcj.so.70) do_it: 2: --bounding-polygon:
> not found esys at esys-desktop:~/osmosis-0.24$

This output supports my theory about your shell script.


Regards,
Hakan



-- 
The key to immortality is first living a life worth remembering...




More information about the talk mailing list