网络营销电子商务研究中心  
How to buy the best prescription safety glasses in Canada? Let's study!
Go Back   网络营销电子商务研究中心 > 服务器与数据库 > 服务器环境搭建
User Name
Password
 
FAQ Members List Calendar Cheap Glasses

服务器环境搭建 Windows,Linux,IIS,Apache等服务器配置、安全维护以及PHP和MYSQL运行环境讨论。

Reply
 
Thread Tools Display Modes
  #1   IP: 222.184.47.213
Old 2009-09-11, 08:43 AM
yahoo yahoo is offline
高级会员
 
Join Date: 2006-04-05
Posts: 165
yahoo 正向着好的方向发展
Default How To: Run Apache HTTP Server and IIS on Windows Server 2003

I decided to install Apache HTTP Server on my dedicated Windows Server 2003 machine. I thought I would write a detailed article explaining the process for anyone else wanting to accomplish the same task. With just a few minor config changes you can easily have IIS and Apache running alongside each other on the same Windows server.

Step 1: Download Apache Server Win32 Binary (MSI Installer) from http://httpd.apache.org/download.cgi
Step 2: Install Apache with the default settings. Read the Apache Windows Help Documentation for more information.

In order to run IIS and Apache on a single server you need to specify what IP IIS and Apache will listen for port 80 on. You must have two different IP addresses available for use.

Step 3: For Apache: Edit the http.conf file to force Apache to run on a specific IP. Find the below text in your http.conf file. If you left the default install location unchanged the file will be located here:
C:\Program Files\Apache Software Foundation\Apache2.2\conf\httpd.conf

# Listen: Allows you to bind Apache to specific IP addresses and/or
# ports, instead of the default. See also the
# directive.
#
# Change this to Listen on specific IP addresses as shown below to
# prevent Apache from glomming onto all bound IP addresses.
#
#Listen 12.34.56.78:80
Listen 80

Change the line Listen 80 to:
Listen xxx.xxx.xxx.xxx:80

xxx.xxx.xxx.xxx is the private IP address you want Apache to listen on.

Step 4: For IIS: Install the Windows 2003 support tools.
Insert your Windows 2003 CD and open up the file:
\SUPPORT\TOOLS\SUPTOOLS.MSI
This will install additional support tools in “C:\Program Files\Support Tools”

Open up a command prompt (start menu > run > cmd)

At the command prompt, switch to the “C:\Program Files\Support Tools” folder (cd /d c:\program files\support tools)

Type the following command:

httpcfg set iplisten -i xxx.xxx.xxx.xxx

xxx.xxx.xxx.xxx is the private IP address you want IIS to listen on. This must be a different IP from the one used above for Apache.

Restart IIS and Apache for the changes to take affect. You might need to reboot depending on your server settings. Now IIS and Apache will run in harmony on the same Windows 2003 Server!

Troubleshooting Apache
If you run it to problems, the first place to start debugging is in your Apache error.log file. The file is located in your root Apache folder logs directory. The default install location is:
C:\Program Files\Apache Software Foundation\Apache2.2\logs\error.log

Common Errors
An attempt was made to access a socket in a way forbidden by its access permissions. : make_sock: could not bind to address xxx.xxx.xxx.xxx:80

You will receive this error in your error.log if IIS is still listening on the private IP that you set for Apache. If you followed my directions correctly an IIS reset should resolve this problem. If you are still having issues try rebooting your server.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Windows 2003的Web服务器配置方法 topvip 服务器环境搭建 0 2009-02-22 09:57 PM
Windows XP中IIS服务器的安装配置 smiling 服务器环境搭建 0 2009-02-17 04:27 PM
Windows XP中IIS服务器的安装配置 smiling 服务器环境搭建 0 2009-02-17 04:27 PM
怎样选择合适的服务器操作系统 sunshine 服务器环境搭建 0 2006-07-03 10:36 AM

Prescription-glasses.com offers prescription glasses online at discount prices.
All times are GMT +8. The time now is 10:54 AM.


Powered by vBulletin Version 3.8.7
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.