Solved

Resin - IIS and multiple JVMs

Posted on 2009-05-10
6
770 Views
Last Modified: 2012-05-06
Hello Experts,

I recently installed Resin 3.1.9 on Windows Server 2008 to serve Coldfusion files with Railo 3.1.0.12. This is my first experience with anything Java, and my question is how do I have each Virtual Host use a different JVM? Right now, all of my sites are using one instance, and when I change anything in resin.conf, the server has to reload. I've read through the documentation on the caucho website, but it's sorely lacking when it comes to how to implement this.

My current folder structure is similar to the following for my two sites:

c:\websites\site1\wwwroot
c:\websites\site2\wwwroot

I've placed the isapi_srun.dll in c:\inetpub\scripts, which is also mapped as the virtual directory "scripts" for each of the sites.

Both of my sites are working correctly with Resin, but I just want them each to run their own instance. How do I go about doing this? Do I need to manually create a scripts directory inside both of the sites' wwwroot with a copy of the isapi_srun.dll and include a resin.ini file there? Also, where do the individual site1.conf and site2.conf files go?

Sorry if this isn't very clear. Again, I'm really new to Resin and Java. Please ask me if you need any further explanation

0
Comment
Question by:vonRogue
  • 3
  • 2
6 Comments
 
LVL 92

Expert Comment

by:objects
ID: 24351289
you just need to startup multiple instances of resin with each one using a different port and webapps.
Its unrelated to IIS really.
0
 
LVL 1

Author Comment

by:vonRogue
ID: 24351348
Thanks for the quick reply, objects. I guess my next question is how resin will know which instance/port to use for each site? Where do I save my site1.conf and site2.conf files, and the resin.ini files?

Right now, I don't have a resin.ini file and I'm just using the default resin.conf file stored in c:\resin\conf\resin.conf. This file contains Host sections for each of my sites.

Caucho's website leads me to believe that I need a separate resin.ini file saved in the Scripts directory for each site, in addition to a ".conf" file for each. Currently, this scripts directory is just a Virtual Directory that contains the isapi_srun.dll file. If I create a resin.ini file there, won't it be the same one for each site that uses the virtual directory? Or am I just overthinking this?
resin.conf
 
snip...
 
<watchdog-port>6600</watchdog-port>
 
snip...
 
<server id="" address="127.0.0.1" port="6800"/>
 
snip...
 
<host id="site1.com" root-directory="C:/websites/site1.com">
	<host-alias>www.site1.com</host-alias>
	<web-app id="/" root-directory="wwwroot"/> 
</host>
 
<host id="site2.com" root-directory="C:/websites/site2.com">
	<host-alias>www.site2.com</host-alias>
	<web-app id="/" root-directory="wwwroot"/> 
</host>

Open in new window

0
 
LVL 92

Expert Comment

by:objects
ID: 24351368
so are you running httpd?

0
 
LVL 1

Author Comment

by:vonRogue
ID: 24351386
Yes, I'm running httpd. IIS is the "front end", but it passes off requests to resin when needed (for .cfm and .jsp files in my case.) I basically followed the installation instructions from here:

http://www.caucho.com/resin-3.1/doc/install-iis.xtp

I setup Resin to run as a service using those instructions as well. Again, everything is working correctly, but is only using 1 JVM.

Here's what I would like to accomplish...
http://www.caucho.com/resin-3.1/doc/install-iis.xtp#Virtual%20Sites%20with%20different%20JVM%27s

I'm just not sure where to store the resin.ini files and the site1.conf and site2.conf files.
0
 
LVL 92

Accepted Solution

by:
objects earned 500 total points
ID: 24351419
httpd has an option you can pass it to tell it the resin home to use

http://www.caucho.com/resin-3.0/install/cse-iis.xtp#Command-line-arguments

you want to startup mutliple instances of httpd pointing at different directories

0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
IIS URL Rewrite/Redirect Rule Help 4 32
Java Restore security prompts not working 10 119
junit as external jar or library 7 37
Java Inheritance super keyword use 8 32
Introduction This article is the first of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article explains our test automation goals. Then rationale is given for the tools we use to a…
ADCs have gained traction within the last decade, largely due to increased demand for legacy load balancing appliances to handle more advanced application delivery requirements and improve application performance.
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
Viewers will learn about the regular for loop in Java and how to use it. Definition: Break the for loop down into 3 parts: Syntax when using for loops: Example using a for loop:

740 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question