tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <ch...@christopherschultz.net>
Subject Re: Changing Sever.xml without restarting Tomcat 8.5
Date Mon, 23 Jul 2018 18:32:55 GMT
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Laurie,

On 7/23/18 12:25 PM, Laurie Miller-Cook wrote:
> Hi there,
> 
> I have an issue where we have multiple virtual hosts in separate 
> base directory's on a single Tomcat installation.  If I need to 
> change something within server.xml I need to restart Tomcat which 
> means I need to do this within an outage window as it affects all
> of the Websites, is there a way of reloading the server.xml without
>  restarting Tomcat?
> 
> As a bit of background we have a wildcard domain, so 
> <clientname>.<Domain>.com so we have created multiple webapp 
> directories with their own Manage and have multiple entries in the
>  server.xml file for the different hosts.
> 
> What need to be able to do is, for example, is add another host to
>  the xml site and get that to take effect automatically without the
>  need to restarting Tomcat as this restarts all the other websites 
> and hence gives outages to our customers.
> 
> Any help would be greatly appreciated.

Tomcat won't reload server.xml. It's just too complicated to determine
what has changed and how to perform an in-place reinit that only does
what is "necessary".

On the other hand, JMX is very powerful and you can make runtime changes
to Tomcat using that. Maybe you can consider performing two operations
whenever you need to add a virtual host:

1. Modify the conf/server.xml
2. Issue a JMX command to provision the new virtual host in the running
Tomcat

You might also want to consider having separate Tomcat instances per
domain. That might be more manageable, though it will require more
memory on your server(s).

- -chris
-----BEGIN PGP SIGNATURE-----
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIzBAEBCAAdFiEEMmKgYcQvxMe7tcJcHPApP6U8pFgFAltWH1YACgkQHPApP6U8
pFif+xAAqBJLoPub6ZsICJGVp5N87IYUlhcsFXEULLkomOkDCHGROea91uhUOdu+
a9JRZbC6tQQmhopqGNb5HkZrkNvkPBT13/71TDB7faGzwLXOv1/V0dRPO7KscgTq
PikAuyXhSNyfOYorv7xKq2MwUdT86dAovukf8ClEDE1mX/7CgtE/MjW64eQcTc59
HNB8CilW8bAs3ApZso1EQEaUYoE7EkCtyWlnEFAtbbPsgzDD3CTpp4iqiVDGXkYD
LsXUvLM8DtVdslzLztX5rRRxDaPsYXd8g9IOfi4yLqOMeOeO0FogBc6VpuC1d7gD
TOeQARm0k2Xf/RbUKbAbD1gV/8xFPI4bKtSJINSD/A5o1Qpvv/rtVz0pQYJA8fgb
u8v485wpmEFSDN+tE9MXE6YQ6HBJRtGQJ8j2xhhqU+iTbXonYX+BbxW9sqhXvvua
5i6cMjuWBuu49HYreaVHdV9N2kfxEJ2wLzVKXE3BEsWnVGYJEFHYizqS3yNyj9qv
cDw1Pc5jfYdfzFkn8oXZe1t1fHXRcxTN6XpwBKzmHxEkwCh+cvwwkZ10zaEjphs1
22X6xsi88e0ng/xdoQPKb+CPNq/13VYS0l1jlAcMc8DPeocSonMv20Y9pySep80h
YioelFbIrdjH7teVKoR9GoR2f/vA22D7UV600GOi2nXiWVWkn2Y=
=hB5A
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message