|
From: Donal M. <dom...@ya...> - 2007-02-22 02:02:05
|
Hi,=0A=0AThanks for the response Leif. I stumbled across the #include optio= n shortly after I sent the message below.=0A=0ARegarding the way the 4 proc= esses are set up, all the .conf files *are* in the same directory. I notice= d that the .sh script (on Solaris) has the .conf file path and APP_NAME wit= hin the script itself, so I've modified this scripts to accept these as par= ameters.=0A=0AIn the .conf files for the processes themselves (rather than = in the common .conf file that they #include), I've specified a different wr= apper log file for each process. If I also add a unique wrapper.java.pidfil= e property for each process, then are there any other changes I need to mak= e in order to safely execute all 4 processes simultaneously?=0A=0ABTW, I ex= pect you already know this, but the "su" command in the script does not wor= k on Solaris as it does not accept a "-m" option. I'll look into a workarou= nd for this tomorrow and can let you know what I come up with if you're int= erested?=0A=0AThanks for providing such a great tool!=0A- Donal=0A=0A----- = Original Message ----=0AFrom: Leif Mortenson <le...@ta...>=0ATo= : wra...@li...=0ASent: Wednesday, 21 February, 2007 8= :22:08 PM=0ASubject: Re: [Wrapper-user] configuring mulitple processes=0A= =0ADonal,=0A Each of the 4 java processes are independent applications. = Are they =0Aall installed=0Ain the same directory as well? How are things= set up?=0A=0A If they are different installs, then you could generate y= our =0Awrapper.conf files=0Aat build time my making the main class name a t= oken that gets replaced.=0A=0A If all 4 applications will be using the s= ame install directory or =0Athe above does not=0Awork, another option is to= move everything other than the main class, =0Aservice name,=0Aand log file= into a file called conf/wrapper-common.conf=0A Then modify your wrapper= .conf to look like this:=0A---=0A#include ../conf/wrapper-common.conf=0Awra= pper.app.parameter.1=3Dfoo.bar.MyProcessMainClass=0Awrapper.logfile=3D../lo= gs/wrapper-app1.log=0Awrapper.console.title=3DApp1=0Awrapper.ntservice.name= =3DApp1=0Awrapper.ntservice.displayname=3DApp1=0Awrapper.ntservice.descript= ion=3DApp1Desc=0A---=0ASee this page for details.=0Ahttp://wrapper.tanukiso= ftware.org/doc/english/props-cascading.html=0A=0ANote that if all 4 apps ar= e in the same directory, you are also going to =0Aneed to make sure=0Athey = all have their own wrapper.log file. Any use of pid, state, or =0Alock fil= es will also need=0Ato avoid conflicts.=0A=0AYou could also keep a single w= rapper.conf and then set the above =0Aproperties from=0Athe wrapper command= line. If you are using a bat or sh file, this would =0Abe feasible.=0Ahtt= p://wrapper.tanukisoftware.org/doc/english/props-command-line.html=0A=0AUsi= ng environment variables and then dereferencing them in the =0Awrapper.conf= is another=0Aoption.=0Ahttp://wrapper.tanukisoftware.org/doc/english/props= -envvars.html=0A=0AIn general, the Wrapper is not designed to have more tha= n one instance =0Arunning out=0Aof the same directory at the same time. It= is possible, but you will =0Ahave some work=0Ato make sure there are no fi= le conflicts etc. The sh script on linux =0Awill work if you set=0Ause set= unique APP_NAME and WRAPPER_CONF values in the sh script.=0A=0ACheers,=0AL= eif=0A=0ADonal Murtagh wrote:=0A> Hi,=0A>=0A> I have 4 java processes that = I wish to wrap. Each one has a different main class, but apart from that th= ey are identical (in terms of JVM parameters, application parameters, etc.)= .=0A>=0A> Therefore, I currently have 4 wrapper.conf files - one for each = process - which are identical apart from=0A>=0A> wrapper.app.parameter.1=3D= foo.bar.MyProcessMainClass=0A>=0A> Is there any way I can avoid the duplica= ting the JVM parameters, application parameters for each process?=0A>=0A> T= hanks,=0A> TD=0A> =0A=0A=0A----------------------------------------------= ---------------------------=0ATake Surveys. Earn Cash. Influence the Future= of IT=0AJoin SourceForge.net's Techsay panel and you'll get the chance to = share your=0Aopinions on IT & business topics through brief surveys-and ear= n cash=0Ahttp://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge= &CID=3DDEVDEV=0A_______________________________________________=0AWrapper-u= ser mailing lis...@li...=0Ahttps://lists.sourc= eforge.net/lists/listinfo/wrapper-user=0A=0A=0A=0A=0A=0A=09=09=0A__________= _________________________________________________ =0ANow you can scan email= s quickly with a reading pane. Get the new Yahoo! Mail. http://uk.docs.yaho= o.com/nowyoucan.html |