WIN2003 Iis6.0+php+asp+mysql Optimized configuration

Source: Internet
Author: User
Tags phpinfo zend

Because IIS 6.0 for Windows 2003 is not installed by default, the support for ASP is turned on and it is easy to configure This step manually
First run the "Add Remove Programs" option in the Control Panel after you select Install IIS 6.0 Install IIS 6.0 to enable ASP support by default if you find that the ASP is not allowed to run, you can press the A B C step to open
A: Open IIS 6.0 in the Start menu-"Programs-" Administrative Tools Select "WEB service Extensions"
B: Click the Active Server Pages component and the remote Administration (HTML) tool "Active Server Pages" and set to allow
C: Click "Internet Data Connector" and set to allow


Second in the Default Web Site Properties window, press the "Home Directory" tab, "Configure" button in the pop-up " Application Configuration" window, click the "Options" button to check "Enable parent path" to determine
In the annex (IISIIS2)


Three PHP environments that configure WINDOWS 2003 IIS 6.0
A lot of friends have mentioned that WINDOWS 2003 + IIS 6.0 follow the online method no matter how the configuration is not successful search for a look everywhere is the same version of the pirated reprint is not successful
Now describe how this site is configured for the PHP environment in Windows 2003 IIS 6.0
Let IIS6.0 support the installation configuration of PHP-=> php4.3.9
We do not recommend the use of the installation version here php4.3.9 's decompression version
The first step is to untie the Php-4.3.9-win32.zip compression pack you can put it under C:\PHP.


The second step is to copy the C:\PHP below the php.ini-dist file into the c:windows directory and rename it to php.ini depending on the situation you can modify some parameters yourself first we need to tell PHP where to find its extension function module file under Modify C: The Windowsphp.ini file needs to be noted as follows
Find Extension_dir string modified to extensions path in your PHP directory:
; Directory in which the loadable Extensions (modules) reside
Extension_dir = "C:\PHP"
This example can be set to "extension_dir=c:php" as the directory where the PHP file is located


The third step is to copy the C:phpphp4ts.dll into the C:windowssystem32 directory.


Fourth Step Control Panel--"management tool--" Internet Service Manager--"Click" Web Service Extensions "--" in the right window click on "Add a new Web service extension"-"the extension of" PHP "-" and then click "Add"-"in the window that appears to fill in" C: PHPsapiphp4isapi.dll "and OK then click on Web Service Extension PHP and select Allow (attachment: IIS3-IIS6)


Fifth step in the "Default Web Site Properties" window, press the "Home directory" tab point "Configure" button in the pop-up window to click the "Add" button, in the pop-up "Add/Edit Application Extension Image" dialog box in the Executable text box, enter "C: PHPsapiphp4isapi.dll ". php" in the "Extension" text box (be sure to have that point) and tick the "Check for file Existence" entry (attachment: IIS7-IIS9)


The sixth step is to click on the "ISAPI filter" tab on the "Default Web Site Properties" window, tap the "Add" button, and in the "Filter Name" of the pop-up Filter Properties window, enter "PHP" in "executable" to browse the selected "C:phpsapiphp4isapi.dll" And then determine
A: Stop IIS 6.0 from running and then restart IIS 6.0 to start loading the PHP view
B: On the Default Web Site Properties window, click the ISAPI Filter tab if you see PHP's Arrow Green and up to prove that PHP has been successfully loaded by IIS 6.0 (attachment: IIS10)


Seventh step in the Default Web Site Properties window on the Home Directory tab modify if PHP is configured in IIS6.0 as the CGI runtime mode, which is all loaded PHP.exe Execute permissions to "scripts and executables" and run in ISAPI mode, load all PHP4isapi.dll to remain The default "pure script" can be used to further enhance the security of the system application pool for "DefaultAppPool" OK (attachment: IIS11)
In this step, the configuration of the PHP environment is complete.


Eighth Step Test
After the configuration is complete, if you want to test whether PHP is installed successfully, you can create a file in the space Reagan directory, such as test.php, and then write the following statement
<?
Phpinfo ();
?>
Use IE to access this file after saving
http://www.11k.net/test.php;
If you can see this familiar page to configure the PHP environment is really successful
Of course you can also configure PHP to run in CGI mode
The specific method is to change the original set path "C:phpsapiphp4isapi.dll" to "C:phpphp.exe"%s "%s" and then "check for the existence of files" cancel and then determine the basic settings are complete
Final Test ...
<?
Phpinfo ();
?>
If CGI error occurs
The specified CGI application misbehaved by isn't returning a complete set of HTTP headers ...
This is to represent that PHP is a CGI mode test run in php.ini find Gi.force_redirect put the front semicolon minus the value to 0 on the line
It's running again. This is another way to configure PHP run mode


