<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Executing Java in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452077#M661963</link>
    <description>Hi, I get following exception:&lt;BR /&gt;/opt/java1.5/bin/java /home/user/Hello&lt;BR /&gt;Exception in thread "main" java.lang.NoClassDefFoundError: /home/user/Hello&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;this is my first program:&lt;BR /&gt;-------------------------------------------&lt;BR /&gt;class Hello {&lt;BR /&gt;        public static void main (String[] arguments) {&lt;BR /&gt;                System.out.println("Testing Java...\n");&lt;BR /&gt;        }&lt;BR /&gt;}&lt;BR /&gt;-------------------------------------------&lt;BR /&gt;&lt;BR /&gt;I compiled it with:&lt;BR /&gt;&lt;BR /&gt;/opt/java1.5/bin/javac /home/user/Hello.java&lt;BR /&gt;&lt;BR /&gt;There were no compilation errors.&lt;BR /&gt;&lt;BR /&gt;HP-UX 11.11&lt;BR /&gt;&lt;BR /&gt;Is this related to CLASSPATH?&lt;BR /&gt;In that case, how to set it properly?&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;&lt;BR /&gt;Juan.</description>
    <pubDate>Thu, 02 Jul 2009 15:40:48 GMT</pubDate>
    <dc:creator>JUAN VIDAL_1</dc:creator>
    <dc:date>2009-07-02T15:40:48Z</dc:date>
    <item>
      <title>Executing Java</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452077#M661963</link>
      <description>Hi, I get following exception:&lt;BR /&gt;/opt/java1.5/bin/java /home/user/Hello&lt;BR /&gt;Exception in thread "main" java.lang.NoClassDefFoundError: /home/user/Hello&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;this is my first program:&lt;BR /&gt;-------------------------------------------&lt;BR /&gt;class Hello {&lt;BR /&gt;        public static void main (String[] arguments) {&lt;BR /&gt;                System.out.println("Testing Java...\n");&lt;BR /&gt;        }&lt;BR /&gt;}&lt;BR /&gt;-------------------------------------------&lt;BR /&gt;&lt;BR /&gt;I compiled it with:&lt;BR /&gt;&lt;BR /&gt;/opt/java1.5/bin/javac /home/user/Hello.java&lt;BR /&gt;&lt;BR /&gt;There were no compilation errors.&lt;BR /&gt;&lt;BR /&gt;HP-UX 11.11&lt;BR /&gt;&lt;BR /&gt;Is this related to CLASSPATH?&lt;BR /&gt;In that case, how to set it properly?&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;&lt;BR /&gt;Juan.</description>
      <pubDate>Thu, 02 Jul 2009 15:40:48 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452077#M661963</guid>
      <dc:creator>JUAN VIDAL_1</dc:creator>
      <dc:date>2009-07-02T15:40:48Z</dc:date>
    </item>
    <item>
      <title>Re: Executing Java</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452078#M661964</link>
      <description>Shalom,&lt;BR /&gt;&lt;BR /&gt;This is pretty simple code.&lt;BR /&gt;&lt;BR /&gt;Are you up to date on OS patches for java and java version from &lt;A href="http://www.hp.com/go/java" target="_blank"&gt;http://www.hp.com/go/java&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;SEP</description>
      <pubDate>Thu, 02 Jul 2009 16:45:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452078#M661964</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2009-07-02T16:45:38Z</dc:date>
    </item>
    <item>
      <title>Re: Executing Java</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452079#M661965</link>
      <description>/opt/java1.5/bin/java -version&lt;BR /&gt;java version "1.5.0.11"&lt;BR /&gt;Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0.11-_07_nov_2007_10_59)&lt;BR /&gt;Java HotSpot(TM) Server VM (build 1.5.0.11 jinteg:11.07.07-09:52 PA2.0 (aCC_AP), mixed mode)&lt;BR /&gt;&lt;BR /&gt;swlist -l product |grep -i java&lt;BR /&gt;  Jdk15                                 1.5.0.11.00    Java 1.5 JDK   &lt;BR /&gt;  Jdk60                                 1.6.0.00.00    Java 6.0 JDK   &lt;BR /&gt;  Jre13                                 1.3.1.20.00    Java2 1.3 RTE 1.3 &lt;BR /&gt;  Jre14                                 1.4.2.17.00    Java2 1.4 RTE  &lt;BR /&gt;  Jre15                                 1.5.0.11.00    Java 1.5 JRE   &lt;BR /&gt;  Jre60                                 1.6.0.00.00    Java 6.0 JRE   &lt;BR /&gt;  MyJDBC                                5.0.0          MySQL Connector/Java 5.0.0 &lt;BR /&gt;  PHKL_32927                            1.0            PA-8800 Fix Java (64-bit JVM) process hang</description>
      <pubDate>Thu, 02 Jul 2009 17:05:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452079#M661965</guid>
      <dc:creator>JUAN VIDAL_1</dc:creator>
      <dc:date>2009-07-02T17:05:54Z</dc:date>
    </item>
    <item>
      <title>Re: Executing Java</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452080#M661966</link>
      <description>The argument to /opt/java1.5/bin/java is not supposed to be a filename, but a class name.&lt;BR /&gt;&lt;BR /&gt;In other words, "/opt/java1.5/bin/java /home/user/Hello" tries to find from the CLASSPATH directories a .java file that contains a class declaration like:&lt;BR /&gt;&lt;BR /&gt;class /home/user/Hello {&lt;BR /&gt;[...]&lt;BR /&gt;&lt;BR /&gt;Of course your program is not written like that: "class Hello" is not the same as "class /home/user/Hello". The latter would be a strange name for the main class of a program.&lt;BR /&gt;&lt;BR /&gt;So, assuming the CLASSPATH has not been set, please try this:&lt;BR /&gt;&lt;BR /&gt;cd /home/user&lt;BR /&gt;/opt/java1.5/bin/java Hello&lt;BR /&gt;&lt;BR /&gt;Or, if you want to run your example program from another directory:&lt;BR /&gt;&lt;BR /&gt;cd /&lt;BR /&gt;export CLASSPATH=/home/user&lt;BR /&gt;/opt/java1.5/bin/java Hello&lt;BR /&gt;&lt;BR /&gt;MK</description>
      <pubDate>Fri, 03 Jul 2009 05:02:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452080#M661966</guid>
      <dc:creator>Matti_Kurkela</dc:creator>
      <dc:date>2009-07-03T05:02:28Z</dc:date>
    </item>
    <item>
      <title>Re: Executing Java</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452081#M661967</link>
      <description>Hi Matti,&lt;BR /&gt;&lt;BR /&gt;I performed:&lt;BR /&gt;&lt;BR /&gt;$ cd /home/user&lt;BR /&gt;$ /opt/java1.5/bin/java Hello&lt;BR /&gt;Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version number in .class file&lt;BR /&gt;        at java.lang.ClassLoader.defineClass1(Native Method)&lt;BR /&gt;        at java.lang.ClassLoader.defineClass(ClassLoader.java:620)&lt;BR /&gt;        at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)&lt;BR /&gt;        at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)&lt;BR /&gt;        at java.net.URLClassLoader.access$100(URLClassLoader.java:56)&lt;BR /&gt;        at java.net.URLClassLoader$1.run(URLClassLoader.java:195)&lt;BR /&gt;        at java.security.AccessController.doPrivileged(Native Method)&lt;BR /&gt;        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)&lt;BR /&gt;        at java.lang.ClassLoader.loadClass(ClassLoader.java:306)&lt;BR /&gt;        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)&lt;BR /&gt;        at java.lang.ClassLoader.loadClass(ClassLoader.java:251)&lt;BR /&gt;        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)&lt;BR /&gt;$</description>
      <pubDate>Sat, 04 Jul 2009 16:11:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452081#M661967</guid>
      <dc:creator>JUAN VIDAL_1</dc:creator>
      <dc:date>2009-07-04T16:11:09Z</dc:date>
    </item>
    <item>
      <title>Re: Executing Java</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452082#M661968</link>
      <description>more hello.java &lt;BR /&gt;import java.util.*;&lt;BR /&gt;class hello {&lt;BR /&gt;public static void main(String args[]) {&lt;BR /&gt;System.out.print("Hola\n");&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;/opt/java1.5/bin/javac hello.java&lt;BR /&gt;/opt/java1.5/bin/javah -jni hello&lt;BR /&gt;&lt;BR /&gt;That WORKED.&lt;BR /&gt;&lt;BR /&gt;THANKS.&lt;BR /&gt;&lt;BR /&gt;JUAN.</description>
      <pubDate>Fri, 10 Jul 2009 19:49:06 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/executing-java/m-p/4452082#M661968</guid>
      <dc:creator>JUAN VIDAL_1</dc:creator>
      <dc:date>2009-07-10T19:49:06Z</dc:date>
    </item>
  </channel>
</rss>

