Re: java.lang.Object cannot be resolved
Hi, Do you really need sudo here? Perhaps that's creating some issues. doesn't seem so. I get exactly the same error in my home directory. What happens if you try to compile a simple Hello World program, without anything specified for -cp? (Try it with and without sudo to see if that makes a difference.) No, simple javac Hello.java doesn't work. Only if I set $CLASSPATH to /usr/lib/jdk/jre/lib/rt.jar or with the -cp-option. What environment variables do you have set? Do you mean $CLASSPATH? For the Hello World program no one. Greetings, Sebastian - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.lang.Object cannot be resolved
Hi, On Feb 13, 2006, at 5:56 PM, Caldarale, Charles R wrote: From: Sebastian Funk [mailto:[EMAIL PROTECTED] Subject: Re: java.lang.Object cannot be resolved No, simple javac Hello.java doesn't work. Only if I set $CLASSPATH to /usr/lib/jdk/jre/lib/rt.jar or with the -cp-option. Then your JDK installation is broken. Where is javac being executed from? It should be coming from the /usr/lib/jdk/bin directory, and the various pieces of the JVM should be in /usr/lib/jdk/jre/bin and its subdirectories. Is that the case? no, javac was set to /usr/bin/javac but with /usr/lib/jdk/bin/javac ist works fine. Thanks a lot. Greetings, Sebastian - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
java.lang.Object cannot be resolved
Hi, I wrote some servlets a few weeks ago and didn't change them. On the server itself I update serveral things. Now, when I try compile the source-code, I get that error: 1. ERROR in Familie.java (at line 1) import java.lang.Object; ^ The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files the same source code worked fine for weeks. I don't use any IDE's like Eclipse. Greetings, Sebastian Funk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.lang.Object cannot be resolved
On Feb 11, 2006, at 6:30 PM, Caldarale, Charles R wrote: From: Sebastian Funk [mailto:[EMAIL PROTECTED] Subject: java.lang.Object cannot be resolved import java.lang.Object; The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files Don't know why you're suddenly getting this message, but there's no reason to import java.lang.Object (or anything else from java.lang, for that matter). There is an implicit import of java.lang.* for all compilations (see Java language spec, section 7.5.5). - Chuck I get that message at the first import-statement. When I don't import java.lang.Object, then I get exactly the same, e.g.: 1. ERROR in Familie.java (at line 1) import javax.servlet.*; ^ The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files Any ideas? Greetings, Sebastian Funk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.lang.Object cannot be resolved
Hi, I never set $CLASSPATH, but when I call rt.jar via javac -cp .../ rt.jar Servlet.java, it works fine. Should I set $CLASSPATH or is that enough? On Feb 11, 2006, at 9:49 PM, Martin Gainty wrote: Lets start with the easy stuff is $JAVA_HOME\lib\rt.jar on your $CLASSPATH ??? Martin- - Original Message - From: David Smith [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org Sent: Saturday, February 11, 2006 1:56 PM Subject: Re: java.lang.Object cannot be resolved Looks like the kind of weirdness that makes me think the JVM has become unstable. Have you tried to restart Tomcat? -- David Sebastian Funk wrote: On Feb 11, 2006, at 6:30 PM, Caldarale, Charles R wrote: From: Sebastian Funk [mailto:[EMAIL PROTECTED] Subject: java.lang.Object cannot be resolved import java.lang.Object; The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files Don't know why you're suddenly getting this message, but there's no reason to import java.lang.Object (or anything else from java.lang, for that matter). There is an implicit import of java.lang.* for all compilations (see Java language spec, section 7.5.5). - Chuck I get that message at the first import-statement. When I don't import java.lang.Object, then I get exactly the same, e.g.: 1. ERROR in Familie.java (at line 1) import javax.servlet.*; ^ The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files Any ideas? Greetings, Sebastian Funk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat and iptables?
Hi, I've run a Tomcat-server and it worked fine. Now I've installed iptables and I'm getting some trouble. Wich port do I have to open for tomcat? Only the 8080 doesn't seem to be enough. What else? Best Regards, Sebastian Funk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat and iptables?
Hi, Thanks to all, now I entered the ports 8082, 8009, 8443 and 8005 (for shutdown) and now Tomcat works, but I can't shutdown. There comes as usual: Using CATALINA_BASE: /home/tomcat/tomcat Using CATALINA_HOME: /home/tomcat/tomcat Using CATALINA_TMPDIR: /home/tomcat/tomcat/temp Using JRE_HOME: /usr/lib/jdk but then nothing happens, and I get no prompt back. Did I miss a port? Best Regards, Sebastian Funk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat and iptables?
Hi, On Dec 16, 2005, at 6:18 PM, Martin Gainty wrote: Sebastian- send us the logs specifically stdout_MMDD.log Martin- Sorry, but I've got nothing named stdout*.log. Where should that be? - Original Message - From: Sebastian Funk [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org Sent: Friday, December 16, 2005 11:52 AM Subject: Re: Tomcat and iptables? Hi, Thanks to all, now I entered the ports 8082, 8009, 8443 and 8005 (for shutdown) and now Tomcat works, but I can't shutdown. There comes as usual: Using CATALINA_BASE: /home/tomcat/tomcat Using CATALINA_HOME: /home/tomcat/tomcat Using CATALINA_TMPDIR: /home/tomcat/tomcat/temp Using JRE_HOME: /usr/lib/jdk but then nothing happens, and I get no prompt back. Did I miss a port? Best Regards, Sebastian Funk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat and iptables?
Hi, On Dec 16, 2005, at 6:18 PM, Martin Gainty wrote: Sebastian- send us the logs specifically stdout_MMDD.log Martin- I've got nothing named stdout*.log. Where so - Original Message - From: Sebastian Funk [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org Sent: Friday, December 16, 2005 11:52 AM Subject: Re: Tomcat and iptables? Hi, Thanks to all, now I entered the ports 8082, 8009, 8443 and 8005 (for shutdown) and now Tomcat works, but I can't shutdown. There comes as usual: Using CATALINA_BASE: /home/tomcat/tomcat Using CATALINA_HOME: /home/tomcat/tomcat Using CATALINA_TMPDIR: /home/tomcat/tomcat/temp Using JRE_HOME: /usr/lib/jdk but then nothing happens, and I get no prompt back. Did I miss a port? Best Regards, Sebastian Funk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat and iptables?
Hi, On Dec 16, 2005, at 6:18 PM, Martin Gainty wrote: Sebastian- send us the logs specifically stdout_MMDD.log Martin- I've got nothing named stdout*.log. Where so - Original Message - From: Sebastian Funk [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org Sent: Friday, December 16, 2005 11:52 AM Subject: Re: Tomcat and iptables? Hi, Thanks to all, now I entered the ports 8082, 8009, 8443 and 8005 (for shutdown) and now Tomcat works, but I can't shutdown. There comes as usual: Using CATALINA_BASE: /home/tomcat/tomcat Using CATALINA_HOME: /home/tomcat/tomcat Using CATALINA_TMPDIR: /home/tomcat/tomcat/temp Using JRE_HOME: /usr/lib/jdk but then nothing happens, and I get no prompt back. Did I miss a port? Best Regards, Sebastian Funk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Antwort: RE: Tomcat JDBC connection with Mysql
Hi, I got the same error a few weeks ago. in my case, the URL was wrong. you use: jdbc:mysql://l/AdressBook Are you sure it's right? Is 'l' really the right host? Did you tried it with the ip-address? Best Regards, Sebastian On Dec 12, 2005, at 2:37 PM, marju jalloh wrote: I went throug the permission and now I get another error java.sql.SQLException: Unable to connect to any hosts due to exception: java.net.SocketException: java.net.ConnectException: Connection refused ** BEGIN NESTED EXCEPTION ** java.net.SocketException MESSAGE: java.net.ConnectException: Connection refused STACKTRACE: java.net.SocketException: java.net.ConnectException: Connection refused I don`t know if the problem is with Tomcat of the Driver of mysql server This is my code ublic class Marju extends HttpServlet { public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { response.setContentType(text/html); PrintWriter out = response.getWriter(); Connection conn = null; try { String userName = root; String password = ; String url = jdbc:mysql://l/AdressBook; Class.forName(com.mysql.jdbc.Driver); conn = DriverManager.getConnection(url, userName,password); out.println(Database connection established); } catch (Exception e) { out.println(Can`t connect to database server!); e.printStackTrace(); } finally { if (conn != null) { try { conn.close (); System.out.println (Database connection terminated); } catch (Exception e) { /* ignore close errors */ } } } out.println(my first servlet); } } Any help would be appreciated Byfour Jan Behrens [EMAIL PROTECTED] wrote: look here -- http://dev.mysql.com/doc/refman/4.1/en/connection-access.html rtfm ;) marju jalloh schrieb am 12.12.2005 13:33:54: But how to Grant permission to an ip host Karthik wrote: hI tHE PROBLEMS IS PRESENT WITHIN THE mysql SERVER,U NEED TO GIVE PERMISSION TO THE ip HOST U ARE USING TRY USING THE GRANT PERMISSION AND USE THE SAME,BUT U HAVE TO FLUSH OUT ALL acl PREVELIAGES AVALIABEL IN MYSQL DB USE A FRONT END LIKE MYSQL FRONT TO DO THIS HOPE THIS HELPS. WITH REGARS kARTHIK -Original Message- From: marju jalloh [mailto:[EMAIL PROTECTED] Sent: Monday, December 12, 2005 4:53 PM To: Tomcat Users List Subject: Tomcat JDBC connection with Mysql I can`connect to my database with via servlet. The connection works well in PHP but not with servlet. I have googled but no solution. this is my error page I got java.sql.SQLException: Data source rejected establishment of connection, message from server: Host 'localhost.localdomain' is not allowed to connect to this MySQL server at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:650) at com.mysql.jdbc.Connection.createNewIO(Connection.java:1808) at com.mysql.jdbc.Connection.(Connection.java:452) at com.mysql.jdbc.NonRegisteringDriver.connect (NonRegisteringDriver.java:411) at java.sql.DriverManager.getConnection(DriverManager.java:525) at java.sql.DriverManager.getConnection(DriverManager.java:171) at Liep.doGet(Liep.java:30) ... ... Can anyone help or give me a pointer to a website Byfour - Yahoo! Shopping Find Great Deals on Holiday Gifts at Yahoo! Shopping - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Yahoo! Shopping Find Great Deals on Holiday Gifts at Yahoo! Shopping - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Yahoo! Shopping Find Great Deals on Holiday Gifts at Yahoo! Shopping - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
servet-dircetory
(Sorry if I sent this message twice, I didn't get the first one) Hi, I've read a book about servlets called Java Servlet Progamming. This book says I can access all my servlets - additionally to that what I declared in web.xml - via http://tomcat-server:8080/servlet/myServlet but I can't. I get 404 Not Found. Why? Best Regards, Sebastian - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: servet-dircetory
On Dec 4, 2005, at 4:19 PM, Wendy Smoak wrote: On 12/4/05, Sebastian Funk [EMAIL PROTECTED] wrote: I've read a book about servlets called Java Servlet Progamming. This book says I can access all my servlets - additionally to that what I declared in web.xml - via http://tomcat-server:8080/servlet/myServlet but I can't. I get 404 Not Found. Why? http://tomcat.apache.org/faq/misc.html#invoker thanks for that. Best regards, Sebastian Funk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: HttpServlet not found?
HI, On Nov 29, 2005, at 5:07 PM, Caldarale, Charles R wrote: From: Sebastian [mailto:[EMAIL PROTECTED] Subject: HttpServlet not found? I compiled it with javac -cp /home/tomcat/j2ee/lib/j2ee.jar:/home/tomcat/mysql MyServlet.java. Using j2ee.jar with Tomcat usually results in much grief, since it contains many classes that conflict with those supplied by Tomcat. Suggest removing it from your system, or at least taking it out of your classpath. Use Tomcat's common/lib/servlet-api.jar instead. that works fine, but just one time. Again, when I recompile my servlet, without any changes, I get that error. I set all $CLASSPATH's new and move j2ee.jar to another place, where it shouldn't be find. but I get the same error NoClassDefFoundError. Thanks Greetings, Sebastian Funk - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]