Can't connect to X11

2005-09-22 Thread Iin Nurhidayat

Hi All,

I found this error :

  java.lang.InternalError: Can't connect to X11
window server using ':0.0' as the value of the DISPLAY
variable. 

on UNIX platform.

Please adv.

Thanks

Regards

- IN -




--- Antony GUILLOTEAU [EMAIL PROTECTED]
wrote:

 I wanted to simulate a CLIENt-CERT realm to the
 browser with serlvet
 (response.setHeader(WWW-Authenticate, BASIC
 realm=\myName\)) but it seems not possible. So I
 want to basically redirect my request to SSL. 
 
 I wish know how to redirect a request to the secure
 port within a serlvet but I don't want use
 init-parameter in the web.xml and so one.
 
 Thanks
 




__ 
Yahoo! Mail - PC Magazine Editors' Choice 2005 
http://mail.yahoo.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Can't connect to X11

2005-09-22 Thread David Delbecq
You are not supposed to use awt or swing on a java web server.
remove calls to awt/swing or use headless java.


Iin Nurhidayat a écrit :

Hi All,

I found this error :

  java.lang.InternalError: Can't connect to X11
window server using ':0.0' as the value of the DISPLAY
variable. 

on UNIX platform.

Please adv.

Thanks

Regards

- IN -




--- Antony GUILLOTEAU [EMAIL PROTECTED]
wrote:

  

I wanted to simulate a CLIENt-CERT realm to the
browser with serlvet
(response.setHeader(WWW-Authenticate, BASIC
realm=\myName\)) but it seems not possible. So I
want to basically redirect my request to SSL. 

I wish know how to redirect a request to the secure
port within a serlvet but I don't want use
init-parameter in the web.xml and so one.

Thanks






   
__ 
Yahoo! Mail - PC Magazine Editors' Choice 2005 
http://mail.yahoo.com

-
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: Can't connect to X11

2005-09-22 Thread Christian Mittendorf

Hi,

do you use some graphic functions in your project? If so,
you should add the following parameter to Tomcat startup:

-Djava.awt.headless=true

cu
cm



Am 22.09.2005 um 09:07 schrieb Iin Nurhidayat:



Hi All,

I found this error :

  java.lang.InternalError: Can't connect to X11
window server using ':0.0' as the value of the DISPLAY
variable. 

on UNIX platform.

Please adv.

Thanks

Regards

- IN -




PGP.sig
Description: Signierter Teil der Nachricht


Re: Can't connect to X11 window server using '0:0' as the value of the display and now java.awt.HeadlessException

2003-03-23 Thread Stephen Riek

 On Thu, 2003-03-20 at 20:36, Micael wrote:
 For me the easiest thing was just to provide the right command line options 
 (java.awt.headless=true) when I started up Tomcat.
May I ask, how you did this ? I've also encountered
JNI_OnLoad errors runing on Solaris due, I suspect, the lack of
XWindows on my server.  I tried adding the headless flag to 
my catalina.sh script as follows ~
elif [ $1 = start ] ; then
  shift
  touch $CATALINA_BASE/logs/catalina.out
  if [ $1 = -security ] ; then
echo Using Security Manager
shift
$_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
  -Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
  -Djava.security.manager \
  -Djava.security.policy==$CATALINA_BASE/conf/catalina.policy \
  -Dcatalina.base=$CATALINA_BASE \
  -Dcatalina.home=$CATALINA_HOME \
  -Djava.io.tmpdir=$CATALINA_TMPDIR \
  -Djava.awt.headless=true \
  org.apache.catalina.startup.Bootstrap $@ start \
   $CATALINA_BASE/logs/catalina.out 21 
  else
$_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
  -Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
  -Dcatalina.base=$CATALINA_BASE \
  -Dcatalina.home=$CATALINA_HOME \
  -Djava.io.tmpdir=$CATALINA_TMPDIR \
  -Djava.awt.headless=true \
  org.apache.catalina.startup.Bootstrap $@ start \
   $CATALINA_BASE/logs/catalina.out 21 
  fi
But that just resulted in the following error,
java.awt.HeadlessException
at java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:121)
at java.awt.Window.(Window.java:266)
at java.awt.Frame.(Frame.java:398)
at java.awt.Frame.(Frame.java:363)
at ImageUtils.loadImage(Unknown Source)

where the loadImage() function is simply supposed to load an image,
 public static Image loadImage(String fileName) {
  Image image = Toolkit.getDefaultToolkit().getImage(fileName);
  MediaTracker mediaTracker = new MediaTracker(new Frame());
  mediaTracker.addImage(image, 0);
  try {
   mediaTracker.waitForID(0);
  }
  catch (InterruptedException ie) {
   //
  }
  return image;
 }
Any ideas/help would be great.
Stephen.
ps. I also tried PJA but couldn't get that to work either :(




-
With Yahoo! Mail you can get a bigger mailbox -- choose a size that fits your needs


Re: Can't connect to X11 window server using '0:0' as the value of the display and now java.awt.HeadlessException

2003-03-23 Thread Micael
I added the headless flag to catalina.sh as follows:

# - Execute The Requested Command -

echo Using CATALINA_BASE:   $CATALINA_BASE
echo Using CATALINA_HOME:   $CATALINA_HOME
echo Using CATALINA_TMPDIR: $CATALINA_TMPDIR
echo Using JAVA_HOME:   $JAVA_HOME
if [ $1 = jpda ] ; then
  if [ -z $JPDA_ADDRESS ]; then
JPDA_ADDRESS=8000
  fi
  if [ -z $JDPA_OPTS ]; then
JPDA_OPTS=-Xdebug 
-Xrunjdwp:transport=dt_socket,address=$JPDA_ADDRESS,server=y,suspend=n
  fi
  CATALINA_OPTS=$CATALINA_OPTS $JPDA_OPTS
  shift
fi
CATALINA_OPTS=-Djava.awt.headless=true

This worked fine.

At 08:15 AM 3/23/03 +, you wrote:

 On Thu, 2003-03-20 at 20:36, Micael wrote:
 For me the easiest thing was just to provide the right command line 
options
 (java.awt.headless=true) when I started up Tomcat.
May I ask, how you did this ? I've also encountered
JNI_OnLoad errors runing on Solaris due, I suspect, the lack of
XWindows on my server.  I tried adding the headless flag to
my catalina.sh script as follows ~
elif [ $1 = start ] ; then
  shift
  touch $CATALINA_BASE/logs/catalina.out
  if [ $1 = -security ] ; then
echo Using Security Manager
shift
$_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
  -Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
  -Djava.security.manager \
  -Djava.security.policy==$CATALINA_BASE/conf/catalina.policy \
  -Dcatalina.base=$CATALINA_BASE \
  -Dcatalina.home=$CATALINA_HOME \
  -Djava.io.tmpdir=$CATALINA_TMPDIR \
  -Djava.awt.headless=true \
  org.apache.catalina.startup.Bootstrap $@ start \
   $CATALINA_BASE/logs/catalina.out 21 
  else
$_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
  -Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
  -Dcatalina.base=$CATALINA_BASE \
  -Dcatalina.home=$CATALINA_HOME \
  -Djava.io.tmpdir=$CATALINA_TMPDIR \
  -Djava.awt.headless=true \
  org.apache.catalina.startup.Bootstrap $@ start \
   $CATALINA_BASE/logs/catalina.out 21 
  fi
But that just resulted in the following error,
java.awt.HeadlessException
at 
java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:121)
at java.awt.Window.(Window.java:266)
at java.awt.Frame.(Frame.java:398)
at java.awt.Frame.(Frame.java:363)
at ImageUtils.loadImage(Unknown Source)

where the loadImage() function is simply supposed to load an image,
 public static Image loadImage(String fileName) {
  Image image = Toolkit.getDefaultToolkit().getImage(fileName);
  MediaTracker mediaTracker = new MediaTracker(new Frame());
  mediaTracker.addImage(image, 0);
  try {
   mediaTracker.waitForID(0);
  }
  catch (InterruptedException ie) {
   //
  }
  return image;
 }
Any ideas/help would be great.
Stephen.
ps. I also tried PJA but couldn't get that to work either :(


-
With Yahoo! Mail you can get a bigger mailbox -- choose a size that fits 
your needs


LEGAL NOTICE

