Home Accessibility Courses Twitter The Mouth Facebook Resources Site Map About Us Contact
 
For 2023 (and 2024 ...) - we are now fully retired from IT training.
We have made many, many friends over 25 years of teaching about Python, Tcl, Perl, PHP, Lua, Java, C and C++ - and MySQL, Linux and Solaris/SunOS too. Our training notes are now very much out of date, but due to upward compatability most of our examples remain operational and even relevant ad you are welcome to make us if them "as seen" and at your own risk.

Lisa and I (Graham) now live in what was our training centre in Melksham - happy to meet with former delegates here - but do check ahead before coming round. We are far from inactive - rather, enjoying the times that we are retired but still healthy enough in mind and body to be active!

I am also active in many other area and still look after a lot of web sites - you can find an index ((here))

Well House Consultants
You are on the site of Well House Consultants who provide Open Source Training Courses and business hotel accommodation. You are welcome to browse and use our resources subject to our copyright statement and to add in links from your pages to ours.
Other subject areas - resources
Java Resources
Well House Manor Resources
Perl Resources
Python Resources
PHP Resources
Object Orientation and General topics
MySQL Resources
Linux / LAMP / Tomcat Resources
Well House Consultants Resources
Extras Resources
C and C++ Resources
Ruby Resources
Tcl/Tk Resources
Web and Intranet Resources
Web Application Deployment module A603
Further httpd Configuration
Exercises, examples and other material relating to training module A603. This topic is presented on public courses Deploying Apache and Tomcat, Deploying LAMP - Linux, Apache, MySQL, Perl/PHP, Linux Web Server, Deploying Java Applications on Linux / Unix

Per Directory controls via .htaccess, Virtual Hosts and starting your server automatically when the server is rebooted.

Related technical and longer articles
Windows - running Apache and MySQL from a CD
Load balancing and robustness - httpd, tomcat, PHP, Servlets, MySQL
Making all your .html files run a Perl script
A Web interface for your Linux admin tasks
Linux and httpd file system layout - LAMP server
The proxy jServ, jk, jk2, warp and jk story

Articles and tips on this subjectupdated
4307Identifying and clearing denial of service attacks on your Apache server
If ... ..... .... I ..... ..... were ...... ... ... ... to . ...... . write .... .... .... . a ... ...... ... ..... sentence, .. ... but ...... .. drip ...... . ..... ...... ... the ..... ... .. ...... ...... words . . .. out ..... .. ...... ..... . slowly ..... ... ...... with .... ... ..... ... long ...
2014-09-27
(longer)
1121Sharing the load with Apache httpd and perhaps Tomcat
"Can you show us how to share the load of a web site between various servers" is one of the question that comes up quite often on the more advanced web server configuration courses that we run. And, yes, I can, but I'll probably ask you a lot of extra questions about exactly how you want to load balance ...
2013-02-23
 
4001Helping search engines with appropriate 400 error codes
Our web site's done its best over the years to help people who enter URLs that have slight errors in them - misspellings, wrong directory names, etc ... and we have quite a number of scrips that take parameters which can be modified to give different results - for example   http://www.wellho.net/net/quote.html?where=L10+1RF will ...
2013-02-11
 
3955Building up from a small PHP setup to an enterprise one
I've often described Well House Consultants as a "mom and pop" company - a small outfit where we provide a niche service (IT Training and a business hotel in Melksham). We make heavy use of PHP on our web sites, and it serves us very well, being quick and easy for us to code and running well on our ...
2013-01-05
(longest)
1954mod_rewrite for newcomers
What is mod_rewrite? It's an Apache httpd (web server) module that takes user's requests for pages and diverts them to a resource of a different name (and perhaps type). Why might we want to do this? See previous article for some reasons and alternatives Here's a simple example of a rewrite rule: RewriteRule ...
2013-01-02
(longer)
3862Forwarding a whole domain, except for a few directories - Apache http server
I was set a puzzle via email last week - how to redirect an entire domain to a new server / domain, apart from three specific directories / folders which are to remain on the old server. Clearly, this is a task for mod_rewrite, and the natural and instrincive reaction is to write a regular expression ...
2012-09-22
 