One of the nineth steps of PHP optimization configuration
Make the Forum Faster PHP acceleration Setup PHP Acceleration: Turck MMCache Deployment implementation
Turck MMCache v2.4.7 for PHP v4.3.9
Introduction Description:
Put the Mmcache.dll file in the PHP extensions directory
Then modify the php.ini file:
Find
; Extension=php_zip.dll
After this sentence, add the following:
Zend_extension_ts= "C:phpextensionsmmcache.dll"
Mmcache.shm_size= "64"
Mmcache.cache_dir= "C:temp"
mmcache.enable= "1"
Mmcache.optimizer= "1"
Mmcache.check_mtime= "1"
mmcache.debug= "0"
Mmcache.filter= ""
mmcache.shm_max= "0"
Mmcache.shm_ttl= "0"
mmcache.shm_prune_period= "0"
mmcache.shm_only= "0"
mmcache.compress= "1"
Restart Apache or IIS if you add Zend Optimizer, it's the perfect php acceleration.ProgrammeRecommended to consider joining this support space (cache cache space as described above in the directory mmcache.cache_dir= "C:temp" will generate cached files) in exchange for speed
Special Note:
1, if your system has installed the Zend Accelerator, then the above configuration in the php.ini must be placed in front of the Zend, otherwise Apache can not start;
2, mmcache.shm_size= "64", where the 64 is the speed of the system used to do the cache memory, the default is 16M, according to your system memory adjustment;
3, mmcache.cache_dir= "/tmp", this is the accelerator working time to generate temporary files directory, please set up a temp folder under the C disk to store the cache file if the default directory space at the time of installation is small recommended adjustment; This directory produces not many files, if you visit a large number of sites themselves to monitor more than a few days to see.
4. For detailed description of the above configuration function, please refer to: http://turck-mmcache.sourceforge.net/index_old.html#config
Effect: Now the system has Zend and MMCache Accelerator, PHP execution speed is faster than the original, Zend optimization has been open to the maximum, the system is the most obvious is the BBS, andsoftware DownloadBackground program output HTML static page is very fast, and there are only zend when there are some pauses.

The tenth Step PHP optimization Configuration Two
Make the Forum Faster PHP acceleration Setup PHP acceleration: Zend Optimizer Optimized PHP program
Zend Optimizer V2.5.5 for Windows
File Size: 2941 KB
Software language: English
Operating Environment: WIN9X/NT/2000/XP
Zend Optimizer V2.5.5 for Windows software Description:
Zend Optimizer uses optimized code to improve the execution speed of PHP 4.0 applications. The principle of implementation is to optimize the code that is generated by running the compiler (Run-time Compiler) before it is finally executed. In general, PHP programs that use Zend Optimizer are 40% to 100% faster than unused. This means that visitors to the site can browse the Web more quickly, completing more transactions and creating better customer satisfaction. A faster response also means that you can save on hardware investment and enhance the services offered by the site. Therefore, the use of Zend Optimizer, is tantamount to improve the profitability of e-commerce. Zend Optimizer can bring a lot of benefits to PHP users, especially those who run the site. Running a PHP program quickly can significantly reduce the CPU load on the server and can reduce the response time by half, that is, the time between when a visitor clicks the link to the server to start reading the page.