This electronic mail  transmission and any accompanying documents contain 
information belonging to the sender which may be confidential and legally 
privileged.  This information is intended only for the use of the 
individual or entity to whom this electronic mail transmission was sent as 
indicated above. If you are not the intended recipient, any disclosure, 
copying, distribution, or action taken in reliance on the contents of the 
information contained in this transmission is strictly prohibited.  If you 
have received this transmission in error, please delete the message.  Thank 
you  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Can't connect to X11 window server using '0:0' as the value of the display and now java.awt.HeadlessException

2003-03-23 Thread Stephen Riek

Thanks Micael. Tried the same thing and got the same results. 
Looks like Catalina/Tomcat is indeed using headless mode but
it's not working with my Java (1.4) and operating system (SunOS 5.6).
I'm presuming you're using this to create/generate graphics in a
servlet ?  Do you mind posting sample Java that creates a
Toolkit or MediaTracker (and which therefore requires headless 
mode) ? I can't fathom what's wrong with mine. Mine works fine
when running on Win2K and Tomcat, but now dying on Sun.
Thanks for the help,
Stephen.
 
 Micael [EMAIL PROTECTED] wrote:
I added the headless flag to catalina.sh as follows:

# - Execute The Requested Command -

echo Using CATALINA_BASE: $CATALINA_BASE
echo Using CATALINA_HOME: $CATALINA_HOME
echo Using CATALINA_TMPDIR: $CATALINA_TMPDIR
echo Using JAVA_HOME: $JAVA_HOME

if [ $1 = jpda ] ; then
if [ -z $JPDA_ADDRESS ]; then
JPDA_ADDRESS=8000
fi
if [ -z $JDPA_OPTS ]; then
JPDA_OPTS=-Xdebug 
-Xrunjdwp:transport=dt_socket,address=$JPDA_ADDRESS,server=y,suspend=n
fi
CATALINA_OPTS=$CATALINA_OPTS $JPDA_OPTS
shift
fi
CATALINA_OPTS=-Djava.awt.headless=true

This worked fine.


At 08:15 AM 3/23/03 +, you wrote:

  On Thu, 2003-03-20 at 20:36, Micael wrote:
  For me the easiest thing was just to provide the right command line 
 options
  (java.awt.headless=true) when I started up Tomcat.
May I ask, how you did this ? I've also encountered
JNI_OnLoad errors runing on Solaris due, I suspect, the lack of
XWindows on my server. I tried adding the headless flag to
my catalina.sh script as follows ~
elif [ $1 = start ] ; then
 shift
 touch $CATALINA_BASE/logs/catalina.out
 if [ $1 = -security ] ; then
 echo Using Security Manager
 shift
 $_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
 -Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
 -Djava.security.manager \
 -Djava.security.policy==$CATALINA_BASE/conf/catalina.policy \
 -Dcatalina.base=$CATALINA_BASE \
 -Dcatalina.home=$CATALINA_HOME \
 -Djava.io.tmpdir=$CATALINA_TMPDIR \
 -Djava.awt.headless=true \
 org.apache.catalina.startup.Bootstrap $@ start \
  $CATALINA_BASE/logs/catalina.out 21 
 else
 $_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
 -Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
 -Dcatalina.base=$CATALINA_BASE \
 -Dcatalina.home=$CATALINA_HOME \
 -Djava.io.tmpdir=$CATALINA_TMPDIR \
 -Djava.awt.headless=true \
 org.apache.catalina.startup.Bootstrap $@ start \
  $CATALINA_BASE/logs/catalina.out 21 
 fi
But that just resulted in the following error,
java.awt.HeadlessException
 at 
 java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:121)
 at java.awt.Window.(Window.java:266)
 at java.awt.Frame.(Frame.java:398)
 at java.awt.Frame.(Frame.java:363)
 at ImageUtils.loadImage(Unknown Source)

where the loadImage() function is simply supposed to load an image,
 public static Image loadImage(String fileName) {
 Image image = Toolkit.getDefaultToolkit().getImage(fileName);
 MediaTracker mediaTracker = new MediaTracker(new Frame());
 mediaTracker.addImage(image, 0);
 try {
 mediaTracker.waitForID(0);
 }
 catch (InterruptedException ie) {
 //
 }
 return image;
 }
Any ideas/help would be great.
Stephen.
ps. I also tried PJA but couldn't get that to work either :(




-
With Yahoo! Mail you can get a bigger mailbox -- choose a size that fits 
your needs



LEGAL NOTICE

This electronic mail transmission and any accompanying documents contain 
information belonging to the sender which may be confidential and legally 
privileged. This information is intended only for the use of the 
individual or entity to whom this electronic mail transmission was sent as 
indicated above. If you are not the intended recipient, any disclosure, 
copying, distribution, or action taken in reliance on the contents of the 
information contained in this transmission is strictly prohibited. If you 
have received this transmission in error, please delete the message. Thank 
you 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
With Yahoo! Mail you can get a bigger mailbox -- choose a size that fits your needs


Re: Can't connect to X11 window server using '0:0' as the valueof the display and now java.awt.HeadlessException

2003-03-23 Thread Georges Roux
Hi,

Here is a good link:
   http://www.geocities.com/marcoschmidt.geo/java-image-faq.html#x
Hope you enjoy.
Georges
Stephen Riek wrote:

Thanks Micael. Tried the same thing and got the same results. 
Looks like Catalina/Tomcat is indeed using headless mode but
it's not working with my Java (1.4) and operating system (SunOS 5.6).
I'm presuming you're using this to create/generate graphics in a
servlet ?  Do you mind posting sample Java that creates a
Toolkit or MediaTracker (and which therefore requires headless 
mode) ? I can't fathom what's wrong with mine. Mine works fine
when running on Win2K and Tomcat, but now dying on Sun.
Thanks for the help,
Stephen.

Micael [EMAIL PROTECTED] wrote:
I added the headless flag to catalina.sh as follows:
# - Execute The Requested Command -

echo Using CATALINA_BASE: $CATALINA_BASE
echo Using CATALINA_HOME: $CATALINA_HOME
echo Using CATALINA_TMPDIR: $CATALINA_TMPDIR
echo Using JAVA_HOME: $JAVA_HOME
if [ $1 = jpda ] ; then
if [ -z $JPDA_ADDRESS ]; then
JPDA_ADDRESS=8000
fi
if [ -z $JDPA_OPTS ]; then
JPDA_OPTS=-Xdebug 
-Xrunjdwp:transport=dt_socket,address=$JPDA_ADDRESS,server=y,suspend=n
fi
CATALINA_OPTS=$CATALINA_OPTS $JPDA_OPTS
shift
fi
CATALINA_OPTS=-Djava.awt.headless=true

This worked fine.

At 08:15 AM 3/23/03 +, you wrote:

 

On Thu, 2003-03-20 at 20:36, Micael wrote:
For me the easiest thing was just to provide the right command line 
 

options
   

(java.awt.headless=true) when I started up Tomcat.
 

May I ask, how you did this ? I've also encountered
JNI_OnLoad errors runing on Solaris due, I suspect, the lack of
XWindows on my server. I tried adding the headless flag to
my catalina.sh script as follows ~
elif [ $1 = start ] ; then
shift
touch $CATALINA_BASE/logs/catalina.out
if [ $1 = -security ] ; then
echo Using Security Manager
shift
$_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
-Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
-Djava.security.manager \
-Djava.security.policy==$CATALINA_BASE/conf/catalina.policy \
-Dcatalina.base=$CATALINA_BASE \
-Dcatalina.home=$CATALINA_HOME \
-Djava.io.tmpdir=$CATALINA_TMPDIR \
-Djava.awt.headless=true \
org.apache.catalina.startup.Bootstrap $@ start \
   

$CATALINA_BASE/logs/catalina.out 21 
   

else
$_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
-Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
-Dcatalina.base=$CATALINA_BASE \
-Dcatalina.home=$CATALINA_HOME \
-Djava.io.tmpdir=$CATALINA_TMPDIR \
-Djava.awt.headless=true \
org.apache.catalina.startup.Bootstrap $@ start \
   

$CATALINA_BASE/logs/catalina.out 21 
   

fi
But that just resulted in the following error,
java.awt.HeadlessException
at 
java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:121)
at java.awt.Window.(Window.java:266)
at java.awt.Frame.(Frame.java:398)
at java.awt.Frame.(Frame.java:363)
at ImageUtils.loadImage(Unknown Source)

