Solved

What IP Address is the Connector using?

Posted on 2004-08-03
17
324 Views
Last Modified: 2013-12-24
I have distributed configuration for JRUN/CFMX and Apache2.

Apache2 is running HostA.
JRUN/CFMX is running on HostB.

Both systems are multihomed.  For example:

HostA:
10.1.79.111
10.1.79.83  -- Apache2 listens to port 80 on this IP.
10.1.79.97

HostB:
10.1.79.125
10.1.79.115
10.1.79.110
10.1.79.119 -- JRun/CFMX listens to port 51000 on this IP

What IP address is the connector using to send a request to JRun/CFMX?
Think before you answer, because I believe this is a trick question?
How can I find out?

Thanks,
Troy
0
Comment
Question by:tdsimpso
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 8
  • 8
17 Comments
 
LVL 5

Expert Comment

by:Seth_Bienek
ID: 11705714
Hey Troy,

Check your httpd.conf file in your apache /conf folder.

Then search for 'mod_jrun20.so'

There should be a section in the configuration file labeled '# JRun Settings'.

Mine looks like this:
# JRun Settings
LoadModule jrun_module "C:/CFusionMX/runtime/lib/wsconfig/1/mod_jrun20.so"
<IfModule mod_jrun20.c>
    JRunConfig Verbose false
    JRunConfig Apialloc false
    JRunConfig Ssl false
    JRunConfig Ignoresuffixmap false
    JRunConfig Serverstore "C:/CFusionMX/runtime/lib/wsconfig/1/jrunserver.store"
    JRunConfig Bootstrap 127.0.0.1:51010
    #JRunConfig Errorurl <optionally redirect to this URL on errors>
    AddHandler jrun-handler .jsp .jws .cfm .cfml .cfc
</IfModule>

Yours is probably the same, but due to the flexibility of both apps, it could be manually set up to run on virtually any port.

Does this answer your question?

Seth
0
 

Author Comment

by:tdsimpso
ID: 11709188

Seth,

What can be manually set up to run on any port?
The Apache Connector (mod_jrun20.s0)?
OR
The JRun Server?

Troy
0
 
LVL 5

Expert Comment

by:Seth_Bienek
ID: 11709308
The Apache Connector gets loaded; it's a program accessed off the hard drive, not via tcp/ip.

It accesses JRun through the port specified in the settings, which can be whatever port JRUN's connector proxy service is set to run on (51010 by default).

You can stop JRun services on your server, then edit jrun.xml (located in C:\CFusionMX\runtime\servers\default\SERVER-INF\ on my development server).  Search for 'jrun.servlet.jrpp.JRunProxyService'.  Below that you'll find a setting an attribute named 'port' with a setting of '51010'.  Change that and theoretically you're good to go after a quick restart.

Just a quick disclaimer: I can't be responsible if any of the changes you make to your config end up hosing your server.  I'm trusting that you're wise enough not to do any of this on a server that is not indispensable. :)

Regards,

Seth
0
Forrester Webinar: xMatters Delivers 261% ROI

Guest speaker Dean Davison, Forrester Principal Consultant, explains how a Fortune 500 communication company using xMatters found these results: Achieved a 261% ROI, Experienced $753,280 in net present value benefits over 3 years and Reduced MTTR by 91% for tier 1 incidents.

 

Author Comment

by:tdsimpso
ID: 11710843
Seth,

The Apache Connector is a Client to the JRun/CFMX Server.  When the Apache Connector sends a request to the JRun/CFMX Server, what IP Address would the Apache Connector be using.

For example,  If I am at my desk and I start a browser and type www.microsoft.com in the Address Field.  The web server at www.microsoft.com recognizes my browser at the IP Address 10.1.190.140 althougth the web server at www.microsoft.com is listening to port 80 on IP Address 207.46.245.92.

So from that example, let's replace the browser with the JRun Apache Connector and the web server with JRun/CFMX Server.  With the configuration I listed above, what IP Address is the JRun Apache Connector using to make the request?

Troy
0
 
LVL 5

Expert Comment

by:Seth_Bienek
ID: 11710915
Hey Troy,

I can only give you a theoretical answer, since I don't have time to do a test.

My assumption would be that the JRun Apache Connector would make the request from either the primary IP adress of the Apache server (less likely) or the IP address that Apache is configured to listen on (more likely).

The way to find out for sure is to run netstat from the command line (netstat -p tcp 1) on the target (JRun) server and watch for incoming connections to port 51010.

Regards,

Seth
0
 

Author Comment

by:tdsimpso
ID: 11710962
Seth,

I've been watching the console for the JMC for messages and it appears that the JRun Apache Connector is using the Primary IP Address.  The primary IP Address is not allow to connect to the JRun/CFMX and is being refused.  So I think your hunch about it using the Primary IP Address might be correct.  I'll test is out some more before making a final conclusion.

Are you using a distributed configuration?  Do you have your web server running on one host and the JRun/CFMX running on another host?  
OR do you have both the web server and JRun/CFMX running on the same host?

Thanks,
Troy
0
 
LVL 5

Expert Comment

by:Seth_Bienek
ID: 11711001
Hey Troy,

Few configurations would benefit from having JRun and the Web server running on seperate boxes, because of the way network latency affects performance.

There are exceptions to every rule, though, so I'm sure you have your reasons. :)

We run Sun Java Web Server and ColdFusion MX together on all our boxes.

Regards,

Seth
0
 

Author Comment

by:tdsimpso
ID: 11717611
Seth,

I was noticing a little bit of latency.

We have a Sun Cluster.  The SysAdmin has configured various Resource Groups.  We have one resource Group which has Apache2 and the other resource group that has JRun/CFMX.  Ideally, both the Apache2 and JRun/CFMX Resource Groups will be running on the same system.  If for some reason the two resource groups get split up onto different system in the cluster, I want them to continuing working.

