当前第2页 返回上一页
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | <VirtualHost _default_:443>
SSLEngine on
ServerName localhost:443
SSLCertificateFile C: /Users/myPC/Downloads/httpd-2 .2.31-x86-r3 /Apache22/conf/ssl/server .crt
SSLCertificateKeyFile C: /Users/myPC/Downloads/httpd-2 .2.31-x86-r3 /Apache22/conf/ssl/server .key
DocumentRoot F:/
<FilesMatch "\.(cgi|shtml|phtml|php)$" >
SSLOptions +StdEnvVars
< /FilesMatch >
<Directory "/Apache22/cgi-bin" >
SSLOptions +StdEnvVars
< /Directory >
BrowserMatch "MSIE [2-5]" \
nokeepalive ssl-unclean- shutdown \
downgrade-1.0 force-response-1.0
CustomLog "C:/Users/myPC/Downloads/httpd-2.2.31-x86-r3/Apache22/logs/ssl_request.log" \
"%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
< /virtualhost >
|
主要改上文四处地方
在130行和152行还有另外两个VirtualHost,均需修改上述的四个选项
例:
130行
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | <VirtualHost *:443>
SSLEngine on
ServerName serverone.tld:443
SSLCertificateFile C: /Users/myPC/Downloads/httpd-2 .2.31-x86-r3 /Apache22/conf/ssl/serverone .crt
SSLCertificateKeyFile C: /Users/myPC/Downloads/httpd-2 .2.31-x86-r3 /Apache22/conf/ssl/serverone .key
DocumentRoot F:/
<FilesMatch "\.(cgi|shtml|phtml|php)$" >
SSLOptions +StdEnvVars
< /FilesMatch >
<Directory "/Apache22/cgi-bin" >
SSLOptions +StdEnvVars
< /Directory >
BrowserMatch "MSIE [2-5]" \
nokeepalive ssl-unclean- shutdown \
downgrade-1.0 force-response-1.0
CustomLog "C:/Users/myPC/Downloads/httpd-2.2.31-x86-r3/Apache22/logs/ssl_request.log" \
"%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b" env =HTTPS
< /virtualhost >
|
第152行
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | <VirtualHost *:443>
SSLEngine on
ServerName servertwo.tld:443
SSLCertificateFile C: /Users/myPC/Downloads/httpd-2 .2.31-x86-r3 /Apache22/conf/ssl/servertwo .crt
SSLCertificateKeyFile C: /Users/myPC/Downloads/httpd-2 .2.31-x86-r3 /Apache22/conf/ssl/servertwo .key
DocumentRoot F:/
<FilesMatch "\.(cgi|shtml|phtml|php)$" >
SSLOptions +StdEnvVars
< /FilesMatch >
<Directory "/Apache22/cgi-bin" >
SSLOptions +StdEnvVars
< /Directory >
BrowserMatch "MSIE [2-5]" \
nokeepalive ssl-unclean- shutdown \
downgrade-1.0 force-response-1.0
CustomLog "C:/Users/myPC/Downloads/httpd-2.2.31-x86-r3/Apache22/ssl_request.log" \
"%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
< /virtualhost >
|
上述的两个VirtualHost均需修改四处
这样,Apache就算配置完了,如果还有问题,可能还需配置./conf/extra/httpd-ssl.conf,配置方法和配置VirtualHost的相似
4,启动Apache HTTP Server
使用Windows命令行以管理员身份进入Apache程序的文件夹下的bin文件夹,输入httpd -k install,完成Apache服务的安装。
然后双击bin目录下的ApacheMonitor.exe,点击右边的start启动服务器,如果正常,如下图:

测试一下:

5,其它
卸载Apache HTTP Server:
管理员身份进入bin目录,使用httpd -k uninstall 移除服务
使用httpd -w -n "Apache2" -k start命令启动服务器 可以显示启动过程中的日志,便于分析错误。
以上就是Windows Apache2.4 VC9(ApacheHaus)安装教程详解的详细内容,更多文章请关注木庄网络博客!
返回前面的内容
相关阅读 >>
笔记本怎么更新windows系统
windows中桌面图标的排列方式可以通过什么设置
windows电脑如何设置环境变量
打开或关闭windows功能显示空白怎么办
windows xp属于什么操作系统
windows资源管理器关掉了怎么办
在windows中alt+tab键的作用是什么?
windows电脑安装不了软件怎么办
如何设置windows电脑前后音频同时输出
怎么关闭windows defender安全中心
更多相关阅读请进入《ApacheHaus》频道 >>
转载请注明出处:木庄网络博客 » Windows Apache2.4 VC9(ApacheHaus)安装教程详解