where the loadImage() function is simply supposed to load an image,
public static Image loadImage(String fileName) {
Image image = Toolkit.getDefaultToolkit().getImage(fileName);
MediaTracker mediaTracker = new MediaTracker(new Frame());
mediaTracker.addImage(image, 0);
try {
mediaTracker.waitForID(0);
}
catch (InterruptedException ie) {
//
}
return image;
}
Any ideas/help would be great.
Stephen.
ps. I also tried PJA but couldn't get that to work either :(


-
With Yahoo! Mail you can get a bigger mailbox -- choose a size that fits 
your needs
   



LEGAL NOTICE

This electronic mail transmission and any accompanying documents contain 
information belonging to the sender which may be confidential and legally 
privileged. This information is intended only for the use of the 
individual or entity to whom this electronic mail transmission was sent as 
indicated above. If you are not the intended recipient, any disclosure, 
copying, distribution, or action taken in reliance on the contents of the 
information contained in this transmission is strictly prohibited. If you 
have received this transmission in error, please delete the message. Thank 
you 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
With Yahoo! Mail you can get a bigger mailbox -- choose a size that fits your needs
 



Re: Can't connect to X11 window server using '0:0' as the value of the display and now java.awt.HeadlessException

2003-03-23 Thread Micael
Here are two uses, if they are of help.  I am using Red Hat 7.2 Linux.

FIRST:

public JPEGEncoder(Image image, int quality, OutputStream out) {
MediaTracker tracker = new MediaTracker(this);
tracker.addImage(image, 0);
try {
tracker.waitForID(0);
} catch (InterruptedException e) {
}
/* Quality of the image.
 * 0 to 100 and from bad image quality, high compression 
to good
 * image quality low compression*/
this.quality = quality;

/* Getting picture information
 * It takes the Width, Height and RGB scans of the image. */
info= new JPEGInfo(image);
imageHeight = info.imageHeight;
imageWidth  = info.imageWidth;
outStream   = new BufferedOutputStream(out);
dct = new JPEGDCT(quality);
huffman = new JPEGConvert(imageWidth,imageHeight);
}
SECOND:
public class JPEGCompression {
/* The parameter element compressionQuality is the compression 
(compressionQuality) from
 * 0 to 100. */
public void compress(String inputImage, String outputImage, String 
compressionQuality) {
FileOutputStream dataOut = null;
int  compression = 80;

File outputFile = new File(outputImage);
int i = 1;
// Makes sure there are no duplicates
while (outputFile.exists()) {
outputFile = new File(outputImage.substring(0, 
outputImage.lastIndexOf(.)) + (i++) + .jpg);
}

File inputFile = new File(inputImage);

if (inputFile.exists()) {
try {
dataOut = new FileOutputStream(outputFile);
} catch(IOException e) {}
try {
compression = 
Integer.parseInt(compressionQuality);
} catch (NumberFormatException e) {
e.printStackTrace();
}
Image image = 
Toolkit.getDefaultToolkit().getImage(inputImage);
JPEGEncoder encoder = new JPEGEncoder(image, 
compression, dataOut);
encoder.compress();
try {
dataOut.close();
} catch(IOException e) {}
} else {
throw new IllegalArgumentException(We couldn't 
find  + inputImage + . Is it in another directory?);
}
}
}

At 09:09 AM 3/23/03 +, you wrote:

Thanks Micael. Tried the same thing and got the same results.
Looks like Catalina/Tomcat is indeed using headless mode but
it's not working with my Java (1.4) and operating system (SunOS 5.6).
I'm presuming you're using this to create/generate graphics in a
servlet ?  Do you mind posting sample Java that creates a
Toolkit or MediaTracker (and which therefore requires headless
mode) ? I can't fathom what's wrong with mine. Mine works fine
when running on Win2K and Tomcat, but now dying on Sun.
Thanks for the help,
Stephen.
 Micael [EMAIL PROTECTED] wrote:
I added the headless flag to catalina.sh as follows:
# - Execute The Requested Command 
-

echo Using CATALINA_BASE: $CATALINA_BASE
echo Using CATALINA_HOME: $CATALINA_HOME
echo Using CATALINA_TMPDIR: $CATALINA_TMPDIR
echo Using JAVA_HOME: $JAVA_HOME
if [ $1 = jpda ] ; then
if [ -z $JPDA_ADDRESS ]; then
JPDA_ADDRESS=8000
fi
if [ -z $JDPA_OPTS ]; then
JPDA_OPTS=-Xdebug
-Xrunjdwp:transport=dt_socket,address=$JPDA_ADDRESS,server=y,suspend=n
fi
CATALINA_OPTS=$CATALINA_OPTS $JPDA_OPTS
shift
fi
CATALINA_OPTS=-Djava.awt.headless=true
This worked fine.

At 08:15 AM 3/23/03 +, you wrote:

  On Thu, 2003-03-20 at 20:36, Micael wrote:
  For me the easiest thing was just to provide the right command line
 options
  (java.awt.headless=true) when I started up Tomcat.
May I ask, how you did this ? I've also encountered
JNI_OnLoad errors runing on Solaris due, I suspect, the lack of
XWindows on my server. I tried adding the headless flag to
my catalina.sh script as follows ~
elif [ $1 = start ] ; then
 shift
 touch $CATALINA_BASE/logs/catalina.out
 if [ $1 = -security ] ; then
 echo Using Security Manager
 shift
 $_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
 -Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
 -Djava.security.manager \
 -Djava.security.policy==$CATALINA_BASE/conf/catalina.policy \
 -Dcatalina.base=$CATALINA_BASE \
 -Dcatalina.home=$CATALINA_HOME \
 -Djava.io.tmpdir=$CATALINA_TMPDIR \
 -Djava.awt.headless=true \
 org.apache.catalina.startup.Bootstrap $@ start \
  $CATALINA_BASE/logs/catalina.out 21 
 else
 $_RUNJAVA 

Re: Can't connect to X11 window server using '0:0' as the value of the display and now java.awt.HeadlessException

2003-03-23 Thread Micael
The material George gave you is really good.  Do you have X11 installed, 
even if not running?  I am not a Solaris guy, so don't know what that may 
mean in that context.

At 09:09 AM 3/23/03 +, you wrote:

Thanks Micael. Tried the same thing and got the same results.
Looks like Catalina/Tomcat is indeed using headless mode but
it's not working with my Java (1.4) and operating system (SunOS 5.6).
I'm presuming you're using this to create/generate graphics in a
servlet ?  Do you mind posting sample Java that creates a
Toolkit or MediaTracker (and which therefore requires headless
mode) ? I can't fathom what's wrong with mine. Mine works fine
when running on Win2K and Tomcat, but now dying on Sun.
Thanks for the help,
Stephen.
 Micael [EMAIL PROTECTED] wrote:
I added the headless flag to catalina.sh as follows:
# - Execute The Requested Command 
-

echo Using CATALINA_BASE: $CATALINA_BASE
echo Using CATALINA_HOME: $CATALINA_HOME
echo Using CATALINA_TMPDIR: $CATALINA_TMPDIR
echo Using JAVA_HOME: $JAVA_HOME
if [ $1 = jpda ] ; then
if [ -z $JPDA_ADDRESS ]; then
JPDA_ADDRESS=8000
fi
if [ -z $JDPA_OPTS ]; then
JPDA_OPTS=-Xdebug
-Xrunjdwp:transport=dt_socket,address=$JPDA_ADDRESS,server=y,suspend=n
fi
CATALINA_OPTS=$CATALINA_OPTS $JPDA_OPTS
shift
fi
CATALINA_OPTS=-Djava.awt.headless=true
This worked fine.

At 08:15 AM 3/23/03 +, you wrote:

  On Thu, 2003-03-20 at 20:36, Micael wrote:
  For me the easiest thing was just to provide the right command line
 options
  (java.awt.headless=true) when I started up Tomcat.