1377Load Balancing with Apache mod_jk (httpd/Tomcat)
A single instance of Apache httpd can handle a very large number of simple requests for files to be served ... but a single instance of Apache Tomcat can handle far fewer requests for applications to be run. After all, there's a big difference between just handing someone a piece of data and having ...
2012-07-27
 
3635Parse error: parse error, unexpected T_STRING on brand new web site - why?
A brank new web site, written with standard commercial software, running on one of our dedicated servers which has dozens of other sites on it, with standard installs of Apache httpd, MySQL and other LAMP componets (Perl, PHP and Python) - and yet the following error: Parse error: parse error, unexpected ...
2012-03-10
 
3449Apache Internal Dummy Connection - what is it and what should I do with it?
When the Apache HTTP Server manages its child processes, it needs a way to wake up processes that are listening for new connections. To do this, it sends a simple HTTP request back to itself. This request will appear in the access_log file ... typically from 127.0.0.1 or your server's IP address. For ...
2011-09-19
 
3133An image from a website that occasionally comes out as hyroglyphics
Do you have an image that displays perfectly in your browser when you download it from your website ... ... but you get occasional reports from users that it comes out as a string of hyroglyphics for them ... The problem may be that the server isn't sending the right content-type header, and that ...
2011-01-14
 
2900Redirecting a page - silent, temporary or permanent?
To 301 or not to 301 ... that is the question. Whether 'tis better to quietly redirect your users to a new page through mod_rewrite, or to instruct them to look elsewhere - Darren Shakespeare - 2003 ;-) In all seriousness - what should you do when someone arrives at your web site looking for a URL that ...
2010-10-08
 
2478How did I do THAT?
I had great fun putting together yesterday's blog about My train journey from Melksham, with a whole lot of images in the text rather than real words. For my first tests, the images sat on the line like this: which starts to look really ugly once you 've added more that a couple of pictures - so I ...
2009-10-26
 
2272Monitoring and loading tools for testing Apache Tomcat
The following monitoring and loading tools can be used to test Apache Tomcat and are all Open Source. This comparative summary includes a link to more details of each of these resources. ab - ApacheBench. Part of the standard Apache httpd download - a good but basic soak test where you can see how ...
2009-07-07
 
1939mod_proxy_ajp and mod_proxy_balancer examples
One of the major enhancements in release 2.2 of Apache httpd is the addition of the mod_proxy_ajp and mod_proxy_balancer modules to the standard distribution. Gone are the days of needing to build special modules such as Jserv, jk, jk2 and warp to have httpd act as a "front" to a Java (Tomcat) server ...
2009-05-10
 
