  | Mailing List | | Home | | Forum Home | | JBoss - Java Application Server | | Struts - A MVC web framework | | Tomcat - JSP/Servlet container | | iText - An open source PDF Java Library | | JDOM - JDOM XML Parser | | J2EE - A mailing list for Java(tm) 2 Platform, Enterprise Edition | | J2EE Pattern - An interest list for Sun Java Center J2EE Pattern Catalog | | Servlet - A mailing list for discussion about Sun Microsystem's Java Servlet API Technology | | JSP - A mailing list about Java Server Pages specification and reference | |
Struts & Hibernate
|
|
|
  | | | Erro in the execution of the program with JDK 1.3.1 | Erro in the execution of the program with JDK 1.3.1 2003-10-15 - By Breno Cardoso Perucchi
Back Hello
Can anybody tell me the one what I should do on that below? Those are the message of forum http://forum.java.sun.com - Java Programming - Java Virtual Machine
thanks
Erro in the execution of the program with JDK 1.3.1 Author: Breno_Perucchi Oct 14, 2003 1:27 AM Hello guys I installed the port JDK 1.3.1 in the system operation Freebsd . But I am having a problem of execution in my Java program. My program try to create bank ticket with bar code but it doesn't get to create the bar code
I already researched in the internet the followings error but up to now I didn't have any answer to solve my problem. I need the help. Below this the log of the java
Below the are log of the JDK 1.3.1 003-10-08 17:50:56 StandardWrapperValve[barbecue]: Servlet.service() for servlet barbecue threw exception javax.servlet.ServletException : Servlet execution threw an exception at org.apache.catalina.core.ApplicationFilterChain  (ApplicationFilterChain.java:269) at org.apache.catalina.core.ApplicationFilterChain  (ApplicationFilterChain.java:193)
-- -- Root Cause -- -- java.lang.InternalError : Can't connect to X11 window server using ':0.0' as the value of the DISPLAY variable. at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method) at sun.awt.X11GraphicsEnvironment.<clinit>(X11GraphicsEnvironment.java:54)
-- -- Root Cause -- -- java.lang.NoClassDefFoundError : sun/awt/motif/MToolkit at java.lang.Class (Native Method) at java.lang.Class (Class.java:115)
Re: Erro in the execution of the program with JDK 1.3.1 Author: andih In Reply To: Erro in the execution of the program with JDK 1 .3.1 Oct 14, 2003 2:33 AM
Reply 1 of 3 You either have no X server running or not the permissions to connect to the server. The message appears whenever at least one servlet uses direct or indirect SWING ( AWT) classes.
The second root may be followup error of the fact that it's not possible to connect to the X server. There occured an error during initialzation of the MToolkit which the Classloder may report as a ClassNotFoundError.
Ensure that there exists a X Server and you have the permissions to connect to the X server. Set the DISPLAY environment variable.
Re: Erro in the execution of the program with JDK 1.3.1 Author: Breno_Perucchi In Reply To: Re: Erro in the execution of the program with JDK 1.3.1 Oct 14, 2003 11:28 AM
Reply 2 of 3 I don't have X11 server installed
Do I have to install X11? Even if my program is executed in the Apache webserver ? This error with awt/motif/MToolkit can be originated by mistake above ?
Thanks for your help
Re: Erro in the execution of the program with JDK 1.3.1 Author: SebastianM In Reply To: Re: Erro in the execution of the program with JDK 1.3.1 Oct 14, 2003 12:39 PM
Reply 3 of 3 try passing the following switch with the JRE:
-Djava.awt.headless=true
as in
java -Djava.awt.headless=true package.MyMainProgram
Re: Erro in the execution of the program with JDK 1.3.1 Author: dpz In Reply To: Re: Erro in the execution of the program with JDK 1.3.1 Oct 15, 2003 11:02 AM
Reply 4 of 4 If there is an X-server some where nearby, you can point your DISPLAY variable at it. Since I presume you aren't actually displaying anything the humnan sitting at that X-Server wont notice anything. You may need to do an 'xhost +<...>' on the X-Server in order to get access.
Since you're running 1.3 the -Djava.awt.headless=true option isn't available.
You might also look at Xvfb which is a headless X-Server for just such emergencies
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML><HEAD> <META http-equiv=Content-Type content="text/html; charset=iso-8859 (See http://iso-8859.ora-code.com)-1"> <META content="MSHTML 6.00.2800.1226" name=GENERATOR> <STYLE></STYLE> </HEAD> <BODY bgColor=#ffffff background=""> <DIV><FONT face=Arial size=2>Hello </FONT></DIV> <DIV><FONT face=Arial size=2></FONT> </DIV> <DIV><FONT face=Arial size=2>Can anybody tell me the one what I should do on that below? </FONT></DIV> <DIV><FONT face=Arial size=2>Those are the message of forum <A href="http://forum.java.sun.com">http://forum.java.sun.com</A> - Java Programming - Java Virtual Machine</FONT></DIV> <DIV><FONT face=Arial size=2></FONT> </DIV> <DIV><FONT face=Arial size=2>thanks</FONT></DIV> <DIV><FONT face=Arial size=2></FONT> </DIV> <DIV><FONT face=Arial size=2> </DIV> <DIV> <TABLE cellSpacing=1 cellPadding=4 width="100%" bgColor=#666699 border=0> <TBODY> <TR bgColor=#ddddff> <TD> <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD width="98%"><FONT size=-1><B>Erro in the execution of the program with JDK 1.3.1</B><BR>Author: <A title="Breno Perucchi" href="http://forum.java.sun.com/profile.jsp?user=393192"><I><FONT color=#660066>Breno_Perucchi</FONT></I></A> </FONT></TD> <TD noWrap width="1%"><FONT size=-1>Oct 14, 2003 1:27 AM </FONT></TD> <TD noWrap align=middle width="1%"><A title=Reply href="http://forum.java.sun.com/post.jsp?forum=31&thread=454080 &message=2068229&reply=true"><IMG height=30 src="mhtml:mid://00000497/!http://forum.java.sun.com/images/reply .gif" width=31 border=0></A> </TD></TR></TBODY></TABLE></TD></TR> <TR bgColor=#ffffff> <TD><FONT size=-1>Hello guys<BR>I installed the port JDK 1.3.1 in the system operation Freebsd . But I am having a problem of execution in my Java program. My program try to create bank ticket with bar code but it doesn't get to create the bar code <BR><BR>I already researched in the internet the followings error but up to now I didn't have any answer to solve my problem. I need the help. Below this the log of the java <BR><BR>Below the are log of the JDK 1.3.1<BR>003-10-08 17:50:56 StandardWrapperValve[barbecue]: Servlet.service() for servlet barbecue threw exception<BR>javax.servlet.ServletException : Servlet execution threw an exception<BR>at org.apache.catalina.core.ApplicationFilterChain  (ApplicationFilterChain.java:269)<BR>at org.apache.catalina.core.ApplicationFilterChain  (ApplicationFilterChain.java:193)<BR><BR>-- -- Root Cause -- --<BR>java.lang.InternalError : Can't connect to X11 window server using ':0.0' as the value of the DISPLAY variable.<BR>at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)<BR>at sun.awt.X11GraphicsEnvironment.<clinit>(X11GraphicsEnvironment.java :54)<BR><BR>-- -- Root Cause -- --<BR>java.lang.NoClassDefFoundError : sun/awt/motif/MToolkit<BR>at java.lang.Class (Native Method)<BR >at java.lang.Class (Class.java:115) </FONT></TD></TR></TBODY></TABLE> </DIV> <DIV><BR></DIV><A name=2068324></A> <DIV> <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD width="99%"> <TABLE cellSpacing=0 cellPadding=1 width="100%" bgColor=#999999 border=0><TBODY> <TR> <TD> <TABLE cellSpacing=0 cellPadding=4 width="100%" bgColor=#dddddd border=0> <TBODY> <TR> <TD width="1%"><A title="Award Duke Dollars" href="http://forum.java.sun.com/rewards.jsp?forum=31& ;thread=454080&message=2068324&reward=true"><IMG height=18 hspace=6 src="mhtml:mid://00000497/!http://forum.java.sun.com/images /duke_add.gif" width=21 vspace=6 border=0></A> </TD> <TD width="97%"><IMG title="1 Duke Dollar awarded" height=16 src="mhtml:mid://00000497/!http://forum.java.sun.com/images /duke_awarded.gif" width=19 border=0> <FONT size=-1><B>Re: Erro in the execution of the program with JDK 1.3.1</B> <BR>Author: <A title="Click for profile" href="http://forum.java.sun.com/profile.jsp?user=8573"><I> <FONT color=#660066>andih</FONT></I></A> <BR>In Reply To: <A title="Posted by: Breno_Perucchi" href="http://forum.java.sun.com/thread.jsp?forum=31& ;thread=454080&message=2068229#2068229">Erro in the execution of the program with JDK 1.3.1</A> </FONT>< /TD> <TD noWrap width="1%"><FONT size=-1>Oct 14, 2003 2:33 AM <BR></FONT><FONT size=-2> <CENTER>Reply 1 of 3</CENTER></FONT></TD> <TD noWrap align=middle width="1%"><A title=Reply href="http://forum.java.sun.com/post.jsp?forum=31&thread =454080&message=2068324&reply=true"><IMG height=30 src="mhtml:mid://00000497/!http://forum.java.sun.com/images /reply.gif" width=31 border=0></A> </TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></TD></TR> <TR> <TD> <TABLE cellSpacing=0 cellPadding=3 width="100%" border=0> <TBODY> <TR> <TD><FONT size=-1>You either have no X server running or not the permissions to connect to the server. The message appears whenever at least one servlet uses direct or indirect SWING ( AWT) classes. <BR><BR>The second root may be followup error of the fact that it's not possible to connect to the X server. <BR>There occured an error during initialzation of the MToolkit which the Classloder may report as a ClassNotFoundError. <BR><BR>Ensure that there exists a X Server and you have the permissions to connect to the X server. Set the DISPLAY environment variable. </FONT></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></DIV> <DIV><BR></DIV><A name=2069550></A> <DIV> <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD width="100%"> <TABLE cellSpacing=0 cellPadding=1 width="100%" bgColor=#999999 border=0><TBODY> <TR> <TD> <TABLE cellSpacing=0 cellPadding=4 width="100%" bgColor=#dddddd border=0> <TBODY> <TR> <TD width="98%"><FONT size=-1><B>Re: Erro in the execution of the program with JDK 1.3.1</B> <BR>Author: <A title="Breno Perucchi" href="http://forum.java.sun.com/profile.jsp?user=393192"><I> <FONT color=#660066>Breno_Perucchi</FONT></I></A> <BR>In Reply To: <A title="Posted by: andih" href="http://forum.java.sun.com/thread.jsp?forum=31& ;thread=454080&message=2068324#2068324">Re: Erro in the execution of the program with JDK 1.3.1</A> </FONT></TD> <TD noWrap width="1%"><FONT size=-1>Oct 14, 2003 11:28 AM <BR></FONT><FONT size=-2> <CENTER>Reply 2 of 3</CENTER></FONT></TD> <TD noWrap align=middle width="1%"><A title=Reply href="http://forum.java.sun.com/post.jsp?forum=31&thread =454080&message=2069550&reply=true"><IMG height=30 src="mhtml:mid://00000497/!http://forum.java.sun.com/images /reply.gif" width=31 border=0></A> </TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></TD></TR> <TR> <TD> <TABLE cellSpacing=0 cellPadding=3 width="100%" border=0> <TBODY> <TR> <TD><FONT size=-1>I don't have X11 server installed <BR><BR>Do I have to install X11? Even if my program is executed in the Apache webserver ?<BR>This error with awt/motif/MToolkit can be originated by mistake above ?<BR><BR>Thanks for your help </FONT></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></DIV> <DIV><BR></DIV><A name=2069769></A> <DIV> <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD width="99%"> <TABLE cellSpacing=0 cellPadding=1 width="100%" bgColor=#999999 border=0><TBODY> <TR> <TD> <TABLE cellSpacing=0 cellPadding=4 width="100%" bgColor=#dddddd border=0> <TBODY> <TR> <TD width="1%"><A title="Award Duke Dollars" href="http://forum.java.sun.com/rewards.jsp?forum=31& ;thread=454080&message=2069769&reward=true"><IMG height=18 hspace=6 src="mhtml:mid://00000497/!http://forum.java.sun.com/images /duke_add.gif" width=21 vspace=6 border=0></A> </TD> <TD width="97%"><FONT size=-1><B>Re: Erro in the execution of the program with JDK 1.3.1</B> <BR>Author: <A title="Click for profile" href="http://forum.java.sun.com/profile.jsp?user=242409"><I >SebastianM</I></A> <BR>In Reply To: <A title="Posted by: Breno_Perucchi" href="http://forum.java.sun.com/thread.jsp?forum=31& ;thread=454080&message=2069550#2069550">Re: Erro in the execution of the program with JDK 1.3.1</A> </FONT></TD> <TD noWrap width="1%"><FONT size=-1>Oct 14, 2003 12:39 PM <BR></FONT><FONT size=-2> <CENTER>Reply 3 of 3</CENTER></FONT></TD> <TD noWrap align=middle width="1%"><A title=Reply href="http://forum.java.sun.com/post.jsp?forum=31&thread =454080&message=2069769&reply=true"><IMG height=30 src="mhtml:mid://00000497/!http://forum.java.sun.com/images /reply.gif" width=31 border=0></A> </TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></TD></TR> <TR> <TD> <TABLE cellSpacing=0 cellPadding=3 width="100%" border=0> <TBODY> <TR> <TD><FONT size=-1>try passing the following switch with the JRE:<BR><BR>-Djava.awt.headless=true<BR><BR>as in<BR><BR>java -Djava.awt.headless=true package.MyMainProgram<BR></FONT></TD></TR></TBODY></TABLE></TD></TR>< /TBODY></TABLE></DIV></FONT> <DIV><FONT face=Arial size=2> <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0> <TBODY> <TR> <TD width="99%"> <TABLE cellSpacing=0 cellPadding=1 width="100%" bgColor=#999999 border=0><TBODY> <TR> <TD> <TABLE cellSpacing=0 cellPadding=4 width="100%" bgColor=#dddddd border=0> <TBODY> <TR> <TD width="1%"><A title="Award Duke Dollars" href="http://forum.java.sun.com/rewards.jsp?forum=37& ;thread=454082&message=2072174&reward=true"><FONT face=Arial size=2><IMG height=18 hspace=6 src="mhtml:mid://00000497/!http://forum.java.sun.com/images /duke_add.gif" width=21 vspace=6 border=0></FONT></A><FONT face=Arial size=2 > </FONT></TD> <TD width="97%"><FONT face=Arial size=2>Re: Erro in the execution of the program with JDK 1.3.1 <BR>Author: </FONT><A title="Click for profile" href="http://forum.java.sun.com/profile.jsp?user=5737"><FONT face=Arial size=2>dpz</FONT></A><FONT face=Arial size=2> <BR>In Reply To: </FONT><A title="Posted by: omcgovern" href="http://forum.java.sun.com/thread.jsp?forum=37& ;thread=454082&message=2071127#2071127"><FONT face=Arial size=2>Re: Erro in the execution of the program with JDK 1.3.1 </FONT></A></TD> <TD noWrap width="1%"><FONT face=Arial size=2>Oct 15, 2003 11:02 AM <BR></FONT> <CENTER><FONT face=Arial size=2>Reply 4 of 4</FONT></CENTER></TD> <TD noWrap align=middle width="1%"><A title=Reply href="http://forum.java.sun.com/post.jsp?forum=37&thread =454082&message=2072174&reply=true"><FONT face=Arial size=2><IMG height=30 src="mhtml:mid://00000497/!http://forum.java.sun.com/images /reply.gif" width=31 border=0></FONT></A><FONT face=Arial size=2> </FONT></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></TD ></TR> <TR> <TD> <TABLE cellSpacing=0 cellPadding=3 width="100%" border=0> <TBODY> <TR> <TD><FONT face=Arial size=2>If there is an X-server some where nearby, you can point your DISPLAY variable at it. Since I presume you aren't actually displaying anything the humnan sitting at that X-Server wont notice anything. You may need to do an 'xhost +<...>' on the X-Server in order to get access.<BR><BR>Since you're running 1.3 the -Djava.awt.headless=true option isn't available.<BR><BR>You might also look at Xvfb which is a headless X-Server for just such emergencies </FONT></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE><BR></FONT><A name=2072174></A></DIV></BODY></HTML>
|
|
 |