Could you give me some more insight about what you have learning?

Do your JRun/CFMX Applications use *.cfc/*.cfm and static content like *.html, *.jpg, *.gif?
How do deploy your CFMX application that have both dynamic and static content?

Thanks,
Troy
0
 
LVL 5

Expert Comment

by:Seth_Bienek
ID: 11718244
Hey Troy,

We deploy complete applications (including static support files like images and html pages) together on the same server, and our failover is handled on a server-wide basis, as opposed to a per-component basis which seems to be what you're describing.

I don't know enough about Sun Clusters to talk resource groups and configuration options, unfortunately.  You might try the Solaris forum with those questions:
http://www.experts-exchange.com/Operating_Systems/Solaris/

Take Care,

Seth
0
 

Author Comment

by:tdsimpso
ID: 11718332

Seth,

Are you using ColdFusion MX Enterprise Version?

Troy
0
 
LVL 5

Expert Comment

by:Seth_Bienek
ID: 11718399

Yes.
0
 

Author Comment

by:tdsimpso
ID: 11719574

Seth,

This is the reason why I asked how your applications where deployed.  Read the following paragraph.

"...
Separate static and dynamic content to improve performance. With ColdFusion MX for J2EE, all requests to the webserver to http://server/cfusion (context root) will go to JRun regardless of the extension (.cfm, .htm, .gif, .jpg). If images and static content exist in /cfusion, all static content will go to the JRun connector back to the webserver. This defeats the purpose of high-performance caching built into the web server. Therefore, we recommend that you place all static content in a folder outside of the /cfusion folder within the webserver root. For example, put all html in a /html folder and place all images underneath the web server root. In a site with a significant amount of static content you will see a significant improvement in throughput and pages/sec by separating the content; in some cases, the performance improves 200-300%.
..."

http://www.macromedia.com/devnet/mx/coldfusion/j2ee/articles/endtoend.html

I was curious with the directory structure you use to manage your code and dynamic content.  What guidelines do you use?

Troy
0
 
LVL 5

Expert Comment

by:Seth_Bienek
ID: 11720399

Hey Troy,

This is an interesting article that I haven't seen before, and it makes some good points.

I am not in charge of infrastructure at my institution, but most of our applications have been migrated from previous versions of coldfusion, so our directory structure has not changed, in that coldfusion (ala JRun) sits at the web root and all files (including static content) are served through the connector.

I am certain that if we were starting from scratch that we would definitely take into consideration our folder structure and how it would impact performance.  But the sheer volume of code we have would require a tremendous time and manpower investment to migrate to a new structure, and while efficiency improvements are always a good thing, we have not had any problems with our current setup, so it'd be hard to justify.

Seth
0
 

Author Comment

by:tdsimpso
ID: 11721339

Seth,

Thanks for your input.
We have the same issue with existing code as well.

I am setting up new servers and wanted to get input from others about installing ColdFusionMX as J2EE applications.  Now that ColdFusionMX Enterprise addition includes a full licensed copy of JRun 4.1, we can now deploy both ColdFusionMX with other J2EE Java Apps within JRun (or Tomcat).

I have punted on the distributed configuration.  I was able to make it work but It was going to be too much of a hassle.  So I just installed another copy of Apache2 dedicated to JRun/CFMX resource group.  I tired of having to do the administration and want to get back to developing out apps.

A resource group is a collection or resource that get carried around from one member of the cluster to another member of the cluster.  For example, our JRun/CFMX/Tomcat Resource Group has the following resources:

1. IPAddress dedicated to the resource group.
2. Disk Group with one or more disk sets.
3. JRun/CFMX software installed.
4. Tomcat installed.
5. etc.

If the system that is handling this resource group fails, the resource group gets transferred to an available system.  Or setup is mostly fail-over support.  We do not do any load balancing, although that is a possibility.  But in order provide load balancing, we would need to by two copies of everything like JRun/CFMX and we just don't have the utilization at this point to justify that.

FYI:
You might be familiar with this site but I'll throw it in anyway.
http://www.corfield.org/index.php?event=machii.main

Thanks,
Troy
0
 
LVL 5

Accepted Solution

by:
Seth_Bienek earned 500 total points
ID: 11977248
The original question was answered.  

I would like for the author to comment on the outcome before the questuion is resolved as 'abandoned'.

Thanks,

Seth
0
 

Author Comment

by:tdsimpso
ID: 12008707

Sorry about that Seth.
Thanks for you help.

Troy
0

Featured Post

Forrester Webinar: xMatters Delivers 261% ROI

Guest speaker Dean Davison, Forrester Principal Consultant, explains how a Fortune 500 communication company using xMatters found these results: Achieved a 261% ROI, Experienced $753,280 in net present value benefits over 3 years and Reduced MTTR by 91% for tier 1 incidents.

Question has a verified solution.

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

Introduction This article explores the design of a cache system that can improve the performance of a web site or web application.  The assumption is that the web site has many more “read” operations than “write” operations (this is commonly the ca…
Meet the world's only “Transparent Cloud™” from Superb Internet Corporation. Now, you can experience firsthand a cloud platform that consistently outperforms Amazon Web Services (AWS), IBM’s Softlayer, and Microsoft’s Azure when it comes to CPU and …
Come and listen to Percona CEO Peter Zaitsev discuss what’s new in Percona open source software, including Percona Server for MySQL (https://www.percona.com/software/mysql-database/percona-server) and MongoDB (https://www.percona.com/software/mongo-…
This is a high-level webinar that covers the history of enterprise open source database use. It addresses both the advantages companies see in using open source database technologies, as well as the fears and reservations they might have. In this…

688 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