install tomcat in one location and have multiple instances running for individual clients:
Why would you want to do this: ============================== 1) Install tomcat in 1 location and have x number of instances running on a per client basis 2) Upgrade tomcat and have it propagate to all clients 3) Limit the resources each tomcat instance uses 4) Tomcat runs as the individual user rather than "root" or "tomcat" 5) Each user has its own manager; hence, no security risk to others 6) Start/Stop/Restart tomcat instances without affecting other clients who also have a tomcat instance
Assumptions: ============ 1. Tomcat is installed in: /usr/local/tomcat (TOMCAT_HOME) 2. Instances are installed in: /usr/local/tomcat/instances 3. Java is installed somewhere on your machine
Step 1 - Create a Tomcat Instance ================================= - Create a directory in /usr/local/tomcat/instances/user1 (CATALINA_BASE) - Create a set of directories (conf,temp,logs,webapps) in $CATALINA_BASE - Copy web.xml,server.xml,tomcat-users.xml from $TOMCAT_HOME/conf to $CATALINA_BASE/conf - Create a bash script called user1startstop.sh as follows and make it executable
Quote:
#!/bin/bash export INSTANCE_NAME=user1 export CATALINA_BASE=/usr/local/tomcat/instances/user1 #This is where you'd be able to restrict the memory usage export CATALINA_OPTS=" -Djava.awt.headless=true" # Call the jsvc script to launch the Tomcat instance /usr/local/tomcat/bin/Tomcat5.sh $1
Replace: ... port=8005 with port 8101 ... This is shutdown port Replace: ... port=8080 with port 8201 ... This is http port Replace: ... port=8009 with port 8301 ... This is the AJP port
- Edit httpd.conf Add the following code under the VirtualHost definition of the user in question: <IfModule mod_jk.c> JkMount /*.jsp user1 JkMount /webapps/* user1 JkMount /servlets/* user1 JkMount /servlet/* user1 </IfModule>
Step 4 - Restart Apache
Step 5 - run $TOMCAT_INSTANCE/user1startstop.sh start
That's it.
I have 5 instances of tomcat running on my machine and it works like a charm.
I have set up Apache as a SSL front end for our web applications deployed in GlassFish Server 3.0.1 Open Source Edition, how can I keep the original URL displayed in the web browser address bar unchanged after redirecting via Rewrite / ProxyPass and ProxyPassReverse
Reference 1: RewriteEngine On
# If the request URL does not start with a slash (/), prepend it. RewriteRule ^([^/].*)$ /$1 [E=redirect:y,N] # If the request URL starts with more than one slash (/), keep only the first one. RewriteRule ^//+(.*)$ /$1 [E=redirect:y,N]
I keep hearing that redirecting from http to https is not very secure [non-SSL to SSL]. Among other reasons, one reason is that the browser may continue to think it is communicating with non secure server and may not encrypt the data. Is it true? I hope not, I am using the following -
I'm trying to redirect some threads in vbulletin from full version to archive version, I just have some problems and I have not been able to resolve it.
I'm on Apache/2.0.59 (Win32) mod_jk/1.2.21 Tomcat 5.5.9 and having a hard time configuring Home or Root dir for each domain.
For eg. domain1.com works as [url], but not directly. How do I set dir1 as domain1's root?
I tried the apache <virtualHost> directive in httpd.conf, which correctly sets dir1 as domain1's root but then the jsp doesn't work, index.jsp code is displayed in the browser.
I also tried several <host> combinations in server.xml, but nothing worked.
I have installed red5 war version at my tomcat webapps directory
which I have installed using easyapache 3, demos/porttester works great but I am unable to login to admin panel at [url] I get tyhe server address as well as username password panel but none of the passwords I try gets accepted, also in this type of installation I was unable to find register.html to create a login,
Depending on where u are at on my site (documents pages, training, main root, etc.) will depend on which type of background, footer, header and the like you'll get. Now I was thinking. Is there a way to have multiple error messages for more then one page depending on where you are at on a site? Right now it's intranet site and a modded snitz forum. What is the code and were does it go and in which apache conf file(s) does it go in?
I have a webserver using apache 2.4.4 and 2 application servers with tomcat 7 on windows server 2008 R2 which uses VMWare ESX5.
I use juvmroute to load balance between these 2 application servers. but with no error in apache and tomcat log files, it can not connect to application servers. and i have to restart the apache service. and it crashes after almost 5 minutes.
This is the part of the access.log file where the crash started:
[Mon Aug 05 00:02:51.980503 2013] [mpm_winnt:notice] [pid 1036:tid 292] AH00422: Parent: Received shutdown signal -- Shutting down the server. [Mon Aug 05 00:02:54.008507 2013] [mpm_winnt:notice] [pid 3416:tid 200] AH00364: Child: All worker threads have exited. [Mon Aug 05 00:02:54.024107 2013] [mpm_winnt:notice] [pid 1036:tid 292] AH00430: Parent: Child process 3416 exited successfully. [Mon Aug 05 00:08:12.932936 2013] [mpm_winnt:notice] [pid 2648:tid 296] AH00455: Apache/2.4.4 (Win64) configured -- resuming normal operations
Issue: Upgraded to Apache 2.4.4 and Tomcat 7.0.33. Accessing the website via HTTPS produces "Object not found" error. The error logs (server,tomcat,apache) show no errors. It was working with Apache 2.2
Server OS: Windows 2008 Apache: version 2.4.4 Tomcat: version 7.033 JRE: version 1.6.0_43 Httpd.conf
I am unable to get A username and password requested by http://127.0.0.1:8080. "Tomcat Manager Application"..I created userid and password in tomcat-users.x.
We want to implementing the load balancing for our domain, if the traffic is heavy and 8080 (i.e. currently integrated with apache) doesn''t serve more that time the apache will call 8081 and serve to the request without any problem.
We want to access our site www.domain.com (i.e. run on port 80). Please guide us it is possible or not?
I have an Apache Server (2.4.3) and a Tomcat Server (7.0.36) and have some Java Applications deployed.Everything works fine, but when we start a quite long Ajax process, I see in my Java Application, that a Ajax request is received and starts processing - everything fine. But during processing of the first request, I see a second request starts after 5 minutes.
My configuration is Apache 2.2.3 using Tomcat - AJP with mod_proxy_ajp, mod_ssl.We have configured Kerberos but some users are getting an error - Size of a request header field exceeds server limit.
Users with headers above 8K are getting this error, users less than 8K can get in fine. How can I increase this header limit in Apache/Tomcat? I have tried multiple suggestions found on google and other sites.
Here is what I tried:
Adding the following to the http.conf LimitRequestFieldSize 65536 ProxyIOBufferSize 65536
Adding the following to server.xml packetSize="65536"
editing a workers.propeties file, but we dont have any files on the server with that name.
<IfModule worker.c> StartServers 100 MaxClients 500 MinSpareThreads 25 MaxSpareThreads 75 ThreadsPerChild 25 MaxRequestsPerChild 100 </IfModule> Here is what is in the /var/log/httpd/error_log file before it dies:
Code: [Wed Jul 01 18:06:32 2009] [info] server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers), spawning 8 children, there are 98 idle, and 108 total children [Wed Jul 01 18:08:17 2009] [info] server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers), spawning 8 children, there are 74 idle, and 76 total children [Wed Jul 01 18:08:18 2009] [info] server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers), spawning 16 children, there are 63 idle, and 63 total children [Wed Jul 01 18:08:19 2009] [info] server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers), spawning 32 children, there are 79 idle, and 79 total children [Wed Jul 01 18:11:36 2009] [info] server seems busy, (you may need to increase StartServers, or Min/MaxSpareServers), spawning 8 children, there are 93 idle, and 108 total children
Our servers has been updated recently and my site is not working properly. It was working before the server change. When I click on the links, it doesn't update correctly, instead it gets the last cached data. I have to refresh each link for it to update which shouldn't be the case. I'm a front-end and have no access to servers. Could this be server-related?
I very much like the "readme.txt" that Apache appends to the directory listings. That is, when a browser GETs a directory, the text in that file is put underneath the list of files therein.
I am completely new to apache and I had the load balancer set up for a single domain that was working perfectly fine, but when it came to multiple domains i couldn't, for the life of me, figure out what to do.
There is example.com sub.example.com and otherexample.com
I had a single node set up for this but I want to experiment with the balancer. I have scratched Google and I only found broken info which couldn't explain much to me. Here are my domains
I inherited an Apache HTTP instance from a colleague. That's why I'm not deep into that stuff. My current scenario is the following: We are running several backend instances which are published to the internet via Apache HTTP Server which is configured as Reverse Proxy (RP). In the past there was only one port and one protocol to handle by the Apache HTTP (RP).
Now I have the following need. There has to be published a Web Service from one instance using two Ports with two protocols (HTTP and HTTPs). I'm not sure how to solve that need.
A solution I tried already was to change and add the variable DEF_BACKEND_PORT to DEF_BACKEND_PORT_1 and DEF_BACKEND_PORT_2 but it didn't worked.
I'm kinda new to apache and I have the following situation.
I have a vps, on which I have set the following:
WordPress Site A, has it's own VirtualHost and domain WordPress Site B, has it's own VirtualHost and domain Canvas LMS (not connected to a domain). Canvas LMS can add multiple accounts, which may (or may not) be accessed individually using a URL that looks as follows:
{canvas_root}/accounts/{account_id}/
For example : http://....../accounts/4/
I need to add a link to each of WP sites, which points to each site's account on Canvas, such that it appears as .../learning/ folder
I do not want the users to see the /account/4/ , just /learning/ I also want to prevent accessing Canvas LMS is located beyond the website's DocumentRoot I want this to work with both HTTP and HTTPS