May I ask, how you did this ? I've also encountered
JNI_OnLoad errors runing on Solaris due, I suspect, the lack of
XWindows on my server. I tried adding the headless flag to
my catalina.sh script as follows ~
elif [ $1 = start ] ; then
 shift
 touch $CATALINA_BASE/logs/catalina.out
 if [ $1 = -security ] ; then
 echo Using Security Manager
 shift
 $_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
 -Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
 -Djava.security.manager \
 -Djava.security.policy==$CATALINA_BASE/conf/catalina.policy \
 -Dcatalina.base=$CATALINA_BASE \
 -Dcatalina.home=$CATALINA_HOME \
 -Djava.io.tmpdir=$CATALINA_TMPDIR \
 -Djava.awt.headless=true \
 org.apache.catalina.startup.Bootstrap $@ start \
  $CATALINA_BASE/logs/catalina.out 21 
 else
 $_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
 -Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
 -Dcatalina.base=$CATALINA_BASE \
 -Dcatalina.home=$CATALINA_HOME \
 -Djava.io.tmpdir=$CATALINA_TMPDIR \
 -Djava.awt.headless=true \
 org.apache.catalina.startup.Bootstrap $@ start \
  $CATALINA_BASE/logs/catalina.out 21 
 fi
But that just resulted in the following error,
java.awt.HeadlessException
 at
 java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:121)
 at java.awt.Window.(Window.java:266)
 at java.awt.Frame.(Frame.java:398)
 at java.awt.Frame.(Frame.java:363)
 at ImageUtils.loadImage(Unknown Source)

where the loadImage() function is simply supposed to load an image,
 public static Image loadImage(String fileName) {
 Image image = Toolkit.getDefaultToolkit().getImage(fileName);
 MediaTracker mediaTracker = new MediaTracker(new Frame());
 mediaTracker.addImage(image, 0);
 try {
 mediaTracker.waitForID(0);
 }
 catch (InterruptedException ie) {
 //
 }
 return image;
 }
Any ideas/help would be great.
Stephen.
ps. I also tried PJA but couldn't get that to work either :(




-
With Yahoo! Mail you can get a bigger mailbox -- choose a size that fits
your needs


LEGAL NOTICE

This electronic mail transmission and any accompanying documents contain
information belonging to the sender which may be confidential and legally
privileged. This information is intended only for the use of the
individual or entity to whom this electronic mail transmission was sent as
indicated above. If you are not the intended recipient, any disclosure,
copying, distribution, or action taken in reliance on the contents of the
information contained in this transmission is strictly prohibited. If you
have received this transmission in error, please delete the message. Thank
you


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
With Yahoo! Mail you can get a bigger mailbox -- choose a size that fits 
your needs


LEGAL NOTICE

This electronic mail  transmission and any accompanying documents contain 
information belonging to the sender which may be confidential and legally 
privileged.  This information is intended only for the use of the 
individual or entity to whom this electronic mail transmission was sent as 
indicated above. If you are not the intended recipient, any disclosure, 
copying, distribution, or action taken in reliance on the contents of the 
information contained in this transmission is strictly 

Re: Can't connect to X11 window server using '0:0' as the value of the display and now java.awt.HeadlessException

2003-03-23 Thread Luciano Kiniti Issoe
Hi all,

It have been a long time since I read any post... but I can't ignore someone in 
trouble.
I had a similar problem using java.AWT with linux...
It needs a graphics system server, like windows or X11 running in your server. 
But as X11 was too heavy for my system, my workaround was to start Xvfb (X virtual 
frame buffer). Google it  to 
get a Solaris Xvfb...
take a look also at 
http://developer.java.sun.com/developer/bugParade/bugs/4281163.html 

Regards,

miagi


On Sun, 23 Mar 2003 12:15:04 -0800, Micael [EMAIL PROTECTED] escreveu :

 De: Micael [EMAIL PROTECTED]
 Data: Sun, 23 Mar 2003 12:15:04 -0800
 Para: Tomcat Users List [EMAIL PROTECTED]
 Assunto: Re: Can't connect to X11 window server using '0:0' as the   value of the 
 display and now 
java.awt.HeadlessException
 
 The material George gave you is really good.  Do you have X11 installed, 
 even if not running?  I am not a Solaris guy, so don't know what that may 
 mean in that context.
 
 At 09:09 AM 3/23/03 +, you wrote:
 
 Thanks Micael. Tried the same thing and got the same results.
 Looks like Catalina/Tomcat is indeed using headless mode but
 it's not working with my Java (1.4) and operating system (SunOS 5.6).
 I'm presuming you're using this to create/generate graphics in a
 servlet ?  Do you mind posting sample Java that creates a
 Toolkit or MediaTracker (and which therefore requires headless
 mode) ? I can't fathom what's wrong with mine. Mine works fine
 when running on Win2K and Tomcat, but now dying on Sun.
 Thanks for the help,
 Stephen.
 
   Micael [EMAIL PROTECTED] wrote:
 I added the headless flag to catalina.sh as follows:
 
 # - Execute The Requested Command 
 -
 
 echo Using CATALINA_BASE: $CATALINA_BASE
 echo Using CATALINA_HOME: $CATALINA_HOME
 echo Using CATALINA_TMPDIR: $CATALINA_TMPDIR
 echo Using JAVA_HOME: $JAVA_HOME
 
 if [ $1 = jpda ] ; then
 if [ -z $JPDA_ADDRESS ]; then
 JPDA_ADDRESS=8000
 fi
 if [ -z $JDPA_OPTS ]; then
 JPDA_OPTS=-Xdebug
 -Xrunjdwp:transport=dt_socket,address=$JPDA_ADDRESS,server=y,suspend=n
 fi
 CATALINA_OPTS=$CATALINA_OPTS $JPDA_OPTS
 shift
 fi
 CATALINA_OPTS=-Djava.awt.headless=true
 
 This worked fine.
 
 
 At 08:15 AM 3/23/03 +, you wrote:
 
On Thu, 2003-03-20 at 20:36, Micael wrote:
For me the easiest thing was just to provide the right command line
   options
(java.awt.headless=true) when I started up Tomcat.
  May I ask, how you did this ? I've also encountered
  JNI_OnLoad errors runing on Solaris due, I suspect, the lack of
  XWindows on my server. I tried adding the headless flag to
  my catalina.sh script as follows ~
  elif [ $1 = start ] ; then
   shift
   touch $CATALINA_BASE/logs/catalina.out
   if [ $1 = -security ] ; then
   echo Using Security Manager
   shift
   $_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
   -Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
   -Djava.security.manager \
   -Djava.security.policy==$CATALINA_BASE/conf/catalina.policy \
   -Dcatalina.base=$CATALINA_BASE \
   -Dcatalina.home=$CATALINA_HOME \
   -Djava.io.tmpdir=$CATALINA_TMPDIR \
   -Djava.awt.headless=true \
   org.apache.catalina.startup.Bootstrap $@ start \
$CATALINA_BASE/logs/catalina.out 21 
   else
   $_RUNJAVA $JAVA_OPTS $CATALINA_OPTS \
   -Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS -classpath $CLASSPATH \
   -Dcatalina.base=$CATALINA_BASE \
   -Dcatalina.home=$CATALINA_HOME \
   -Djava.io.tmpdir=$CATALINA_TMPDIR \
   -Djava.awt.headless=true \
   org.apache.catalina.startup.Bootstrap $@ start \
$CATALINA_BASE/logs/catalina.out 21 
   fi
  But that just resulted in the following error,
  java.awt.HeadlessException
   at
   java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:121)
   at java.awt.Window.(Window.java:266)
   at java.awt.Frame.(Frame.java:398)
   at java.awt.Frame.(Frame.java:363)
   at ImageUtils.loadImage(Unknown Source)
  
  where the loadImage() function is simply supposed to load an image,
   public static Image loadImage(String fileName) {
   Image image = Toolkit.getDefaultToolkit().getImage(fileName);
   MediaTracker mediaTracker = new MediaTracker(new Frame());
   mediaTracker.addImage(image, 0);
   try {
   mediaTracker.waitForID(0);
   }
   catch (InterruptedException ie) {
   //
   }
   return image;
   }
  Any ideas/help would be great.
  Stephen.
  ps. I also tried PJA but couldn't get that to work either :(
  
  
  
  
  -
  With Yahoo! Mail you can get a bigger mailbox -- choose a size that fits
  your needs
 
 
 
 LEGAL NOTICE
 
 This electronic mail transmission and any accompanying documents contain
 information belonging to the sender which may be confidential and legally
 privileged. This information is intended only for the use of the
 individual or entity to whom this electronic mail transmission was sent as
 indicated above. If you are not the intended recipient, any disclosure,
 copying, distribution, or action taken

