Create images using Java on headless Linux server

Hi,

I’m trying to create an image using Java (nothing really fancy), the agent works if run in the foreground on a Windows desktop (of course) but in the background it refuses to run. The code is to be called as part of a WebQueryOpen or WebQuerySave agent. Messages:

29-10-2006 14:27:06 HTTP JVM: java.lang.NoClassDefFoundError: sun/awt/X11GraphicsEnvironment

29-10-2006 14:27:06 HTTP JVM: at java.lang.Class.forName1(Native Method)

29-10-2006 14:27:06 HTTP JVM: at java.lang.Class.forName(Class.java:180)

29-10-2006 14:27:07 HTTP JVM: at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:91)

29-10-2006 14:27:07 HTTP JVM: at java.awt.Window.init(Window.java:268)

29-10-2006 14:27:07 HTTP JVM: at java.awt.Window.(Window.java:312)

29-10-2006 14:27:07 HTTP JVM: at java.awt.Frame.(Frame.java:431)

29-10-2006 14:27:07 HTTP JVM: at java.awt.Frame.(Frame.java:396)

29-10-2006 14:27:07 HTTP JVM: at JavaAgent.ProduceDiagram(JavaAgent.java:220)

29-10-2006 14:27:07 HTTP JVM: at JavaAgent.NotesMain(JavaAgent.java:137)

29-10-2006 14:27:07 HTTP JVM: at lotus.domino.AgentBase.runNotes(Unknown Source)

29-10-2006 14:27:07 HTTP JVM: at lotus.domino.NotesThread.run(Unknown Source)

So I traced ALL help there is to be found with Google, but I couldn’t solve it.

I use Xvfb as virtual framebuffer:

Xvfb -ac :0 -screen 0 1280x1024x16

DISPLAY in the shell environment is set to

DISPLAY=:0.0; export DISPLAY

Links that seem interesting:

So, you see, I’ve been there and done that, but nothing helps. Is there ANYONE with some hands-on experience on this subject??

Sjef

PS: It must be the same as

https://www-10.lotus.com/ldd/nd6forum.nsf/55c38d716d632d9b8525689b005ba1c0/0c3fe9110ca7fa27852570d0003d47f3

but there’s no real solution offered there.

PS2: I had it working on some other Linux system some time ago, but I think I did that by disabling the standard JVM and linking the JVM to the Linux JVM. Any comments on this?

Subject: Create images using Java on headless Linux server

I am by no means an expert on java but have recently looked at doing some domino tag integrated web sites and believe that the JRE is a little behind bleeding edge. You may need to adjust the calls in your code to the exact JRE in your Domino version.

Sorry I couldn’t be more help.

Shawn

Subject: Create images using Java on headless Linux server

Hi

From version 1.4 (Domino 7) of Java “Headless mode” mode i supported, which is what you need.

from the Sun site…

“Headless mode is a system configuration in which the display device, keyboard, or mouse is lacking”

brgds

Jesper Kiaer

http://www.jezzper.com