This repository has been archived on 2024-04-08. You can view files and clone it, but cannot push or open issues or pull requests.
phptsmadmin/includes/jpgraph/docs/chunkhtml/apjs03.html

41 lines
4.4 KiB
HTML
Raw Normal View History

2011-05-28 09:51:52 +00:00
<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>Approaches to running multiple PHP versions</title><link rel="stylesheet" type="text/css" href="manual.css"><meta name="generator" content="DocBook XSL Stylesheets V1.76.0"><link rel="home" href="index.html" title="JpGraph Manual"><link rel="up" href="apj.html" title="Appendix J. Setting up PHP5 in parallel with PHP4 in SuSE 10.1"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Approaches to running multiple PHP versions</th></tr><tr><td width="20%" align="left"> </td><th width="60%" align="center">Appendix J. Setting up PHP5 in parallel with PHP4 in SuSE 10.1</th><td width="20%" align="right"> </td></tr></table><hr></div><div class="section" title="Approaches to running multiple PHP versions"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="id2654423"></a>Approaches to running multiple PHP versions</h2></div></div></div>
<p>There are two fundamental ways of running multiple versions of PHP on the same server. </p>
<p>
</p><div class="orderedlist"><ol class="orderedlist" type="1"><li class="listitem">
<p>Running multiple instances of the HTTPD demon where each instance listens
on separate addresses and/or ports. </p>
<p><span class="bold"><strong>Advantage:</strong></span> This is the only way to run
multiple versions of PHP as (SAPI) modules in Apache2. In addition this has
some better security since potential crashes will be isolated and not effect
the other HTTPD demons. </p>
<p><span class="bold"><strong>Drawback:</strong></span> Running multiple HTTPD
instances will need more system resources in terms of memory and file
handlers. </p>
</li><li class="listitem">
<p>Running one instance of the HTTPD demon which is configured to serve
multiple virtual hosts. This is the approach we have chosen. </p>
<p><span class="bold"><strong>Advantage:</strong></span> Minimum system overhead and
relatively easy to setup. </p>
<p><span class="bold"><strong>Drawback:</strong></span> Only one PHP version can be run
as a (SAPI) Apache module the other PHP versions must be
configured/installed as CGI modules. This has a slight performance impact
and might not be suitable for heavily loaded production sites. (Note: that
could be overcome with the use of fast-cgi which works by pre-loading an
instance of PHP in memory which will then be used by the Apache process. See
Apache2 documentation regarding fast-cgi for more details). </p>
<p>
</p><div class="note" title="Note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3>
<p>There are actually two versions of virtual hosts with apache. By
name pr by IP-address. In this example we have chosen to match the
virtual hosts by IP address since for a development server we want
to be able to use plain IP addresses and not have the added
complexity of setting up a full DNS server. For more details about
other differences please see the excellent Apache2 documentation.
</p>
</div><p>
</p>
</li></ol></div><p>
</p>
</div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"> </td><td width="20%" align="center"><a accesskey="u" href="apj.html">Up</a></td><td width="40%" align="right"> </td></tr><tr><td width="40%" align="left" valign="top"> </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> </td></tr></table></div></body></html>