Re: Can't connect to X11 window server using '0:0' as the value ofthe display and now java.awt.HeadlessException

2003-03-20 Thread Georges Roux
Hi,

I put System.setProperty(java.awt.headless, true);
in my servlet init method it's ok, but now when I open a Frame,
I get the exception HeadlessException:
java.awt.HeadlessException
   at 
java.awt.GraphicsEnvironnement.checkHeadless(GraphicsEnvironement.java:121)
   at java.awt.window.init(Window.java:226)
   at java.awt.Frame.init(Frame.java:398)
   ...

What can I do?

Georges



Chad Johnson wrote:

If I had to wager a guess you'll need to run tomcat in a 'headless' JVM.
To do that add :
-Djava.awt.headless=true

To the :

CATALINA_OPTS

environment variable.

-Chad Johnson

-Original Message-
From: Georges Roux [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, March 18, 2003 5:32 PM
To: [EMAIL PROTECTED]
Subject: Can't connect to X11 window server using '0:0' as the value of
the display

Hello everybody,

Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use
J2sdk1.4.1_01.
I have a servlet which manipulate exif informations in jpg images. it
works well but when I try to run it on tomcat it fails (error 500)
I have the following error:
Can't connect to X11 window server using '0:0' as the value of the
display
What can I do?

Georges

-
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]
 

--

18:54 18:54 connard
18:55 18:54 t'as que ca a faire? ;)
18:56 18:55 je m'ennuies ferme ouais ! encore 5mn avant la fin du taf,
 donc j'en profite pour passer dans les fortunes :)
+==+
|  |
|  Georges Roux|
|  URL : georgesroux.pacageek.org  |
|  email : [EMAIL PROTECTED]|
|  mobile : +33 (0) 613977573  |
+==+


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Can't connect to X11 window server using '0:0' as the value of the display and now java.awt.HeadlessException

2003-03-20 Thread Chad Johnson
Hey,
  From the 1.4.x api docs:

HeadlessException: Thrown when code that is dependent on a keyboard,
display, or mouse is called in an environment that does not support a
keyboard, display, or mouse.

That Frame seems to be the culprit of this.

-Chad Johnson

-Original Message-
From: Georges Roux [mailto:[EMAIL PROTECTED] 
Sent: Thursday, March 20, 2003 11:09 AM
To: Tomcat Users List
Subject: Re: Can't connect to X11 window server using '0:0' as the value
of the display and now java.awt.HeadlessException


Hi,

I put System.setProperty(java.awt.headless, true);
in my servlet init method it's ok, but now when I open a Frame, I get
the exception HeadlessException:

java.awt.HeadlessException
at 
java.awt.GraphicsEnvironnement.checkHeadless(GraphicsEnvironement.java:1
21)
at java.awt.window.init(Window.java:226)
at java.awt.Frame.init(Frame.java:398)
...

What can I do?

Georges



Chad Johnson wrote:

If I had to wager a guess you'll need to run tomcat in a 'headless' 
JVM. To do that add :

-Djava.awt.headless=true

To the :

CATALINA_OPTS

environment variable.

-Chad Johnson

-Original Message-
From: Georges Roux [mailto:[EMAIL PROTECTED]
Sent: Tuesday, March 18, 2003 5:32 PM
To: [EMAIL PROTECTED]
Subject: Can't connect to X11 window server using '0:0' as the value of
the display


Hello everybody,

Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use 
J2sdk1.4.1_01.

I have a servlet which manipulate exif informations in jpg images. it 
works well but when I try to run it on tomcat it fails (error 500)

I have the following error:
Can't connect to X11 window server using '0:0' as the value of the 
display

What can I do?

Georges


-
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]

  


-- 

18:54 18:54 connard
18:55 18:54 t'as que ca a faire? ;)
18:56 18:55 je m'ennuies ferme ouais ! encore 5mn avant la fin du taf,
  donc j'en profite pour passer dans les fortunes :)


+==+
|  |
|  Georges Roux|
|  URL : georgesroux.pacageek.org  |
|  email : [EMAIL PROTECTED]|
|  mobile : +33 (0) 613977573  |
+==+



-
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: Can't connect to X11 window server using '0:0' as the value of the display and now java.awt.HeadlessException

2003-03-20 Thread Micael
You using Linux?  What is your environment?  Anyway, setting the JVM is the 
way to go if you are using Linux.

At 06:09 PM 3/20/03 +0100, you wrote:
Hi,

I put System.setProperty(java.awt.headless, true);
in my servlet init method it's ok, but now when I open a Frame,
I get the exception HeadlessException:
java.awt.HeadlessException
   at 
java.awt.GraphicsEnvironnement.checkHeadless(GraphicsEnvironement.java:121)
   at java.awt.window.init(Window.java:226)
   at java.awt.Frame.init(Frame.java:398)
   ...

What can I do?

Georges



Chad Johnson wrote:

If I had to wager a guess you'll need to run tomcat in a 'headless' JVM.
To do that add :
-Djava.awt.headless=true

To the :

CATALINA_OPTS

environment variable.

-Chad Johnson

-Original Message-
From: Georges Roux [mailto:[EMAIL PROTECTED] Sent: Tuesday, 
March 18, 2003 5:32 PM
To: [EMAIL PROTECTED]
Subject: Can't connect to X11 window server using '0:0' as the value of
the display

Hello everybody,

Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use
J2sdk1.4.1_01.
I have a servlet which manipulate exif informations in jpg images. it
works well but when I try to run it on tomcat it fails (error 500)
I have the following error:
Can't connect to X11 window server using '0:0' as the value of the
display
What can I do?

Georges

-
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]

--

18:54 18:54 connard
18:55 18:54 t'as que ca a faire? ;)
18:56 18:55 je m'ennuies ferme ouais ! encore 5mn avant la fin du taf,
 donc j'en profite pour passer dans les fortunes :)
+==+
|  |
|  Georges Roux|
|  URL : georgesroux.pacageek.org  |
|  email : [EMAIL PROTECTED]|
|  mobile : +33 (0) 613977573  |
+==+


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


LEGAL NOTICE

This electronic mail  transmission and any accompanying documents contain 
information belonging to the sender which may be confidential and legally 
privileged.  This information is intended only for the use of the 
individual or entity to whom this electronic mail transmission was sent as 
indicated above. If you are not the intended recipient, any disclosure, 
copying, distribution, or action taken in reliance on the contents of the 
information contained in this transmission is strictly prohibited.  If you 
have received this transmission in error, please delete the message.  Thank 
you  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Can't connect to X11 window server using '0:0' as the value ofthe display and now java.awt.HeadlessException

2003-03-20 Thread p niemandt
ok: there is another solution to the headless thing: (I wrote a
graphical servlet that runs on a linux box without X, and had the same
problems: The headless seemed to work, well, kinda, but not to my
liking): So I went the xvfb route: This is a virtual frame buffer to can
install on a linux box that emulates an X session, which then kinda
solves all the graphical problems in one step. You set the xvfb to the
resolution required and just start and forget about it. 

Worth I shot, I'd say, and might safe you hours of frustration [It did
me ;-) ].


