Railo on Tomcat - multi-web using jar files

45 views
Skip to first unread message

Scott Conklin

unread,
Jul 8, 2010, 3:09:42 PM7/8/10
to Railo
I have followed almost all of the most common tutorials on installing
Railo on Tomcat using the jar file installation approach...from Jamie
Krug, Sean Corfield and others...

http://www.lynchconsulting.com.au/blog/index.cfm/2010/3/12/Railo-on-Tomcat-revisited--modproxy
http://jamiekrug.com/blog/index.cfm/2009/4/1/railo-jars-on-jboss-or-tomcat-tips-and-tricks
http://corfield.org/blog/post.cfm/Railo_on_Tomcat__multiweb

AND I always get the exact same errors. i can't figure out what i am
doing wrong.
(note: the one difference is that i install Tomcat6 from the Ubuntu
repository (om 10.04) instead of downloading the tar file as the
instructions in these blog say to do... does that matter? )

can someone help?

when going to http://127.0.0.1:8080/railo-context/admin/server.c...
i get:
-----------------------------

javax.servlet.ServletException
railo.runtime.config.ConfigWebImpl.<init>(ConfigWebImpl.java:58)

railo.runtime.config.ConfigWebFactory.newInstance(ConfigWebFactory.java:
208)

railo.runtime.engine.CFMLEngineImpl.loadJSPFactory(CFMLEngineImpl.java:
154)

railo.runtime.engine.CFMLEngineImpl.addServletConfig(CFMLEngineImpl.java:
123)

railo.loader.engine.CFMLEngineFactory.getInstance(CFMLEngineFactory.java:
73)

railo.loader.engine.CFMLEngineFactory.getInstance(CFMLEngineFactory.java:
111)
railo.loader.servlet.CFMLServlet.init(CFMLServlet.java:26)

org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:
102)

org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:
298)

org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:
852)
org.apache.coyote.http11.Http11Protocol
$Http11ConnectionHandler.process(Http11Protocol.java:588)
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:
489)
java.lang.Thread.run(Thread.java:619)
.....


the catalina.out log file shows this error:
-----------------------------------------------------------

==========================
SERVER CONTEXT
-----------------------------------------------------
- config:/opt/railo/railo-server/context
===========================
java.io.IOException: No such file or directory
at java.io.UnixFileSystem.createFileExclusively(Native Method)
at java.io.File.createNewFile(File.java:883)
at
railo.commons.io.res.type.file.FileResource.createFile(FileResource.java:
243)
at
railo.runtime.config.ConfigServerFactory.newInstance(ConfigServerFactory.java:
54)
at
railo.runtime.engine.CFMLEngineImpl.getConfigServerImpl(CFMLEngineImpl.java:
135)
at railo.runtime.engine.CFMLEngineImpl.<init>(CFMLEngineImpl.java:87)
at
railo.runtime.engine.CFMLEngineImpl.getInstance(CFMLEngineImpl.java:
102)
......

and this one:
----------------------------------

Wed Jul 07 00:05:25 CDT 2010-875 using JRE Date Library
java.io.FileNotFoundException: /opt/railo/railo-server/patches/
3.1.2.001.rc (No such file or directory)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
......

and a whole lot of these:
----------------------------------------

Jul 7, 2010 12:05:25 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 1440 ms
.....
java.lang.NullPointerException
at
railo.runtime.type.scope.ScopeContext.getClusterScope(ScopeContext.java:
101)
at railo.runtime.engine.Controler.run(Controler.java:80)
at railo.runtime.op.Caster.toPageException(Caster.java:2951)
at
railo.runtime.type.scope.ScopeContext.getClusterScope(ScopeContext.java:
119)
at railo.runtime.engine.Controler.run(Controler.java:80)

Sean Corfield

unread,
Jul 8, 2010, 3:36:37 PM7/8/10
to ra...@googlegroups.com
On Thu, Jul 8, 2010 at 12:09 PM, Scott Conklin <scottr...@gmail.com> wrote:
> (note: the one difference is that i install Tomcat6 from the Ubuntu
> repository (om 10.04) instead of downloading the tar file as the
> instructions in these blog say to do... does that matter? )

I believe this might be a security issue. I seem to remember someone
reporting that they ran into problems with the standard UBuntu Tomcat6
setup...
--
Sean A Corfield -- (904) 302-SEAN
Railo Technologies, Inc. -- http://getrailo.com/
An Architect's View -- http://corfield.org/

"If you're not annoying somebody, you're not really alive."
-- Margaret Atwood

Todd Rafferty

unread,
Jul 8, 2010, 3:39:15 PM7/8/10
to ra...@googlegroups.com
http://www.railo.ch/blog/index.cfm/2009/8/26/Ubuntu-704-Tomcat-6-and-Railo
--
~Todd Rafferty ** Volunteer Railo Open Source Community Manager ** http://getrailo.org/