Installing Zend Optimizer optimizing PHP programs
Zend Optimizer is by the PHP core engine "Zend"http://www.zend.comCreated by Zend Technology Inc. free PHP optimization software. According to Zend Company disclosed that using this software in some cases can at least improve performance by more than 30%! Now let's take a look at how to configure this set of software.
The installation of Zend optimizer is simple
1, run the installation files, first prompts you to select the installation directory, select a directory you like, click "Next".
2. The installation Wizard will ask you to select the currently used Web server (Apache, IIS, or other), select a good server and click "Next"
3. The installation Wizard prompts you to confirm the location of the php.ini (by default, c:windows) click "Next" and Prompt "backup php.ini to C:windowsphp.ini-optimizer-bak, When uninstalling the software, you can revert to the original php.ini) and click "Next".
4. The installation Wizard prompts "to restart the IIS service in order to continue Setup", click Yes, Setup starts restarting the IIS service, and the installer prompts "The IIS service has successfully restarted" Click OK, and then click Finish to complete the installation.
5, after the installation process will automatically according to your choice to modify PHP.ini help you start the engine. Let's introduce the configuration options for Zend Optimizer to help you maximize your custom and reasonable configuration.
[Zend]
Zend_optimizer.optimization_level=15
zend_extension_ts= "C:Program FilesZendlibZendExtensionManager.dll"
zend_extension_manager.optimizer_ts= "C:Program FilesZendlibOptimizer-2.5.5"
※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※
[Zend]
zend_optimizer.optimization_level=1023
Zend_optimizer.encoder_loader=0
zend_extension_ts= "C:Program FilesZendlibZendOptimizer.dll"
(The content that is seen in the online material may be different depending on the version.)
※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※
Now let's cover the implications of the above in these configuration files:
Zend_optimizer.optimization_level "= = Optimization degree, here defines how many optimization processes to start.
Zend_optimizer.encoder_loader "= = whether to allow processing of PHP files encrypted by Zend Encoder.
Zend_extension_ts the directory where the = = Optimizer resides.
Zend_extension_manager.optimizer_ts the = = Optimizer manages the directory.
Zend_optimizer.optimization_level detailed explanation of the optimization process
Here is the most important part, look carefully! Zend opt has a total of 10 optimization processes, the more theoretically the more performance the better. Of course, there is always a gap between theory and practice. The more the optimization process opens, the more the performance is consumed, and the 10 optimization processes of Zend opt are not the same, which means that the effect is not average. The highest value defined by the Zend Company (high mode) is 15, and here 15 refers to the 1-4 optimization process. Of course, many friends are not satisfied with this, after all, the highest only open 4 optimization process even half of the total is not. The corresponding numeric codes (values) for each optimization process are as follows:
Do not use 0 <= if this is not installed, but also save a bit of memory to say!
Optimization Process 1 (PASS1) 1
Optimization Process 2 (PASS2) 2
Optimization Process 3 (PASS3) 4
Optimization Process 4 (PASS4) 8
Optimization Process 5 (PASS5) 16
Optimization Process 6 (PASS6) 32
Optimization Process 7 (PASS7) 64
Optimization Process 8 (PASS8) 128
Optimization Process 9 (PASS9) 256
Optimization process (PASS10) 512
The way in which the optimization process is turned on is controlled by the addition of these numeric codes (values) and by the parameter values of the parameters. As in my config file Zend_optimizer.optimization_level = 1023, here's 1023 is the optimization process 1 to the optimization process 10 all the numerical code (value) is added to the sum, indicating the opening of all 10 optimization process. The Zend Company-defined high mode value mentioned earlier is 15,15, which also opens the optimization process 1-4.
Cryptographic code support Zend_optimizer.encoder_loader detailed explanation
For this parameter, I think most of the friends who have not seen the Zend Opt FAQ document do not know. This parameter is used to tell Zend opt to support code that has been Zend Encoder encrypted. By default, Zend Opt will support encrypted code. I recommend that you turn off this option if you do not use code that has been encrypted. This function involves the process of unpacking the anti-code, which can lead to the aggravation of the system load. My friend has developed the corresponding anti-compilation tool, which is expected to be launched after the Spring Festival.
The value of this parameter is only two 0 off, 1 is turned on. The default is 1 and the recommended setting is 0.
Module positioning zend_extension_ts, Zend_extension_manager.optimizer_ts without explanation, these parameters are Zend Optimizer related modules on the hard disk installation path.
6, how to know Zend Optimizer is running?
The answer is simple, just use PHP's function phpinfo () to detect the knowledge, as follows:
<?
Phpinfo ();
?>
The part of the displayed results about Zend Optimizer is like this:
Makes use of the Zend Scripting Language Engine:
Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies with Zend Extension Manager v1.0.3, Copyright (c) 2003-2004, by Zend Technologies with Zend Optimizer v2.5.3, Copyright (c) 1998-2004, by Zend Technologies
Indicates that Zend Optimizer for PHP has been optimized successfully.
To this WIN2003 iis6.0+php+asp+mysql optimization configuration is basically done.

The text is a little complicated, you must be patient.

This article from "Cock Silk life" blog, declined reprint!

WIN2003 Iis6.0+php+asp+mysql Optimized configuration

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.