On Thu, 2003-03-20 at 18:34, Micael wrote:
 You using Linux?  What is your environment?  Anyway, setting the JVM is the 
 way to go if you are using Linux.
 
 At 06:09 PM 3/20/03 +0100, you wrote:
 Hi,
 
 I put System.setProperty(java.awt.headless, true);
 in my servlet init method it's ok, but now when I open a Frame,
 I get the exception HeadlessException:
 
 java.awt.HeadlessException
 at 
  java.awt.GraphicsEnvironnement.checkHeadless(GraphicsEnvironement.java:121)
 at java.awt.window.init(Window.java:226)
 at java.awt.Frame.init(Frame.java:398)
 ...
 
 What can I do?
 
 Georges
 
 
 
 Chad Johnson wrote:
 
 If I had to wager a guess you'll need to run tomcat in a 'headless' JVM.
 To do that add :
 
 -Djava.awt.headless=true
 
 To the :
 
 CATALINA_OPTS
 
 environment variable.
 
 -Chad Johnson
 
 -Original Message-
 From: Georges Roux [mailto:[EMAIL PROTECTED] Sent: Tuesday, 
 March 18, 2003 5:32 PM
 To: [EMAIL PROTECTED]
 Subject: Can't connect to X11 window server using '0:0' as the value of
 the display
 
 
 Hello everybody,
 
 Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use
 J2sdk1.4.1_01.
 
 I have a servlet which manipulate exif informations in jpg images. it
 works well but when I try to run it on tomcat it fails (error 500)
 
 I have the following error:
 Can't connect to X11 window server using '0:0' as the value of the
 display
 
 What can I do?
 
 Georges
 
 
 -
 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]
 
 
 
 --
 
 18:54 18:54 connard
 18:55 18:54 t'as que ca a faire? ;)
 18:56 18:55 je m'ennuies ferme ouais ! encore 5mn avant la fin du taf,
   donc j'en profite pour passer dans les fortunes :)
 
 
 +==+
 |  |
 |  Georges Roux|
 |  URL : georgesroux.pacageek.org  |
 |  email : [EMAIL PROTECTED]|
 |  mobile : +33 (0) 613977573  |
 +==+
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 
 LEGAL NOTICE
 
 This electronic mail  transmission and any accompanying documents contain 
 information belonging to the sender which may be confidential and legally 
 privileged.  This information is intended only for the use of the 
 individual or entity to whom this electronic mail transmission was sent as 
 indicated above. If you are not the intended recipient, any disclosure, 
 copying, distribution, or action taken in reliance on the contents of the 
 information contained in this transmission is strictly prohibited.  If you 
 have received this transmission in error, please delete the message.  Thank 
 you  
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
-- 
p niemandt [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Can't connect to X11 window server using '0:0' as the value of the display and now java.awt.HeadlessException

2003-03-20 Thread Glenn Parsons
At 07:18 PM 3/20/2003 +, you wrote:
ok: there is another solution to the headless thing: (I wrote a
graphical servlet that runs on a linux box without X, and had the same
problems: The headless seemed to work, well, kinda, but not to my
liking): So I went the xvfb route: This is a virtual frame buffer to can
install on a linux box that emulates an X session, which then kinda
solves all the graphical problems in one step. You set the xvfb to the
resolution required and just start and forget about it.
Worth I shot, I'd say, and might safe you hours of frustration [It did
me ;-) ].
 I had tried xvfb and had some difficulties. Any pointers? suggestions?

Thanks,
Glenn


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Can't connect to X11 window server using '0:0' as the value ofthe display and now java.awt.HeadlessException

2003-03-20 Thread p niemandt
Difficult to say: What kind of problems?

I start mine using

Xvfb :0 -screen 0 1600x1200x32 

{I just added it to rc.local }




On Thu, 2003-03-20 at 19:27, Glenn Parsons wrote:
 At 07:18 PM 3/20/2003 +, you wrote:
 ok: there is another solution to the headless thing: (I wrote a
 graphical servlet that runs on a linux box without X, and had the same
 problems: The headless seemed to work, well, kinda, but not to my
 liking): So I went the xvfb route: This is a virtual frame buffer to can
 install on a linux box that emulates an X session, which then kinda
 solves all the graphical problems in one step. You set the xvfb to the
 resolution required and just start and forget about it.
 
 Worth I shot, I'd say, and might safe you hours of frustration [It did
 me ;-) ].
 
   I had tried xvfb and had some difficulties. Any pointers? suggestions?
 
 Thanks,
 Glenn
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
-- 
p niemandt [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Can't connect to X11 window server using '0:0' as the value of the display and now java.awt.HeadlessException

2003-03-20 Thread Glenn Parsons


At 07:59 PM 3/20/2003 +, you wrote:
Difficult to say: What kind of problems?

I start mine using

Xvfb :0 -screen 0 1600x1200x32 

{I just added it to rc.local }

Will retry with resolution change.

Thanks,
Glenn


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Can't connect to X11 window server using '0:0' as the value of the display and now java.awt.HeadlessException

2003-03-20 Thread Micael
For me the easiest thing was just to provide the right command line options 
(java.awt.headless=true) when I started up Tomcat.

At 02:27 PM 3/20/03 -0500, you wrote:
At 07:18 PM 3/20/2003 +, you wrote:
ok: there is another solution to the headless thing: (I wrote a
graphical servlet that runs on a linux box without X, and had the same
problems: The headless seemed to work, well, kinda, but not to my
liking): So I went the xvfb route: This is a virtual frame buffer to can
install on a linux box that emulates an X session, which then kinda
solves all the graphical problems in one step. You set the xvfb to the
resolution required and just start and forget about it.
Worth I shot, I'd say, and might safe you hours of frustration [It did
me ;-) ].
 I had tried xvfb and had some difficulties. Any pointers? suggestions?

Thanks,
Glenn


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


LEGAL NOTICE

This electronic mail  transmission and any accompanying documents contain 
information belonging to the sender which may be confidential and legally 
privileged.  This information is intended only for the use of the 
individual or entity to whom this electronic mail transmission was sent as 
indicated above. If you are not the intended recipient, any disclosure, 
copying, distribution, or action taken in reliance on the contents of the 
information contained in this transmission is strictly prohibited.  If you 
have received this transmission in error, please delete the message.  Thank 
you  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Can't connect to X11 window server using '0:0' as the value ofthe display and now java.awt.HeadlessException

2003-03-20 Thread Chris Dodunski
Hi,

Another common (Java) solution is to install PJA Toolkit:

PJA (Pure Java AWT) Toolkit is a JavaTM library for drawing graphics
developed by eTeks. It is 100% Pure Java and doesn't use any native graphics
resource of the system on which the Java Virtual Machine runs.
java.awt.Graphics methods such as drawLine (), fillOval (), drawString
(),... are implemented in the default JVM with native graphical functions
(except in some cases for Java2D) : That means that drawLine () finally
calls a GDI system function on Windows or X11 function on a X11/UNIX machine
even if the drawing is done in an off-screen image using the class
java.awt.Image. This ensures the best performance for drawing graphics with
Java.
But in a few cases, this default behavior can cause problems that PJA
library improves :

When no X11 Display is available on a UNIX machine (also called headless
environment) or when GDI resources are low on Windows, it is impossible to
compute off-screen images with java.awt.Graphics methods under a JDK version
 1.4, even if your program doesn't need to display these images. Typically,
this situation happens for servlets returning dynamically generated images
like pies, charts or web counters.
With PJA, you don't need to change your Java programs that you expected to
run : setting java.awt system property to com.eteks.awt.PJAToolkit is the
only required modification to your program with Java 1.1 (see PJA FAQ and
com.eteks.awt.PJAToolkit class documentation for more information).
It is also impossible to compute off-screen images when the Java security
manager forbids access to any Toolkit or the AWT library. In that case you
can although create an instance of com.eteks.awt.PJAImage class which
extends java.awt.Image, and draw into it with graphics methods.
Drawing with native function doesn't give always the exact same results for
each pixel on all platforms. For example, SansSerif font renders differently
on MacOS, Windows and other systems : each letter of this font isn't drawn
the same, and is different if font anti-aliasing is set or not on the
system. On MacOS, circles aren't rendered as specified in Java documentation
: fillArc () and drawArc () don't use the same base ellipse...

Finally, PJA library available under GNU General Public License is supplied
with its Java source files, and is a good exemple for studying :

How pixels are drawn by graphics functions on a computer
(com.eteks.awt.PJAGraphics uses Bresenham algorithms to draw lines and
circles).
How to use the Java paradigm for managing images specified by the
ImageConsumer/ImageProducer/ImageObserver interfaces.
How Java Toolkit works and what it needs to work (which abstract classes and
interfaces to implement).

Regards,

Chris.


-Original Message-
From: p niemandt [mailto:[EMAIL PROTECTED]
Sent: Friday, 21 March 2003 7:18 a.m.
To: Tomcat Users List
Subject: Re: Can't connect to X11 window server using '0:0' as the value
ofthe display and now java.awt.HeadlessException


ok: there is another solution to the headless thing: (I wrote a
graphical servlet that runs on a linux box without X, and had the same
problems: The headless seemed to work, well, kinda, but not to my
liking): So I went the xvfb route: This is a virtual frame buffer to can
install on a linux box that emulates an X session, which then kinda
solves all the graphical problems in one step. You set the xvfb to the
resolution required and just start and forget about it.

Worth I shot, I'd say, and might safe you hours of frustration [It did
me ;-) ].