2060Database connection Pooling, SSL, and command line deployment - httpd and Tomcat
Yesterday (yes, that was a Saturday!) I was running a tailored Apache Tomcat training and consultancy day - a day on which I cover a lot of standard training material, but did so in relation to a particular application for the delegate(s). Most of what I covered was in our own material (which we can ...
2009-03-01
 
1974Moving a directory on your web site
Apache httpd's mod_alias is part of your standard web server build ... it's the part that allows you to put alias directives into your configuration file httpd.conf to that different parts of your web tree can reside on different parts of your computer's file system. As an example, the manual that's ...
2009-01-03
 
1955How to avoid duplicating web page maintainance
How do you move from a web site with a single static page to a web site with a thousand pages (URLs) without multiplying your maintainance work by a thousand? Such is the critical importance of being able to do this that there are many schemes available - many solutions - and virtually every site that's ...
2008-12-21
 
5502006 - Making business a pleasure
"Making Business a Pleasure" - a spoken logo for Well House Consultants for 2006. Whether you're attending a course, staying as a guest at Well House Manor, working for us, or simply visiting our web site, we want you to enjoy the experience. We don't know exactly what 2006 will bring, but we have ...
2008-09-27
 
1778Pointing all the web pages in a directory at a database
Do you want a web directory of pages, where each of them has its own page name (URL), but there isn't really a separate page for you to maintain - all the data is held in some sort of database on your server, and the pages are created automatically from the data as they're requested? You can do this ...
2008-08-30
 
1767mod_proxy and mod_proxy_ajp - httpd
Under Apache httpd version 2.2, mod_proxy_ajp provides a neat way for you to forward requests to an appropriately configured Apache Tomcat server using the more terse ajp protocol rather than the verbose http. Here are some sample configuration lines from httpd.conf, forwarding requests under the ...
2008-08-23
 
1762WEB-INF (Tomcat) and .htaccess (httpd)
Apache Tomcat's WEB-INF directory is rather like Apache httpd's ".htxxxxx" files - they both contain data which is within the document directories, but is configuration data that's not directly visible to the web. WEB-INF/web.xml (Tomcat) contains the extra configuration information for the current ...
2008-08-20
 
1707Configuring Apache httpd
There are two approaches to bundling software for user installation. "The MicroSoft way" is to use an install wizard that drops each of the elements of the software into the best operational place on the user's system, and configures it there for running straight away. "The OpenSource way" is to install ...
2008-07-12
 
1636What to do if the Home Page is missing
The Web Server Administrator has two choices as to what he / she should do when a content provider doesn't supply a home page (index.html or similar) in a directory - either he can generate an error such as a 403 ("Forbidden") or 404 ("Not found"), or he can generate a directory listing, so that the ...
2008-05-09
 
649Denial of Service ''attack''
We've had 45000 page requests in the last week from the University of Illinois - 17000 of which were within a period of a few hours yesterday. Not bad going? Had we been recommended to the whole University as a site worth seeing? Alas, no; all the requests were coming from a single host computer, ...
2008-05-04
 
345Spotting a denial of service attack
Our web site traffic rose from 37000 hits last Wednesday to 64000 hits on Thursday. Good sales and marketing activity on our part? No - it's a potential problem; all the extra traffic came from a single location and my immediate concerns included: * Possible denial of service, where all the bandwidth ...
2008-05-04
 
1619User and Group settings for Apache httpd web server
When you're running an Apache httpd web server, you should run it using a separate daemon user account and group set up for the purpose and not run it as either root (a horrific thing to do, as it would lead to all sorts of security holes) or nobody (another very bad idea, as the "nobody" applications ...
2008-04-23
 
1566Strange behaviour of web directory requests without a trailing slash
When you call up a web page and you give a directory name WITHOUT a training slash, the web server return a "moved temporarily" page - code 302 - giving you the same name WITH a trailing slash as your new page: Dorothy:~ grahamellis$ telnet 192.168.200.162 80 Trying 192.168.200.162... Connected to 192.168.200.162. Escape ...
2008-03-06
 
1564Default file (MiMe types) for Apache httpd and Apache Tomcat
Apache Tomcat web server default MIME type What file extension maps to what "Mime Type" in Apache Tomcat? It's important to know, since the Mime type is sent out by the server to the browser to tell the browser how to handle the following data stream. a) There is a long list of extensions and their ...
2008-03-05
 
1554Online hotel reservations - Melksham, Wiltshire (near Bath)
I'm happy to announce the release of our online booking system for rooms at Well House Manor - the hotel that we run alongside our training centre, catering also for other visitors to the area of West Wiltshire and Bath who are looking for larger, superior rooms, unlimited internet access, large screen ...
2008-02-24
 
1551Which modules are loaded in my Apache httpd
Modules for use in httpd can be loaded statically or dynamicaly. A couple of core modules are built in by default if you build your own server, and you can choose others too using --enable options to the ./configure command. We do this on our Linux Web Server and Deploying httpd and Tomcat courses ...
2008-02-23
 
1381Using a MySQL database to control mod_rewrite via PHP
Question: How can I set up Apache httpd / mod_proxy to use a program rather that a list of URL patterns to control my rewrites? Specify a rewrite map type prg in your httpd.conf or .htaccess file. For example: RewriteEngine On RewriteMap tryme prg:/home/trainee/website/andy RewriteRule (.*\.htm) ${tryme:$1} Question: ...
2007-10-05
 
1355.php or .html extension? Morally Static Pages
You'll find many pages on our web site with .php extensions, and many more with .html extensions. "So the .php files contain executable content and the .html files do not" you may think. No - not exactly; in practise almost every page actually contains some PHP / Script elements. So WHAT, WHY, HOW? WHAT ...
2007-09-18
 
1351Compressing web pages sent out from server. Is it worth it?
Web servers can compress .html and similar files before they send them out - a great way to keep traffic volume down where bandwidth is more of a consideration than processor power. But what proportion of browsers can accept compressed data? That's a darned good question which I was asked on today's ...
2007-09-14
 
1207Simple but effective use of mod_rewrite (Apache httpd)
[Index under mod_rewrite tutorial] Do you want a single 'intelligent' web page to provide the content for tens or hundreds of URLs so that you don't have to write each similar page individually? Do you want to set up your server so that it will take any requests for ".htm" files and turn them into ".html"s? ...
2007-05-29
 
1080httpd.conf or .htaccess?
You can put Apache httpd configuration changes into both the httpd.conf file and files called .htaccess. What's the difference? Which should you use? If you put directives into httpd.conf - or any files called up with an include: * They are read only when the server restarts * They are set up by the ...
2007-02-14
 
1009Passing GET parameters through Apache mod_rewrite
If you're using Apache mod_rewrite to redirect a series of URLs to a single script, did you know that you can pass values entered onto a form via the GET method through as well? Simply add on %{QUERY_STRING} onto the end of your new URL. You'll need to add a ? into the target URL to ensure that the ...
2006-12-27
 
934Clustering, load balancing, mod_rewrite and mod_proxy
"It's not friendly - it's like a reference book". Customer comment on yesterday's tailored training day, where we were load balancing a web application between a number of back end servers, using Apache httpd, with mod_proxy and mod_rewrite to do the clever bits. Our customers are right - it IS tough ...
2006-11-26
 
853To list a directory under httpd on a web server, or not?
One of the choices a web server administrator has to make when he configures a web server is what to do with directories in which his content suppliers do not put a home page. Does he want to provide an error response (such as a "404" or "403" page), or does he wish to provide a directory listing? A ...
2006-09-02
 
755Using different URLs to navigate around a single script
1. I want my website to have different URLs for each of my content pages so that users can easily bookmark pages, pass them on to friends and contacts easily and with confidence, and search engines can register and handle each as its own distinct page but 2. I want most of the pages on my website to ...
2006-06-13
 
631Apache httpd to Tomcat - jk v proxy
Many of our customers run both the Apache httpd and Apache Tomcat web servers - with good cause, since Tomcat is biased towards web applications where the same code is run many, many times over and httpd is biased towards serving pages and is better tuned for a much larger number of different pages but ...
2006-06-09
 
466Separating 'per instance' data from binaries and web sites
When you install Apache httpd or Apache Tomcat, everything goes into a single directory tree. That's the most natural way for the servers to ship as it means that they can be installed, tested, and then removed again easily if you wish without any complex procedure being involved. But for a live environment, ...
2006-06-05
 
Examples from our training material
AUP   Acceptable User Policy
DOThtaccess   mod_rewrite - all .html request divert to a script
DOTmy.cnf   Override MySQL defaults with .my.cnf
README   sample README file
add_account.php   Add a MySQL and Linux account from a web page
andy   A Programmed RewriteMap for mod_rewrite in PHP
demo.php   Demonstration of mod_rewrite
fulluser   Script to create Linux and MySQL accounts
mpmsample.conf   Sample Annotated Prefork and Worker MPM configurations
webuser   Script to run
Background information
Some modules are available for download as a sample of our material or under an Open Training Notes License for free download from [here].
Topics covered in this module
Automatic Start-up.
Per-directory control.
Virtual Hosts.
Name-based Virtual Hosts.
IP-based virtual hosts.
Complete learning
If you are looking for a complete course and not just a information on a single subject, visit our Listing and schedule page.

Well House Consultants specialise in training courses in Linux and LAMP,Ruby, Lua, Python, Perl, PHP, and MySQL. We run Private Courses throughout the UK (and beyond for longer courses), and Public Courses at our training centre in Melksham, Wiltshire, England. It's surprisingly cost effective to come on our public courses - even if you live in a different country or continent to us.

We have a technical library of over 700 books on the subjects on which we teach. These books are available for reference at our training centre.


You can Add a comment or ranking to this page

© WELL HOUSE CONSULTANTS LTD., 2024: 48 Spa Road • Melksham, Wiltshire • United Kingdom • SN12 7NY
PH: 01144 1225 708225 • EMAIL: info@wellho.net • WEB: http://www.wellho.net • SKYPE: wellho

PAGE: http://www.wellho.net/resources/A603.html • PAGE BUILT: Sun Oct 11 14:50:09 2020 • BUILD SYSTEM: JelliaJamb