Randy Merrill

unread,
Jul 8, 2010, 3:41:00 PM7/8/10
to ra...@googlegroups.com
If it is a security issue edit the /etc/init.d/tomcat6 file and find the TOMCAT6_SECURITY and change it:

TOMCAT6_SECURITY=no

When you install Tomcat6 fresh in Ubuntu 10.04 it actually defaults to "no" which is nice.
--
Randy Merrill

Scott Conklin

unread,
Jul 8, 2010, 4:01:58 PM7/8/10
to ra...@googlegroups.com

this is already set to no

Scott Conklin

unread,
Jul 8, 2010, 4:02:59 PM7/8/10
to ra...@googlegroups.com

yea, i saw this post and checked that out... i am on ubuntu 10.04 and it is by default already set to "no" 

Scott Conklin

unread,
Jul 8, 2010, 4:05:32 PM7/8/10
to ra...@googlegroups.com
yea, 

in init.d, this is already set to no... checked that a long time ago.
TOMCAT_SECURITY=no 

are you saying i should uninstall and try to do the installation using the latest zip file?  

Jordan Michaels

unread,
Jul 8, 2010, 5:28:18 PM7/8/10
to ra...@googlegroups.com
The railo installers install Railo as a Tomcat common class:

http://railo.viviotech.net/

It's exactly what you're trying to do.

Only pre-requisite is Apache if you want to use Apache as the front-end
web server.

-Jordan

--
Warm regards,
Jordan Michaels
Vivio Technologies
http://www.viviotech.net/
Open BlueDragon Steering Committee
Railo Community Distributions

Ryan LeTulle

unread,
Jul 8, 2010, 5:41:41 PM7/8/10
to ra...@googlegroups.com
I would remove Tomcat first though if you already installed from the repository.  That way you would have standard installer paths.

</ryan>

Jamie Krug

unread,
Jul 16, 2010, 12:07:53 PM7/16/10
to Railo
Scott,

Do you have Sun Java 6 JDK installed, and not Open JDK? Or, if you
have both, do you have Tomcat set to use Sun?

Also, keep in mind that Tomcat is run as the tomcat6 user on Ubuntu
(when installed from the repos/apt-get), and that Railo does need
write permissions for certain things. In particular, the Railo Server
configuration directory is created, by default, in the same folder as
the Railo jars, so be sure that directory has write permissions for
the tomcat6 user. Railo will also attempt to generate a WEB-INF
directory under each application Web root, so any Web roots that you'd
like to run CFML and have a Railo context must have write permission
for tomcat6 on the Web root folder (or, you could manually create WEB-
INF if you'd like and make tomcat6 the owner, if you prefer).

In any case, I'd suggest starting fresh, if needed. I recently
configured an Ubuntu 10.04 server with Railo, Tomcat, Apache, MySQL,
and it went great! It's very simple, and I like being able to use
everything from the Ubuntu repos. In fact, this one liner (okay, two
if you don't have the partner repo enabled) gets you 90% there ;-)

# add partner repo, if needed, so we can install sun-java6-jdk
sudo add-apt-repository "deb http://archive.canonical.com/ lucid
partner" && sudo apt-get update

# install packages
sudo apt-get install apache2 mysql-server sun-java6-jdk tomcat6
libtcnative-1

You then need only the Railo jars and a few Tomcat configuration
tweaks to get Railo running on Tomcat via common class loader. AJP
proxy from Apache to Tomcat is also very simple.

I have a production-worthy setup for Ubuntu 10.04 neatly documented
here:
http://docs.google.com/View?id=dchcmx7_70dqhqgsdw

I haven't gotten around to blogging about any of this, but I'll
elaborate on my blog soon. Hope that helps!

Cheers,
Jamie

On Jul 8, 3:09 pm, Scott Conklin <scottrconk...@gmail.com> wrote:
> I have followed almost all of the most common tutorials on installing
> Railo on Tomcat using the jar file installation approach...from Jamie
> Krug, Sean Corfield and others...
>
> http://www.lynchconsulting.com.au/blog/index.cfm/2010/3/12/Railo-on-T...http://jamiekrug.com/blog/index.cfm/2009/4/1/railo-jars-on-jboss-or-t...http://corfield.org/blog/post.cfm/Railo_on_Tomcat__multiweb
>
> AND I always get the exact same errors. i can't figure out what i am
> doing wrong.
> (note: the one difference is that i install Tomcat6 from the Ubuntu
> repository (om 10.04) instead of downloading the tar file as the
> instructions in these blog say to do... does that matter? )
>
> can someone help?
>
> when going tohttp://127.0.0.1:8080/railo-context/admin/server.c...
Reply all
Reply to author
Forward
0 new messages