On Thu, 2003-03-20 at 18:34, Micael wrote:
 You using Linux?  What is your environment?  Anyway, setting the JVM is
the
 way to go if you are using Linux.

 At 06:09 PM 3/20/03 +0100, you wrote:
 Hi,
 
 I put System.setProperty(java.awt.headless, true);
 in my servlet init method it's ok, but now when I open a Frame,
 I get the exception HeadlessException:
 
 java.awt.HeadlessException
 at
 
java.awt.GraphicsEnvironnement.checkHeadless(GraphicsEnvironement.java:121)
 at java.awt.window.init(Window.java:226)
 at java.awt.Frame.init(Frame.java:398)
 ...
 
 What can I do?
 
 Georges
 
 
 
 Chad Johnson wrote:
 
 If I had to wager a guess you'll need to run tomcat in a 'headless' JVM.
 To do that add :
 
 -Djava.awt.headless=true
 
 To the :
 
 CATALINA_OPTS
 
 environment variable.
 
 -Chad Johnson
 
 -Original Message-
 From: Georges Roux [mailto:[EMAIL PROTECTED] Sent: Tuesday,
 March 18, 2003 5:32 PM
 To: [EMAIL PROTECTED]
 Subject: Can't connect to X11 window server using '0:0' as the value of
 the display
 
 
 Hello everybody,
 
 Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use
 J2sdk1.4.1_01.
 
 I have a servlet which manipulate exif informations in jpg images. it
 works well but when I try to run it on tomcat it fails (error 500)
 
 I have the following error:
 Can't connect to X11 window server using '0:0' as the value of the
 display
 
 What can I do?
 
 Georges

Re: Can't connect to X11 window server using '0:0' as the value ofthe display and now java.awt.HeadlessException

2003-03-20 Thread p niemandt
Yep: Done correctly, this is probably the more 'correct' solution, but,
and I'm probably opening myself to a lot of flamebait, but I do suspect
that using something like Xvfb might give some advantages that using
headless won't. For example, and I'm just guessing, but I think that
'headless' is purely a software solution, while Xvfb might be connected
to your display adaptor, and therefor might be faster or less of a drain
on your system resources.

{
But, like I said, I have no documentation to back up this statement,
this is purely a guess and based on my personal findings: If anybody
else knows differently, I would be very interested to know more, as I'm
doing a lot more graphics orientated servlets, that usually run on
headless boxes }



On Thu, 2003-03-20 at 20:36, Micael wrote:
 For me the easiest thing was just to provide the right command line options 
 (java.awt.headless=true) when I started up Tomcat.
 
 At 02:27 PM 3/20/03 -0500, you wrote:
 At 07:18 PM 3/20/2003 +, you wrote:
 ok: there is another solution to the headless thing: (I wrote a
 graphical servlet that runs on a linux box without X, and had the same
 problems: The headless seemed to work, well, kinda, but not to my
 liking): So I went the xvfb route: This is a virtual frame buffer to can
 install on a linux box that emulates an X session, which then kinda
 solves all the graphical problems in one step. You set the xvfb to the
 resolution required and just start and forget about it.
 
 Worth I shot, I'd say, and might safe you hours of frustration [It did
 me ;-) ].
   I had tried xvfb and had some difficulties. Any pointers? suggestions?
 
 Thanks,
 Glenn
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 
 LEGAL NOTICE
 
 This electronic mail  transmission and any accompanying documents contain 
 information belonging to the sender which may be confidential and legally 
 privileged.  This information is intended only for the use of the 
 individual or entity to whom this electronic mail transmission was sent as 
 indicated above. If you are not the intended recipient, any disclosure, 
 copying, distribution, or action taken in reliance on the contents of the 
 information contained in this transmission is strictly prohibited.  If you 
 have received this transmission in error, please delete the message.  Thank 
 you  
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
-- 
p niemandt [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Can't connect to X11 window server using '0:0' as the value ofthe display and now java.awt.HeadlessException

2003-03-20 Thread Andy Eastham
Hi,

I would say that Xvfb does _not_ connect to your display adapter - the v
stands for virtual, ie it's not a real frame buffer as in a video card -
it's a virtual one in your systems normal memory.

It's specifically for taking the place of a display adapter when your server
doesn't have one.

We always used to use this on sun E250s without a display adapter, but now
we use headless as it's more reliable.

Andy

 -Original Message-
 From: p niemandt [mailto:[EMAIL PROTECTED]
 Sent: 20 March 2003 21:47
 To: Tomcat Users List
 Subject: Re: Can't connect to X11 window server using '0:0' as the value
 ofthe display and now java.awt.HeadlessException


 Yep: Done correctly, this is probably the more 'correct' solution, but,
 and I'm probably opening myself to a lot of flamebait, but I do suspect
 that using something like Xvfb might give some advantages that using
 headless won't. For example, and I'm just guessing, but I think that
 'headless' is purely a software solution, while Xvfb might be connected
 to your display adaptor, and therefor might be faster or less of a drain
 on your system resources.

 {
 But, like I said, I have no documentation to back up this statement,
 this is purely a guess and based on my personal findings: If anybody
 else knows differently, I would be very interested to know more, as I'm
 doing a lot more graphics orientated servlets, that usually run on
 headless boxes }



 On Thu, 2003-03-20 at 20:36, Micael wrote:
  For me the easiest thing was just to provide the right command
 line options
  (java.awt.headless=true) when I started up Tomcat.
 
  At 02:27 PM 3/20/03 -0500, you wrote:
  At 07:18 PM 3/20/2003 +, you wrote:
  ok: there is another solution to the headless thing: (I wrote a
  graphical servlet that runs on a linux box without X, and had the same
  problems: The headless seemed to work, well, kinda, but not to my
  liking): So I went the xvfb route: This is a virtual frame
 buffer to can
  install on a linux box that emulates an X session, which then kinda
  solves all the graphical problems in one step. You set the xvfb to the
  resolution required and just start and forget about it.
  
  Worth I shot, I'd say, and might safe you hours of frustration [It did
  me ;-) ].
I had tried xvfb and had some difficulties. Any pointers?
 suggestions?
  
  Thanks,
  Glenn
  
  
  
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
  
 
 
 
  LEGAL NOTICE
 
  This electronic mail  transmission and any accompanying
 documents contain
  information belonging to the sender which may be confidential
 and legally
  privileged.  This information is intended only for the use of the
  individual or entity to whom this electronic mail transmission
 was sent as
  indicated above. If you are not the intended recipient, any disclosure,
  copying, distribution, or action taken in reliance on the
 contents of the
  information contained in this transmission is strictly
 prohibited.  If you
  have received this transmission in error, please delete the
 message.  Thank
  you
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 --
 p niemandt [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: Can't connect to X11 window server using '0:0' as the value ofthedisplay and now java.awt.HeadlessException

2003-03-20 Thread Georges Roux
Sorry but with headless I can't create a Frame, with Xvfb I can.

Georges

Andy Eastham wrote:

Hi,

I would say that Xvfb does _not_ connect to your display adapter - the v
stands for virtual, ie it's not a real frame buffer as in a video card -
it's a virtual one in your systems normal memory.
It's specifically for taking the place of a display adapter when your server
doesn't have one.
We always used to use this on sun E250s without a display adapter, but now
we use headless as it's more reliable.
Andy

 

-Original Message-
From: p niemandt [mailto:[EMAIL PROTECTED]
Sent: 20 March 2003 21:47
To: Tomcat Users List
Subject: Re: Can't connect to X11 window server using '0:0' as the value
ofthe display and now java.awt.HeadlessException
Yep: Done correctly, this is probably the more 'correct' solution, but,
and I'm probably opening myself to a lot of flamebait, but I do suspect
that using something like Xvfb might give some advantages that using
headless won't. For example, and I'm just guessing, but I think that
'headless' is purely a software solution, while Xvfb might be connected
to your display adaptor, and therefor might be faster or less of a drain
on your system resources.
{
But, like I said, I have no documentation to back up this statement,
this is purely a guess and based on my personal findings: If anybody
else knows differently, I would be very interested to know more, as I'm
doing a lot more graphics orientated servlets, that usually run on
headless boxes }


On Thu, 2003-03-20 at 20:36, Micael wrote:
   

For me the easiest thing was just to provide the right command
 

line options
   

(java.awt.headless=true) when I started up Tomcat.

At 02:27 PM 3/20/03 -0500, you wrote:
 

At 07:18 PM 3/20/2003 +, you wrote:
   

ok: there is another solution to the headless thing: (I wrote a
graphical servlet that runs on a linux box without X, and had the same
problems: The headless seemed to work, well, kinda, but not to my
liking): So I went the xvfb route: This is a virtual frame
 

buffer to can
   

install on a linux box that emulates an X session, which then kinda
solves all the graphical problems in one step. You set the xvfb to the
resolution required and just start and forget about it.
Worth I shot, I'd say, and might safe you hours of frustration [It did
me ;-) ].
 

