Re: Host manager / manager access.
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 Turbo, On 2/4/19 10:13, TurboChargedDad . wrote: > Java 8 Tomcat 8.5.20 Thanks. > I am trying to understand how to get the host manager / manager > access working from somewhere other than the localhost. I have > tried all the various methods out there on the web to no avail. I > keep getting the 403 access denied message. I am at a total loss > at this point.. > > Thanks in advance. > > I hope this is readable as it's hard to tell what it's going to > look like in this gmail editor. > > I have tried creating the following files. > > $CATALINA_BASE/conf/server.xml > protocol="HTTP/1.1" redirectPort="8080" setIPVHosts="true" /> > You shouldn't need any special configuration in conf/server.xml for this, but it's good to see your connector port. > $CATALINA_BASE/conf/Catalina/localhost/magager.xml > > encoding='utf-8'?> > > > > > > > > docBase="${catalina.home}/webapps/manager"> className="org.apache.catalina.valves.RemoteAddrValve" allow="^.*$" > /> That looks okay to me, except that the filename is (almost certainly) wrong. Transcribing typo? If you are going to "allow all" in the RemoveAddrValve, then you may as well just remove (or comment-out) the Valve altogether. > $CATALINA_BASE/webapps/host-manager/WEB-INF/context.xml > > encoding='utf-8'?> > > > > > > allow=".*" /> > > > Same thing, here: just remove RemoteAddrValve if you want to "allow all" . > $CATALINA_BASE/webapps/manager/WEB-INF/context.xml > > encoding='utf-8'?> > > > > > > allow=".*" /> > > > Definitely undo your edits to manager/WEB-INF/context.xml if you have a conf/Catalina/localhost/manager.xml -- the latter file will override the former one. > $CATALINA_BASE/conf/ tomcat-users.xml > > > http://tomcat.apache.org/xml; > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance; > xsi:schemaLocation="http://tomcat.apache.org/xml tomcat-users.xsd" > version="1.0"> > > > roles="manager-script"/> password="password3" roles="manager-jmx"/> password="password4" roles="manager-status"/> username="test5" password=" password5 " roles="admin-gui"/> username="test6" password="password6" roles="admin-script"/> > > > So, are you challenged for a username/password when you try to access the manager? I don't see any configured for your manager (etc.) applications. I think you want to add something like this to conf/Catalina/localhost/manager.xml (and friends): - -chris -BEGIN PGP SIGNATURE- Comment: Using GnuPG with Thunderbird - https://www.enigmail.net/ iQIyBAEBCAAdFiEEMmKgYcQvxMe7tcJcHPApP6U8pFgFAlxYsyUACgkQHPApP6U8 pFifew/40bD3kduI6EeZaWSEAiInz/H3K14pBbSxy+dQ38FiNyJI1/DJuhNFUwlB OYKkPujVuwzcOtoXgHwAniPAFHITB+9SGfxYmif7/FpF3LbwWl4quQZtjGjqhF4f cu5JV9r44lwW4qD5HeurzDAuep2VlZEFzT+vV961noRXXGsnTmjuS726j9imqYRR p9CFDxLnVWUNxHwYC7bUc2591aO+0dCdnhEM5xWhsPJ34Wa+0uvLg/FwSscXhEP5 C3al/DAkl8GhS5b5q4aoWi2W2uBzlWwxDRlw/klN3M1Y0FvRoJex8WJlo/PeCYZR A27kxSiFu5i7G2cr0rayUt/ejJlTJ73vfGbzeH2kPFa60X7+FtLREQLRdVN9tcVQ PPP4kGvcXA4kbvaRn/a8lM3bPtbgRI/IqHkVRj3h8y0cmB/V47exfezwuWHhIdiQ ZdpdMYgM4dpSf8GC//FxCDxwiV5Q7VDUychZdYEnLOLvX4ArpsLQTUqI5hBlkKHZ wwqj9IHUrWq9d0WRDWQoMFn96o0bRIofjbeQBF2eeu7t14UUoR1CMbX/iCUiP4Gg KPjtT66Jf6D4WPOnmoVHZt6c33ipKruVrBJfaHXhlxJPuRm+tHFbopdntC7uF38t tB4AMa9QJp72DE8dqGlbQyWequcFJUK/oDhV6W+FC8u8kJzgvg== =ETQ/ -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Host-manager and jndi data-sources question
chris derham wrote: All, So we have a single war file that we wish to be able to run for different clients, each isolated from each other. I noticed that with the host-manager app we should be able to setup a different host within the same tomcat instance. 1) is this the best way to solve our aim? Would we be better off with multiple tomcat instances - e.g. single catalina_home and multiple catalina_base? I think these would be better insulated, but there would be more admin overhead If you have multiple Host within a single Tomcat instance, they can share the same IP address and port, and differ only by their DNS hostname. But if you bring down/up Tomcat, you bring down/up all Host at the same time. If you run different Tomcat instances, each with one Host, you can bring down/up one instance/Host independently of the others. But each instance will need its own port, or IP address. This may be a good reason to use a front-end httpd, to hide these different ports from the users. In both cases, you will need a distinct appBase for each Host, and will need to load your war independently to each of them. 2) the app needs a database connection. How can we setup a jndi connection for each host? Each client would want a jndi connection using a different db account. What is the recommended way to do this when using the host-manager Someone else would need to answer that. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Host Manager.
The way I've implemented this it does all the normal work of adding the host to the container before trying to persist the file. Now there are a lot of things that can go wrong when trying to write to a filesystem. Maybe the user doesn't have permission to update the file. Maybe the existing file is unparseable for some reason (that one shouldn't really happen). Maybe the security manager stops the user updating the file. etc. etc. So my question is what should be seen in the host manager in everyone's opinion if the file system changes aren't persisted? Some possibilities below: Should it still show success as its been added to the container.? Should the addition to the container be undone (rollback)? Should it show an error? Or two messages 1 for the container 1 for the file? If error messages are shown how much information should be shown to the client, a full stack trace, an informative message such as update server.xml:FAIL blocked by security manager Please feel free to pitch in anyone. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Host Manager.
Wesley Acheson wrote: The way I've implemented this it does all the normal work of adding the host to the container before trying to persist the file. Now there are a lot of things that can go wrong when trying to write to a filesystem. Maybe the user doesn't have permission to update the file. Maybe the existing file is unparseable for some reason (that one shouldn't really happen). Maybe the security manager stops the user updating the file. etc. etc. So my question is what should be seen in the host manager in everyone's opinion if the file system changes aren't persisted? Some possibilities below: Should it still show success as its been added to the container.? Should the addition to the container be undone (rollback)? Should it show an error? Or two messages 1 for the container 1 for the file? If error messages are shown how much information should be shown to the client, a full stack trace, an informative message such as update server.xml:FAIL blocked by security manager Please feel free to pitch in anyone. Although I am not really competent, I will use your last phrase above as an excuse and pitch in. I understand what you are saying about what can go wrong, and I understand that conditions after a change may not be the same as when the change was started. But I find it particularly frustrating when I do a lot of work in an application, and when I want to save my work at the end, it comes and tells me that it cannot be saved, and does not provide any alternative (*). I would imagine that some of these reasons for not being able to write server.xml, can be tested ahead of time, and a warning message provided to the user as to that fact, before they start making changes. Also, maybe in case server.xml cannot be directly overwritten, an alternative path could be requested from the user ? (and/or the file could be written first as server.xml.new, and only renamed in a second step, which could fail). (*) the popup dialog with a single button Press OK to reboot comes to mind. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Host Manager.
Okay thats good feedback a lot more work though. On Fri, Sep 17, 2010 at 12:01 AM, André Warnier a...@ice-sa.com wrote: Wesley Acheson wrote: The way I've implemented this it does all the normal work of adding the host to the container before trying to persist the file. Now there are a lot of things that can go wrong when trying to write to a filesystem. Maybe the user doesn't have permission to update the file. Maybe the existing file is unparseable for some reason (that one shouldn't really happen). Maybe the security manager stops the user updating the file. etc. etc. So my question is what should be seen in the host manager in everyone's opinion if the file system changes aren't persisted? Some possibilities below: Should it still show success as its been added to the container.? Should the addition to the container be undone (rollback)? Should it show an error? Or two messages 1 for the container 1 for the file? If error messages are shown how much information should be shown to the client, a full stack trace, an informative message such as update server.xml:FAIL blocked by security manager Please feel free to pitch in anyone. Although I am not really competent, I will use your last phrase above as an excuse and pitch in. I understand what you are saying about what can go wrong, and I understand that conditions after a change may not be the same as when the change was started. But I find it particularly frustrating when I do a lot of work in an application, and when I want to save my work at the end, it comes and tells me that it cannot be saved, and does not provide any alternative (*). I would imagine that some of these reasons for not being able to write server.xml, can be tested ahead of time, and a warning message provided to the user as to that fact, before they start making changes. Also, maybe in case server.xml cannot be directly overwritten, an alternative path could be requested from the user ? (and/or the file could be written first as server.xml.new, and only renamed in a second step, which could fail). (*) the popup dialog with a single button Press OK to reboot comes to mind. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Host Manager.
Okay I'm most of the way to a solution but I wouldn't mind if someone would take a look at a new WIP class and tell me what needs cleaning. Its not quite functional. Anyone interested? On Fri, Sep 3, 2010 at 4:44 AM, Wesley Acheson wesley.ache...@gmail.com wrote: Looked at that before not really convinced reworking that is easier than adding in an xml line or two via an xml writer. Willing to be convinced though. Wes On 9/3/10, Pid p...@pidster.com wrote: On 02/09/2010 21:06, Caldarale, Charles R wrote: From: Wesley Acheson [mailto:wesley.ache...@gmail.com] Subject: Host Manager. Is there is no documentation for the host-manager? Very little that I've found. You can learn a bit about it by looking at its WEB-INF/web.xml file. If I remember correctly from this list it doesn't persist its settings is that correct? Correct. How many people would be interested in it persisting its settings, by editing the appropriate files. I would be interested. Note that there's only one file to edit: conf/server.xml. Is that in theory possible? It's all software... to add the folder structure and the appropiate context.xml files. That's not necessary - the conf/Catalina/[host]/... files are already created automatically as webapps are deployed under the new Host. Only conf/server.xml needs to be updated. Would it interfere too badly with tomcat while it was running? No, Tomcat only reads server.xml during startup. Whatever update mechanism is used must insure that the file is never in an unparsable state (e.g., don't update in place, instead create a new file and then rename it). May I gently steer you in the direction of the JMX API and the Catalina:type=Server.Operations.storeConfig() command? Not sure it works very well at the moment, but if it did... p - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org -- Sent from my mobile device - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Host Manager.
could you configure public static void writeXml( Node n, OutputStream os ) throws TransformerException of org.apache.tomcat.util.DomUtil to trap TransformerFactoryConfigurationError http://cupi2.uniandes.edu.co/site/images/recursos/javadoc/j2se/1.5.0/docs/api/javax/xml/transform/TransformerFactory.html#newTransformer%28javax.xml.transform.Source%29 it seems at minumum one of these conditions to be satisifed to properly newInstance the TransformerFactory ? Use the javax.xml.transform.TransformerFactory system property. Use the properties file lib/jaxp.properties in the JRE directory. This configuration file is in standard java.util.Properties format and contains the fully qualified name of the implementation class with the key being the system property defined above. The jaxp.properties file is read only once by the JAXP implementation and it's values are then cached for future use. If the file does not exist when the first attempt is made to read from it, no further attempts are made to check for its existence. It is not possible to change the value of any property in jaxp.properties after it has been read for the first time. Use the Services API (as detailed in the JAR specification), if available, to determine the classname. The Services API will look for a classname in the file META-INF/services/javax.xml.transform.TransformerFactory in jars available to the runtime. Platform default TransformerFactory instance. ? Martin Gainty __ Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht dient lediglich dem Austausch von Informationen und entfaltet keine rechtliche Bindungswirkung. Aufgrund der leichten Manipulierbarkeit von E-Mails koennen wir keine Haftung fuer den Inhalt uebernehmen. Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le destinataire prévu, nous te demandons avec bonté que pour satisfaire informez l'expéditeur. N'importe quelle diffusion non autorisée ou la copie de ceci est interdite. Ce message sert à l'information seulement et n'aura pas n'importe quel effet légalement obligatoire. Étant donné que les email peuvent facilement être sujets à la manipulation, nous ne pouvons accepter aucune responsabilité pour le contenu fourni. Date: Sun, 12 Sep 2010 16:01:26 +0200 Subject: Re: Host Manager. From: wesley.ache...@gmail.com To: users@tomcat.apache.org Okay I'm most of the way to a solution but I wouldn't mind if someone would take a look at a new WIP class and tell me what needs cleaning. Its not quite functional. Anyone interested? On Fri, Sep 3, 2010 at 4:44 AM, Wesley Acheson wesley.ache...@gmail.com wrote: Looked at that before not really convinced reworking that is easier than adding in an xml line or two via an xml writer. Willing to be convinced though. Wes On 9/3/10, Pid p...@pidster.com wrote: On 02/09/2010 21:06, Caldarale, Charles R wrote: From: Wesley Acheson [mailto:wesley.ache...@gmail.com] Subject: Host Manager. Is there is no documentation for the host-manager? Very little that I've found. You can learn a bit about it by looking at its WEB-INF/web.xml file. If I remember correctly from this list it doesn't persist its settings is that correct? Correct. How many people would be interested in it persisting its settings, by editing the appropriate files. I would be interested. Note that there's only one file to edit: conf/server.xml. Is that in theory possible? It's all software... to add the folder structure and the appropiate context.xml files. That's not necessary - the conf/Catalina/[host]/... files are already created automatically as webapps are deployed under the new Host. Only conf/server.xml needs to be updated. Would it interfere too badly with tomcat while it was running? No, Tomcat only reads server.xml during startup. Whatever update mechanism is used must insure that the file is never in an unparsable state (e.g., don't update in place, instead create a new file and then rename it). May I gently steer you in the direction of the JMX API and the Catalina:type=Server.Operations.storeConfig() command? Not sure it works very well at the moment, but if it did... p - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands
Re: Host Manager.
On Sun, Sep 12, 2010 at 5:38 PM, Martin Gainty mgai...@hotmail.com wrote: could you configure public static void writeXml( Node n, OutputStream os ) throws TransformerException of org.apache.tomcat.util.DomUtil to trap TransformerFactoryConfigurationError http://cupi2.uniandes.edu.co/site/images/recursos/javadoc/j2se/1.5.0/docs/api/javax/xml/transform/TransformerFactory.html#newTransformer%28javax.xml.transform.Source%29 it seems at minumum one of these conditions to be satisifed to properly newInstance the TransformerFactory ? Use the javax.xml.transform.TransformerFactory system property. Use the properties file lib/jaxp.properties in the JRE directory. This configuration file is in standard java.util.Properties format and contains the fully qualified name of the implementation class with the key being the system property defined above. The jaxp.properties file is read only once by the JAXP implementation and it's values are then cached for future use. If the file does not exist when the first attempt is made to read from it, no further attempts are made to check for its existence. It is not possible to change the value of any property in jaxp.properties after it has been read for the first time. Use the Services API (as detailed in the JAR specification), if available, to determine the classname. The Services API will look for a classname in the file META-INF/services/javax.xml.transform.TransformerFactory in jars available to the runtime. Platform default TransformerFactory instance. ? Martin Gainty So far my attempt is here now. https://issues.apache.org/bugzilla/show_bug.cgi?id=48674 Your way sounds better though :( - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Host Manager.
On 02/09/2010 23:14, Christopher Schultz wrote: Jeffrey, On 9/2/2010 5:40 PM, Jeffrey Janner wrote: I'd be happy if it just wrote out a new file based on the settings at the time I said save -- damn the comments. At least then, it's a pretty straight-forward bit of save code. But, if you're one of those who has to save the commentary that's already there, then have fun. It doesn't seem unreasonable to persist the comments: they're XML elements, too. If you can write code to parse and insert elements into an XML tree, you can afford to keep the comments in there, too. There is some code that tries to save server.xml in the 5.5. tree. It was used by the admin app. Mark - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Host Manager.
-Original Message- From: Pid [mailto:p...@pidster.com] Sent: Thursday, September 02, 2010 7:57 PM To: Tomcat Users List Subject: Re: Host Manager. On 02/09/2010 21:06, Caldarale, Charles R wrote: From: Wesley Acheson [mailto:wesley.ache...@gmail.com] Subject: Host Manager. Is there is no documentation for the host-manager? Very little that I've found. You can learn a bit about it by looking at its WEB-INF/web.xml file. If I remember correctly from this list it doesn't persist its settings is that correct? Correct. How many people would be interested in it persisting its settings, by editing the appropriate files. I would be interested. Note that there's only one file to edit: conf/server.xml. Is that in theory possible? It's all software... to add the folder structure and the appropiate context.xml files. That's not necessary - the conf/Catalina/[host]/... files are already created automatically as webapps are deployed under the new Host. Only conf/server.xml needs to be updated. Would it interfere too badly with tomcat while it was running? No, Tomcat only reads server.xml during startup. Whatever update mechanism is used must insure that the file is never in an unparsable state (e.g., don't update in place, instead create a new file and then rename it). May I gently steer you in the direction of the JMX API and the Catalina:type=Server.Operations.storeConfig() command? Not sure it works very well at the moment, but if it did... p Well, it certainly meets my requirement that it writes it out sans comments. I added two hosts, smith wesson, to an out-of-the-box 5.5.29 setup on Windows. For smith, I just proved a name and appbase. For wesson, I also unchecked AutoDeploy and DeployXML. I used jconsole to run the storeConfig(), and it renamed the old file to server.xml.timestamp and then wrote out a new server.xml sans comments. It appears that it doesn't write out anything that might be default settings. It didn't write out a port or shutdown value for Server and left out some parameters for the Connector for port 8080. It actually added a connectionTimout=-1 to the AJP connector. You can see the results below. All in all, it's not a great or perfect solution, but it is workable. ?xml version=1.0 encoding=UTF-8? Server Listener className=org.apache.catalina.core.AprLifecycleListener/ Listener className=org.apache.catalina.mbeans.GlobalResourcesLifecycleListener/ Listener className=org.apache.catalina.storeconfig.StoreConfigLifecycleListener / Listener className=org.apache.catalina.mbeans.ServerLifecycleListener/ GlobalNamingResources Environment name=simpleValue type=java.lang.Integer value=30/ Resource auth=Container description=User database that can be updated and saved name=UserDatabase type=org.apache.catalina.UserDatabase pathname=conf/tomcat-users.xml factory=org.apache.catalina.users.MemoryUserDatabaseFactory/ /GlobalNamingResources Service name=Catalina Connector port=8080 redirectPort=8443 minSpareThreads=25 connectionTimeout=2 maxSpareThreads=75 maxThreads=150 /Connector Connector port=8009 redirectPort=8443 connectionTimeout=-1 protocol=AJP/1.3 /Connector Engine defaultHost=localhost name=Catalina Realm className=org.apache.catalina.realm.UserDatabaseRealm/ Host appBase=polyweb2 autoDeploy=false deployXML=false liveDeploy=false name=wesson /Host Host appBase=polyweb name=smith /Host Host name=localhost /Host /Engine /Service /Server __ Confidentiality Notice: This Transmission (including any attachments) may contain information that is privileged, confidential, and exempt from disclosure under applicable law. If the reader of this message is not the intended recipient you are hereby notified that any dissemination, distribution, or copying of this communication is strictly prohibited. If you have received this transmission in error, please immediately reply to the sender or telephone (512) 343-9100 and delete this transmission from your system. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Host Manager.
From: Wesley Acheson [mailto:wesley.ache...@gmail.com] Subject: Host Manager. Is there is no documentation for the host-manager? Very little that I've found. You can learn a bit about it by looking at its WEB-INF/web.xml file. If I remember correctly from this list it doesn't persist its settings is that correct? Correct. How many people would be interested in it persisting its settings, by editing the appropriate files. I would be interested. Note that there's only one file to edit: conf/server.xml. Is that in theory possible? It's all software... to add the folder structure and the appropiate context.xml files. That's not necessary - the conf/Catalina/[host]/... files are already created automatically as webapps are deployed under the new Host. Only conf/server.xml needs to be updated. Would it interfere too badly with tomcat while it was running? No, Tomcat only reads server.xml during startup. Whatever update mechanism is used must insure that the file is never in an unparsable state (e.g., don't update in place, instead create a new file and then rename it). - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Host Manager.
I'd be interested as well. I've actually been meaning to get to this myself and submit a patch to make the changes persist, but my schedule has been too hectic for any extra-curricular work recently. If you don't (and I'm hoping you will)... I will get to it eventually. ;) -Jordan On 09/02/2010 01:06 PM, Caldarale, Charles R wrote: From: Wesley Acheson [mailto:wesley.ache...@gmail.com] Subject: Host Manager. Is there is no documentation for the host-manager? Very little that I've found. You can learn a bit about it by looking at its WEB-INF/web.xml file. If I remember correctly from this list it doesn't persist its settings is that correct? Correct. How many people would be interested in it persisting its settings, by editing the appropriate files. I would be interested. Note that there's only one file to edit: conf/server.xml. Is that in theory possible? It's all software... to add the folder structure and the appropiate context.xml files. That's not necessary - the conf/Catalina/[host]/... files are already created automatically as webapps are deployed under the newHost. Only conf/server.xml needs to be updated. Would it interfere too badly with tomcat while it was running? No, Tomcat only reads server.xml during startup. Whatever update mechanism is used must insure that the file is never in an unparsable state (e.g., don't update in place, instead create a new file and then rename it). - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Host Manager.
On Thu, Sep 2, 2010 at 10:42 PM, Jordan Michaels jor...@viviotech.netwrote: I'd be interested as well. I've actually been meaning to get to this myself and submit a patch to make the changes persist, but my schedule has been too hectic for any extra-curricular work recently. If you don't (and I'm hoping you will)... I will get to it eventually. ;) -Jordan On 09/02/2010 01:06 PM, Caldarale, Charles R wrote: From: Wesley Acheson [mailto:wesley.ache...@gmail.com] Subject: Host Manager. Is there is no documentation for the host-manager? Very little that I've found. You can learn a bit about it by looking at its WEB-INF/web.xml file. If I remember correctly from this list it doesn't persist its settings is that correct? Correct. How many people would be interested in it persisting its settings, by editing the appropriate files. I would be interested. Note that there's only one file to edit: conf/server.xml. Is that in theory possible? It's all software... to add the folder structure and the appropiate context.xml files. That's not necessary - the conf/Catalina/[host]/... files are already created automatically as webapps are deployed under the newHost. Only conf/server.xml needs to be updated. Would it interfere too badly with tomcat while it was running? No, Tomcat only reads server.xml during startup. Whatever update mechanism is used must insure that the file is never in an unparsable state (e.g., don't update in place, instead create a new file and then rename it). - Chuck I don't have a huge amount of time right now but yeah as far as I understand it, it shouldn't be tooo difficult. I do have another side project (in php) which Is probably more urgent to me. However I was thinking about doing this. Really I'm not sure what way the community is supposed to feed in its desires at the moment. So I thought maybe the best way was to ensure there was some interest here before committing myself. Wes
Re: Host Manager.
On Thu, Sep 2, 2010 at 10:06 PM, Caldarale, Charles R chuck.caldar...@unisys.com wrote: From: Wesley Acheson [mailto:wesley.ache...@gmail.com] How many people would be interested in it persisting its settings, by editing the appropriate files. I would be interested. Note that there's only one file to edit: conf/server.xml. Honestly I thought there was more than one going from this http://tomcat.apache.org/tomcat-6.0-doc/virtual-hosting-howto.html Is that in theory possible? It's all software... to add the folder structure and the appropiate context.xml files. That's not necessary - the conf/Catalina/[host]/... files are already created automatically as webapps are deployed under the new Host. Only conf/server.xml needs to be updated. I've just created a host using the host manager. And deployed a war. I don't see such a file. just the manager.xml Would it interfere too badly with tomcat while it was running? No, Tomcat only reads server.xml during startup. Whatever update mechanism is used must insure that the file is never in an unparsable state (e.g., don't update in place, instead create a new file and then rename it). Understood for server.xml is the same true of the context files though?
RE: Host Manager.
I'd be happy if it just wrote out a new file based on the settings at the time I said save -- damn the comments. At least then, it's a pretty straight-forward bit of save code. But, if you're one of those who has to save the commentary that's already there, then have fun. Jeff -Original Message- From: Wesley Acheson [mailto:wesley.ache...@gmail.com] Sent: Thursday, September 02, 2010 2:40 PM To: Tomcat Users List Subject: Host Manager. Few Questions Is there is no documentation for the host-manager? If I remember correctly from this list it doesn't persist its settings is that correct? How many people would be interested in it persisting its settings, by editing the appropriate files. Final question. Is that in theory possible? to add the folder structure and the appropiate context.xml files. Would it interfere too badly with tomcat while it was running? I really like the idea of the host manager. If it persisted its features I may actually have used it. Regards, Wes __ Confidentiality Notice: This Transmission (including any attachments) may contain information that is privileged, confidential, and exempt from disclosure under applicable law. If the reader of this message is not the intended recipient you are hereby notified that any dissemination, distribution, or copying of this communication is strictly prohibited. If you have received this transmission in error, please immediately reply to the sender or telephone (512) 343-9100 and delete this transmission from your system. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Host Manager.
From: Wesley Acheson [mailto:wesley.ache...@gmail.com] Subject: Re: Host Manager. Honestly I thought there was more than one going from this http://tomcat.apache.org/tomcat-6.0-doc/virtual-hosting-howto.html The files should be created automatically - but only when needed. I've just created a host using the host manager. And deployed a war. I don't see such a file. See what such file? just the manager.xml Where is that located? When I tried it (6.0.29), the host-manager copied its manager.xml template to conf/Catalina/[newHost]/manager.xml, and put this in it: Context docBase=${catalina.home}/webapps/manager privileged=true antiResourceLocking=false antiJARLocking=false /Context It also automatically created the new appBase directory for the new host. I did click the _Start_ button on the line for the new Host; don't know if that was needed or not. Understood for server.xml is the same true of the context files though? Since they've never been seen before (brand new Host), it won't matter. But there really aren't any for the host-manager to create, other than the one for the manager app, so webapps can be deployed under the new Host. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Host Manager.
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Jeffrey, On 9/2/2010 5:40 PM, Jeffrey Janner wrote: I'd be happy if it just wrote out a new file based on the settings at the time I said save -- damn the comments. At least then, it's a pretty straight-forward bit of save code. But, if you're one of those who has to save the commentary that's already there, then have fun. It doesn't seem unreasonable to persist the comments: they're XML elements, too. If you can write code to parse and insert elements into an XML tree, you can afford to keep the comments in there, too. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkyAIbUACgkQ9CaO5/Lv0PCh0ACdFLsEc5231/hM8bD1Ajx9AOq7 +hcAoIkwLr+vFJ0+sO6SYa67bAfvv1qc =amdL -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Host Manager.
On 02/09/2010 21:06, Caldarale, Charles R wrote: From: Wesley Acheson [mailto:wesley.ache...@gmail.com] Subject: Host Manager. Is there is no documentation for the host-manager? Very little that I've found. You can learn a bit about it by looking at its WEB-INF/web.xml file. If I remember correctly from this list it doesn't persist its settings is that correct? Correct. How many people would be interested in it persisting its settings, by editing the appropriate files. I would be interested. Note that there's only one file to edit: conf/server.xml. Is that in theory possible? It's all software... to add the folder structure and the appropiate context.xml files. That's not necessary - the conf/Catalina/[host]/... files are already created automatically as webapps are deployed under the new Host. Only conf/server.xml needs to be updated. Would it interfere too badly with tomcat while it was running? No, Tomcat only reads server.xml during startup. Whatever update mechanism is used must insure that the file is never in an unparsable state (e.g., don't update in place, instead create a new file and then rename it). May I gently steer you in the direction of the JMX API and the Catalina:type=Server.Operations.storeConfig() command? Not sure it works very well at the moment, but if it did... p - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org 0x62590808.asc Description: application/pgp-keys signature.asc Description: OpenPGP digital signature
Re: Host Manager.
Looked at that before not really convinced reworking that is easier than adding in an xml line or two via an xml writer. Willing to be convinced though. Wes On 9/3/10, Pid p...@pidster.com wrote: On 02/09/2010 21:06, Caldarale, Charles R wrote: From: Wesley Acheson [mailto:wesley.ache...@gmail.com] Subject: Host Manager. Is there is no documentation for the host-manager? Very little that I've found. You can learn a bit about it by looking at its WEB-INF/web.xml file. If I remember correctly from this list it doesn't persist its settings is that correct? Correct. How many people would be interested in it persisting its settings, by editing the appropriate files. I would be interested. Note that there's only one file to edit: conf/server.xml. Is that in theory possible? It's all software... to add the folder structure and the appropiate context.xml files. That's not necessary - the conf/Catalina/[host]/... files are already created automatically as webapps are deployed under the new Host. Only conf/server.xml needs to be updated. Would it interfere too badly with tomcat while it was running? No, Tomcat only reads server.xml during startup. Whatever update mechanism is used must insure that the file is never in an unparsable state (e.g., don't update in place, instead create a new file and then rename it). May I gently steer you in the direction of the JMX API and the Catalina:type=Server.Operations.storeConfig() command? Not sure it works very well at the moment, but if it did... p - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org -- Sent from my mobile device - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Host Manager Questions
Hello George Did you try to install manager.xml into $CATALINA_HOME/conf/[enginename]/[hostname] Martin- - Original Message - From: George Sexton [EMAIL PROTECTED] To: 'Tomcat Users List' users@tomcat.apache.org Sent: Thursday, December 01, 2005 12:49 PM Subject: Host Manager Questions I'm trying to use the host manager to deploy new hosts, and when I try to do so I get this error message: FAIL - Couldnt install manager.xml Does anyone have any idea what is happening? I'm using Tomcat version 5.5.9. George Sexton MH Software, Inc. http://www.mhsoftware.com/ Voice: 303 438 9585 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Host Manager Questions
Good Afternoon George I deploy thru Tomcat 5.5.7 Manager where I Browse to the war I want to deploy and click deploy and the webapp is unjar'ed, web.xml has correct entries for all jars and resources etc.. so the web application is installed and configured automatically when you use Tomcat 5.5.7 Manager Hope this helps, Martin- - Original Message - From: George Sexton [EMAIL PROTECTED] To: 'Tomcat Users List' users@tomcat.apache.org; 'Martin Gainty' [EMAIL PROTECTED] Sent: Thursday, December 01, 2005 3:18 PM Subject: RE: Host Manager Questions OK, that pointed me in the right direction. The tomcat user did not have WRITE permissions to the [enginename] directory. That now brings up the point that just slays me: Why in the world does it assume that I want the manager application deployed to the new host? Who thought that was a good idea? When I create the new host, it copies manager.xml, and deploys my ROOT context (which exists in docbase), but doesn't create a ROOT.xml file in the [enginname]/[hostname] Directory. Also, it doesn't appear that the host-manager modifies server.xml, so any aliases or options specified at creation are lost when the server re-starts. As it stands, this is pretty useless. It just infuriates me that any time I point out how bad the admin app is, everyone tells me to use manager, or host-manager, but they're totally useless as well. George Sexton MH Software, Inc. http://www.mhsoftware.com/ Voice: 303 438 9585 -Original Message- From: Martin Gainty [mailto:[EMAIL PROTECTED] Sent: Thursday, December 01, 2005 12:47 PM To: Tomcat Users List Subject: Re: Host Manager Questions Hello George Did you try to install manager.xml into $CATALINA_HOME/conf/[enginename]/[hostname] Martin- - Original Message - From: George Sexton [EMAIL PROTECTED] To: 'Tomcat Users List' users@tomcat.apache.org Sent: Thursday, December 01, 2005 12:49 PM Subject: Host Manager Questions I'm trying to use the host manager to deploy new hosts, and when I try to do so I get this error message: FAIL - Couldnt install manager.xml Does anyone have any idea what is happening? I'm using Tomcat version 5.5.9. George Sexton MH Software, Inc. http://www.mhsoftware.com/ Voice: 303 438 9585 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Host Manager Questions
Since I'm currently running something like 70 some odd virtual hosts on one tomcat installation I would really rather not have the manager application deployed on each of those 70 hosts. Each host has only one context (the ROOT context) and after the virtual host is created, it is seldom if ever changed. Its just really ridiculous that the host-manager doesn't serialize the creation options for the virtual host when it creates it, or that when it auto-deploys a web application on creation, it doesn't create a context.xml that points to the auto-deployed context. George Sexton MH Software, Inc. http://www.mhsoftware.com/ Voice: 303 438 9585 -Original Message- From: Martin Gainty [mailto:[EMAIL PROTECTED] Sent: Thursday, December 01, 2005 1:34 PM To: George Sexton Cc: Tomcat Users List Subject: Re: Host Manager Questions Good Afternoon George I deploy thru Tomcat 5.5.7 Manager where I Browse to the war I want to deploy and click deploy and the webapp is unjar'ed, web.xml has correct entries for all jars and resources etc.. so the web application is installed and configured automatically when you use Tomcat 5.5.7 Manager Hope this helps, Martin- - Original Message - From: George Sexton [EMAIL PROTECTED] To: 'Tomcat Users List' users@tomcat.apache.org; 'Martin Gainty' [EMAIL PROTECTED] Sent: Thursday, December 01, 2005 3:18 PM Subject: RE: Host Manager Questions OK, that pointed me in the right direction. The tomcat user did not have WRITE permissions to the [enginename] directory. That now brings up the point that just slays me: Why in the world does it assume that I want the manager application deployed to the new host? Who thought that was a good idea? When I create the new host, it copies manager.xml, and deploys my ROOT context (which exists in docbase), but doesn't create a ROOT.xml file in the [enginname]/[hostname] Directory. Also, it doesn't appear that the host-manager modifies server.xml, so any aliases or options specified at creation are lost when the server re-starts. As it stands, this is pretty useless. It just infuriates me that any time I point out how bad the admin app is, everyone tells me to use manager, or host-manager, but they're totally useless as well. George Sexton MH Software, Inc. http://www.mhsoftware.com/ Voice: 303 438 9585 -Original Message- From: Martin Gainty [mailto:[EMAIL PROTECTED] Sent: Thursday, December 01, 2005 12:47 PM To: Tomcat Users List Subject: Re: Host Manager Questions Hello George Did you try to install manager.xml into $CATALINA_HOME/conf/[enginename]/[hostname] Martin- - Original Message - From: George Sexton [EMAIL PROTECTED] To: 'Tomcat Users List' users@tomcat.apache.org Sent: Thursday, December 01, 2005 12:49 PM Subject: Host Manager Questions I'm trying to use the host manager to deploy new hosts, and when I try to do so I get this error message: FAIL - Couldnt install manager.xml Does anyone have any idea what is happening? I'm using Tomcat version 5.5.9. George Sexton MH Software, Inc. http://www.mhsoftware.com/ Voice: 303 438 9585 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]