This chapter describes how to set up your new Stronghold Web Server:
If you are upgrading an existing Apache or Stronghold server, install this version of the Stronghold software into a new directory as described in this chapter, then continue to either:
If you are upgrading: If you have an existing Apache or Stronghold server on the same host, you must stop the old server or install Stronghold on ports that your server does not use.
- To stop Stronghold, use the ServerRoot/bin/stop-server script or the ServerRoot/stop script, depending upon which version of Stronghold you are upgrading from.
- To stop Apache, use the apachectl stop script.
Stronghold Web Server is available for most varieties of the UNIX operating system. However, you need a server platform that meets these system requirements:
df
sar -r 5 6Note that running this command on Red Hat Linux system requires that you have the sysstat package installed.
Those are the minimum requirements for running Stronghold itself. In addition, you also need:
As your log files accumulate data over time, they occupy more disk space. The largest log files are the access logs, which occupy about 80 bytes per request, or 1MB per 10,000 requests. For example, if your site receives 200,000 hits per day, you accumulate 20MB of log entries per day. You should plan to rotate your logs regularly to control the file size of the current log, and to allow archiving of older log files to conserve disk space.
For moderate traffic on a Linux platform, allow at least 32MB of memory for the server. On a Solaris system, allow at least 64MB. If you plan to run a high traffic site, you need significantly more memory than the minimum; if you plan to run a light-traffic site, less memory will suffice.
Platform support for virtual hosts is recommended, but it is not required.
Stronghold Web Server is distributed as a single, self-contained installer file. There are two general types:
To install Stronghold on a Red Hat Linux Advanced Server 2.1 system:
./install
If you receive an error, such as Permission denied, then you must change the installer’s file permissions before continuing:
chmod u+x install
The installer installs all of the Stronghold software, then asks if you want to enable Red Hat Content Accelerator (TUX) and Tomcat.
After you make your choices, the installer automatically starts Stronghold for you.
Continue reading at Verifying the Stronghold Installation.
If you will want to run Tomcat: The Tomcat Servlet/JSP container requires a Java Developer’s Kit (JDK), version 1.2 or above. If such a JDK is not installed, download and install one from either Sun’s Java site (http://java.sun.com) or from the IBM Java site (http://www-106.ibm.com/developerworks/java/) before continuing with the Stronghold installation.
To install the Stronghold software on systems other than Red Hat Linux Advanced Server:
./install
If you receive an error, such as Permission denied, then you must change the installer’s file permissions before continuing:
chmod u+x sh-40-
Type in that directory path and press [Enter]. If the directory you enter does not exist, the program asks you to confirm that you want to create the new directory.
The directory path you enter is referred to as ServerRoot in the Stronghold documentation. Wherever you see a reference to ServerRoot, substitute the actual path that you entered here.
Use the [space] bar to select or de-select packages and the arrow keys to move through the list. When you have made your selections, install the software by pressing [Enter]. You can install both PHP 3 and PHP 4. By default, PHP 4 runs; to run PHP 3 instead, you need to modify the configuration file (httpd.conf). To learn how to run both PHP 3 and PHP 4 at the same time, refer to the documentation available at: http://www.php.net/
The program installs the Stronghold Web Server and its components, and a status bar displays the installer’s progress. When the installation is complete, the program prompts you to press [Return] to continue with the configuration phase of the installation.
After the Stronghold software has been installed, you are prompted to configure the Stronghold server:
The installer guesses the hostname and presents this as the default; edit if incorrect.
The default is webmaster at the hostname you entered in the previous step.
Browsers automatically direct their requests to port 80 unless the user specifies a different port when they type the URL. To install Stronghold as an SSL-only server, enter 0 (that is, zero). If you are installing the server as root, you can choose any unused port number. If you are installing as a user other than root, you may only choose an unused port number of 1024 or above.
If the port you choose is already in use, the installer prompts you to choose a different one.
Browsers automatically direct HTTPS requests to port 443 unless the user specifies a different port when they type the URL. If you are installing the server as root, you can choose any unused port number. If you are installing as a user other than root, you may only choose an unused port number of 1024 or above.
If the port you choose is already in use, the script prompts you to choose a different one.
If you have a server certificate from a previous release of Stronghold, the installation program alerts you to the migration information that you can find later in this manual, then continues the installation with the step that follows.
If this is your first installation of Stronghold, the installation program generates a new keypair. The keypair is required to encrypt and decrypt secure communications with your customers. The key will be stored in the file: ServerRoot/conf/ssl/private/ServerName.key and the certificate will be stored in: ServerRoot/conf/ssl/certs/ServerName.cert
When choosing key sizes: Key sizes must either be 512 or 1024 for compatibility with certain browsers. We recommend 1024 bits. Keys larger that 1024 bits are incompatible with some versions of Netscape Navigator and Microsoft Internet Explorer, and with other browsers that use RSA’s BSAFE cryptography toolkit.
To generate a certificate, select Yes and continue reading at Requesting a Signed Certificate or Creating a Temporary Certificate.
If you already have a certificate from a previous Stronghold Web Server or Apache installation, select No and continue reading at Manually Upgrading to Stronghold 4.0 (or the appropriate subsection for other versions).
If your preferred CA requires you to supply a challenge password or an optional company name, enter them when prompted, otherwise press [Return].
The program prints the certificate signing request (CSR), which looks something like this:
-----BEGIN NEW CERTIFICATE REQUEST----- MIIBEzCBzgIBADB7MQswCQYDVQQGEwJVUzETMBEGA1UECBMKQ2FsaWZvcm5pYTEQ MA4GA1UEBxMHT2FrbGFuZDEbMBkGA1UEChMSQzJOZXQgU29mdHdhcmUgSW5jMRAw DgYDVQQLEwdUZXN0aW5nMRYwFAYDVQQDEw1nYWJiZXIuYzIubmV0MEwwDQYJKoZI hvcNAQEBBQADOwAwOAIxAJukoQhq4LanG2k+/LnRTGJAcgv9LJPsdfCsjqRs8ygo yaw4ucOEdx+WdnM0x36NcQIDAQABMA0GCSqGSIb3DQEBBAUAAzEABRLR6IkG70oN G1MnvuMDeWou4kIvc98ysjssCNKsDKsHAXBSEbfsIQs5JRNagVBW -----END NEW CERTIFICATE REQUEST-----
Continue reading at Verifying the Stronghold Installation.
Some country codes may not be what you expect; for example, you should use GB in the United Kingdom. For a complete list, see Country Codes.
If your preferred CA requires you to supply a challenge password or an optional company name, enter them when prompted, otherwise press [Return].
The program prints the certificate signing request (CSR), which looks something like this:
-----BEGIN NEW CERTIFICATE REQUEST----- MIIBEzCBzgIBADB7MQswCQYDVQQGEwJVUzETMBEGA1UECBMKQ2FsaWZvcm5pYTEQ MA4GA1UEBxMHT2FrbGFuZDEbMBkGA1UEChMSQzJOZXQgU29mdHdhcmUgSW5jMRAw DgYDVQQLEwdUZXN0aW5nMRYwFAYDVQQDEw1nYWJiZXIuYzIubmV0MEwwDQYJKoZI hvcNAQEBBQADOwAwOAIxAJukoQhq4LanG2k+/LnRTGJAcgv9LJPsdfCsjqRs8ygo yaw4ucOEdx+WdnM0x36NcQIDAQABMA0GCSqGSIb3DQEBBAUAAzEABRLR6IkG70oN G1MnvuMDeWou4kIvc98ysjssCNKsDKsHAXBSEbfsIQs5JRNagVBW -----END NEW CERTIFICATE REQUEST-----
Continue reading at Verifying the Stronghold Installation.
After installing Stronghold 4.0, there are some browser-based tools available for you to test certain components. To access these tools, open a browser and enter the URL: http://fully_qualified_hostname:http_port/stronghold
On the left navigation bar, the Examples section has links that test Stronghold components:
The Status section has links to server status information:
If you are migrating from a previous installation, continue reading at Manually Upgrading to Stronghold 4.0.