I had tried xvfb and had some difficulties. Any pointers?
   

suggestions?
   

Thanks,
Glenn


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
   

LEGAL NOTICE

This electronic mail  transmission and any accompanying
 

documents contain
   

information belonging to the sender which may be confidential
 

and legally
   

privileged.  This information is intended only for the use of the
individual or entity to whom this electronic mail transmission
 

was sent as
   

indicated above. If you are not the intended recipient, any disclosure,
copying, distribution, or action taken in reliance on the
 

contents of the
   

information contained in this transmission is strictly
 

prohibited.  If you
   

have received this transmission in error, please delete the
 

message.  Thank
   

you



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
 

--
p niemandt [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]


Re: Can't connect to X11 window server using '0:0' as the value ofthe display

2003-03-19 Thread Bill Barker

Zsolt Koppany [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
 Hi,

 does it need modifications in the application or it will work with every
AWT
 dependent application?

Depends what you want to do basically.  Running headless causes the JVM to
replace most of the basic functions that you previously needed to be
provided by the standard Linux utility Xvfb (e.g. fonts, color-mappings).

I can think of cases where headless isn't enough, but if you are that
creative, it deserves another topic ;-)


 Zsolt

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]
 Behalf Of Theodore Chen
 Sent: Mittwoch, 19. März 2003 00:37
 To: Tomcat Users List
 Subject: Re: Can't connect to X11 window server using '0:0' as the value
 ofthe display


 Try running the Tomcat VM with the -Djava.awt.headless=true system
 property (set it in an environment variable named CATALINA_OPTS).

 On Tue, 2003-03-18 at 16:31, Georges Roux wrote:
  Hello everybody,
 
  Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use
J2sdk1.4.1_01.
 
  I have a servlet which manipulate exif informations in jpg images.
  it works well but when I try to run it on tomcat it fails (error 500)
 
  I have the following error:
  Can't connect to X11 window server using '0:0' as the value of the
 display
 
  What can I do?
 
  Georges
 
 
  -
  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: Can't connect to X11 window server using '0:0' as the value ofthedisplay

2003-03-19 Thread Georges Roux
Thanks,

I put System.setProperty(java.awt.headless, true);
in my servlet init method and it's ok now.
Georges

Bill Barker wrote:

Zsolt Koppany [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
 

Hi,

does it need modifications in the application or it will work with every
   

AWT
 

dependent application?
   

Depends what you want to do basically.  Running headless causes the JVM to
replace most of the basic functions that you previously needed to be
provided by the standard Linux utility Xvfb (e.g. fonts, color-mappings).
I can think of cases where headless isn't enough, but if you are that
creative, it deserves another topic ;-)
 

Zsolt

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]
Behalf Of Theodore Chen
Sent: Mittwoch, 19. März 2003 00:37
To: Tomcat Users List
Subject: Re: Can't connect to X11 window server using '0:0' as the value
ofthe display
Try running the Tomcat VM with the -Djava.awt.headless=true system
property (set it in an environment variable named CATALINA_OPTS).
On Tue, 2003-03-18 at 16:31, Georges Roux wrote:
   

Hello everybody,

Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use
 

J2sdk1.4.1_01.
 

I have a servlet which manipulate exif informations in jpg images.
it works well but when I try to run it on tomcat it fails (error 500)
I have the following error:
Can't connect to X11 window server using '0:0' as the value of the
 

display
   

What can I do?

Georges

-
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]


Re: Can't connect to X11 window server using '0:0' as the value ofthe display

2003-03-19 Thread Per Erik Nordbø
Georges Roux wrote:

Hello everybody,

Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use 
J2sdk1.4.1_01.

I have a servlet which manipulate exif informations in jpg images.
it works well but when I try to run it on tomcat it fails (error 500)
I have the following error:
Can't connect to X11 window server using '0:0' as the value of the 
display

What can I do?

Georges

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Try 'xhost +' as root.

per erik



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Can't connect to X11 window server using '0:0' as the value of the display

2003-03-19 Thread Chad Johnson
If I had to wager a guess you'll need to run tomcat in a 'headless' JVM.
To do that add :

-Djava.awt.headless=true

To the :

CATALINA_OPTS

environment variable.

-Chad Johnson

-Original Message-
From: Georges Roux [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, March 18, 2003 5:32 PM
To: [EMAIL PROTECTED]
Subject: Can't connect to X11 window server using '0:0' as the value of
the display


Hello everybody,

Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use
J2sdk1.4.1_01.

I have a servlet which manipulate exif informations in jpg images. it
works well but when I try to run it on tomcat it fails (error 500)

I have the following error:
Can't connect to X11 window server using '0:0' as the value of the
display

What can I do?

Georges


-
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]



Can't connect to X11 window server using '0:0' as the value of thedisplay

2003-03-18 Thread Georges Roux
Hello everybody,

Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use J2sdk1.4.1_01.

I have a servlet which manipulate exif informations in jpg images.
it works well but when I try to run it on tomcat it fails (error 500)
I have the following error:
Can't connect to X11 window server using '0:0' as the value of the display
What can I do?

Georges

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Can't connect to X11 window server using '0:0' as the value of the display

2003-03-18 Thread Filip Hanik
can you try to set the DISPLAY env variable to localhost:0.0

export DISPLAY=localhost:0.0

Filip

 -Original Message-
 From: Georges Roux [mailto:[EMAIL PROTECTED]
 Sent: Tuesday, March 18, 2003 3:32 PM
 To: [EMAIL PROTECTED]
 Subject: Can't connect to X11 window server using '0:0' as 
 the value of
 the display
 
 
 Hello everybody,
 
 Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use 
 J2sdk1.4.1_01.
 
 I have a servlet which manipulate exif informations in jpg images.
 it works well but when I try to run it on tomcat it fails (error 500)
 
 I have the following error:
 Can't connect to X11 window server using '0:0' as the value 
 of the display
 
 What can I do?
 
 Georges
 
 
 -
 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: Can't connect to X11 window server using '0:0' as the value ofthe display

2003-03-18 Thread Theodore Chen
Try running the Tomcat VM with the -Djava.awt.headless=true system
property (set it in an environment variable named CATALINA_OPTS).

On Tue, 2003-03-18 at 16:31, Georges Roux wrote:
 Hello everybody,
 
 Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use J2sdk1.4.1_01.
 
 I have a servlet which manipulate exif informations in jpg images.
 it works well but when I try to run it on tomcat it fails (error 500)
 
 I have the following error:
 Can't connect to X11 window server using '0:0' as the value of the display
 
 What can I do?
 
 Georges
 
 
 -
 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: Can't connect to X11 window server using '0:0' as the value ofthe display

2003-03-18 Thread Zsolt Koppany
Hi,

does it need modifications in the application or it will work with every AWT
dependent application?

Zsolt

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]
Behalf Of Theodore Chen
Sent: Mittwoch, 19. März 2003 00:37
To: Tomcat Users List
Subject: Re: Can't connect to X11 window server using '0:0' as the value
ofthe display


Try running the Tomcat VM with the -Djava.awt.headless=true system
property (set it in an environment variable named CATALINA_OPTS).

On Tue, 2003-03-18 at 16:31, Georges Roux wrote:
 Hello everybody,

 Hi run Tomcat 4.1.18 Standalone on Linux debian(sid)and use J2sdk1.4.1_01.

 I have a servlet which manipulate exif informations in jpg images.
 it works well but when I try to run it on tomcat it fails (error 500)

 I have the following error:
 Can't connect to X11 window server using '0:0' as the value of the
display

 What can I do?

 Georges


 -
 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]