Unix Technical Forum

Tomcat only runs webMathematica if run as root.

This is a discussion on Tomcat only runs webMathematica if run as root. within the comp.unix.solaris forums, part of the Solaris Operating System category; --> Hi I sent this to a Mathematica newsgroup, but are trying a couple more just in case someone here ...


Go Back   Unix Technical Forum > Unix Operating Systems > Solaris Operating System > comp.unix.solaris

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 01-09-2008, 06:58 AM
Dave
 
Posts: n/a
Default Tomcat only runs webMathematica if run as root.

Hi

I sent this to a Mathematica newsgroup, but are trying a couple more
just in case someone here might know. The Mathematica one is moderated
(what a pain), so I'm sending this separately to avoid delays due to the
moderation.

I've been trying to install on a Sun Ultra 60 the program webMathematica:

http://www.wolfram.com/products/webm...ica/index.html

which is free or cheap web-based front end to an expensive bit of
commercial software. An example of the webMathematica is here

http://integrals.wolfram.com/
(useful if you are doing Calculus). Your browser interfaces with a
Tomcat server, which calls Mathematica to do the computations and
returns the results to the browser.

I've installed Mathematica 5.2, Tomcat 5.5.12 and webMathematica 2.1 on
the Sun.

Starting up Tomcat, the examples from Tomcat work fine at port 8080. But
none of the Mathematica ones do unless I run Tomcat as root. Which
launches Mathematica as root too - not a good idea, given that program
can read and write files.

Here's the Tomcat log file, which shows the error message:

"A front end is not available; export of PNM requires a front end."






Nov 23, 2005 3:37:19 AM org.apache.catalina.core.ApplicationContext log
INFO: MSP: Wed Nov 23 03:37:19 GMT 2005 Memory alloc: 9814016 used: 7515080
Nov 23, 2005 3:37:21 AM org.apache.catalina.core.ApplicationContext log
INFO: MSP: General KernelData0::
Export::nofe: A front end is not available; export of PNM requires a
front end.
Nov 23, 2005 3:37:21 AM org.apache.catalina.core.ApplicationContext log
INFO: MSP: IOException thrown java.io.FileNotFoundException:
/usr/local/apache2/apache-tomcat-5.5.12/work/Catalina/localhost/webMathematica/MSPStore993157332_0
(No such file or directory)


The webMathematica program seems a bit dumb in that ideally it needs
XVnc running, otherwise windows pop up on the console whenever someone
runs the application!

http://documents.wolfram.com/webmath...index_2_4.html

I can't get XVnc to work for me ( the client always reports the password
is wrong), so I have logged in as root and run

# xhost +

which should allow anyone to connect. Windows will pop up on the console
I believe, but I'm not too bothered by that. Perhaps I should log in the
console as user "nobody" then try starting as nobody. (It's in my
garage, so might do tomorrow, but not now).

Any other ideas? I realise this is very Mathematica specific, but I it
is worth a try on one of these two newsgroups.

--
Dave K

http://www.southminster-branch-line.org.uk/

Please note my email address changes periodically to avoid spam.
It is always of the form: month-year@domain. Hitting reply will work
for a couple of months only. Later set it manually. The month is
always written in 3 letters (e.g. Jan, not January etc)

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 01-09-2008, 06:58 AM
Dave
 
Posts: n/a
Default Re: Tomcat only runs webMathematica if run as root.

Dave wrote:

> Perhaps I should log in the
> console as user "nobody" then try starting as nobody. (It's in my
> garage, so might do tomorrow, but not now).
>
> Any other ideas? I realise this is very Mathematica specific, but I it
> is worth a try on one of these two newsgroups.


This has been solved - I think!!

I tried logging onto the console with CDE as user nobody and could not
connect to the X server. I created a new user 'tomcat' who could log in
under CDE ok. (Not sure why nobody can't).

When I started Tomcat as the user 'tomcat' webMathematica runs OK.

Seems something was up that prevented 'nobody' connecting to an X server.



--
Dave K

http://www.southminster-branch-line.org.uk/

Please note my email address changes periodically to avoid spam.
It is always of the form: month-year@domain. Hitting reply will work
for a couple of months only. Later set it manually. The month is
always written in 3 letters (e.g. Jan, not January etc)

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 10:49 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com