Caucho Forums  

This forum is permanently closed because of spam. For free community support, please visit Google Groups:

Go Back   Caucho Forums > Resin

Thread Tools Display Modes
Prev Previous Post   Next Post Next
Old 12-16-2011, 06:54 PM
theBlueSage theBlueSage is offline
Join Date: Apr 2011
Posts: 33
Default adding different http ports to does not work

according to your documentation here :

I should be able to change the http port for each of my servers defined in, and use server-multi to set them up. Well, using the config below this is failing. snip ---------------
setuid_user : orion
setuid_group : orion

app_tier :

http : 8080
app-0.http : 10880
app-1.http : 10881

--------------- end snip ---------------

and here is the relevant part from the resin.xml file

---------- resin.xml snip -------------------------
<cluster id="app_tier">

<!-- sets the content root for the cluster, relative to resin.root -->

<!-- define the servers in the cluster -->
<server-multi id-prefix="app-" address-list="${app_tier}" port="6800" >
<http port="${rvar('http')}" />
<http port="${rvar('https')}">
<jsse-ssl self-signed-certificate-name="resin@localhost"/>

I start the first server using this (yes I contrarily started app-1 before app-0, and yes I tried it the other way too with app-0 first and it made no difference) :

java -jar /home/orion/clusterResins/latest_resin/lib/resin.jar -resin-home /home/orion/resinB -log-directory /home/orion/resinB/log/ -root-directory /home/orion/resinB -server app-1 start

This part went well and I see my' hello world' at . I then started the second serer with the following command :

java -jar /home/orion/clusterResins/latest_resin/lib/resin.jar -resin-home /home/orion/resin -log-directory /home/orion/resin/log/ -root-directory /home/orion/resin -server app-0 start

and although the start command rendered :

Resin/4.0.24 started -server 'app-0' for watchdog at

the watchdog.log showed this :
[2011/12/16 14:29:13.402] {watchdog-app-1} WatchdogChild[app-1] starting
[2011/12/16 14:29:13.420] {watchdog-app-1} Watchdog starting Resin[app-1]
[2011/12/16 14:29:45.718] {watchdog-app-0} WatchdogChild[app-0] starting
[2011/12/16 14:29:45.731] {watchdog-app-0} Watchdog starting Resin[app-0]
[2011/12/16 14:29:50.863] {watchdog-app-0} Socket bind failed for null:10881 while running as orion. Check for other processes listening to the port and check for permissions (root on unix).
at com.caucho.vfs.JniServerSocketImpl.<init>(JniServe
at com.caucho.vfs.JniServerSocketImpl.create(JniServe
at sun.reflect.NativeMethodAccessorImpl.invoke0(Nativ e Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Native
at sun.reflect.DelegatingMethodAccessorImpl.invoke(De
at java.lang.reflect.Method.invoke(
at com.caucho.vfs.QJniServerSocket.createJNI(QJniServ
at ndForWatchdog(
at com.caucho.boot.WatchdogChildProcess.createProcess (
at com.caucho.env.thread.ResinThread.runTasks(ResinTh
at java:130)
[2011/12/16 14:29:50.866] {watchdog-app-0} com.caucho.config.ConfigException: <user-name> requires compiled JNI.
at com.caucho.boot.WatchdogChildProcess.createProcess (
at com.caucho.env.thread.ResinThread.runTasks(ResinTh
at java:130)

As you can see, the watchdog tried to start the app-0 server at the http port of 10881, which is the port for app-1. When I start app-0 first, the same clash happens but on port 10880. In other words the first startup does pick up the correct http port, but the second one does not.

Please let me know what I am doing wrong, I'd love to get this going before the end of next week ...

Thanks in advance for your time and support
Reply With Quote

dynamic http port, resin-pro 4.0.24, server-multi

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT. The time now is 04:15 PM.

Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.