我们有多个子域,每个都有自己的httpd.conf中的虚拟主机条目,以及ssl.conf中的支持https的那些子域。 我们的主要www子域有一个与之相关的GoDaddy证书。 我现在在我们的开发环境(“api.bulbstorm.com”)中configuration的子域有一个ssl.conf虚拟主机条目,如下所示: <VirtualHost 172.16.247.153:443> DocumentRoot "/var/www/api" ServerName api.bulbstorm.com:443 ErrorLog logs/api-error_log CustomLog logs/api-access_log common LogLevel warn SSLEngine on SSLProtocol all -SSLv2 SSLCertificateFile /var/www/certs/api/server.crt SSLCertificateKeyFile /var/www/certs/api/server.key <Files ~ "\.(cgi|shtml|phtml|php3?)$"> SSLOptions +StdEnvVars </Files> <Directory "/var/www/cgi-bin"> SSLOptions +StdEnvVars </Directory> <Directory "/var/www/api"> Options +FollowSymLinks RewriteEngine On AllowOverride All Order allow,deny Allow from all </Directory> php_value include_path "/var/www/inc" SetEnvIf User-Agent […]
我通过它的Windows安装程序安装了Apache,然后安装了PHP和MySQL。 WordPress的工作正常,这意味着所需的基本设置工作正常。 但不知何故mod_rewriting是行不通的,即使我已经从httpd.conf取消了LoadModule ….. mod_rewrite注释。 每当我去我的localhost一些固定链接,我只是得到一个404(基于浏览器,而不是基于WordPress)。 请build议我需要做的改变。
好吧,在这里! 即时运行的Linux(cent os),我的httpd.conf文件中有“LoadModule rewrite_module modules / mod_rewrite.so”启用! “mod_rewrite.so”位于modules文件夹中。 这里是一些代码 HTTPD.CONF: <Directory /> Options All AllowOverride All </Directory> <Directory "/var/www/html"> Options Indexes All AllowOverride All Order allow,deny Allow from all </Directory> VHost文件: # owned by VirtualHost NameVirtualHost 192.168.10.200:80 # FrontPage needs the following four things to be here # otherwise all the vhosts need to go […]
Apache的segfaults,当我们有php 5.3开启register_globals。 我知道我们不应该这样做,现在我们已经把它closures了,但是我们的一些非常古老的代码需要它。 任何人有什么提示/试图解决这个问题? 谢谢
我一直这样做: chown apache2:apache2 / var / www / -vR chmod 555 / var / www / -vR chmod 755 / var / www / a / special / dir / which / needs / write / permissions / -vR 或者而不是2,3只需将权限设置为755 最近我才知道把apache设置成用户不安全,怎么办? 还有什么select? 什么是增加Web服务器(Apache)安全性的其他良好做法?
我想将Apache 2设置为使用基于名称的虚拟主机的反向代理来决定如何将请求路由到后端服务器。 很简单。 问题是这些后端服务器可能会以dynamic方式添加和删除。 我的第一个想法是以编程方式重新编写一个Apacheconfiguration文件,并在每次后端服务器启动或closures时调用apachectl graceful 。 这似乎不是正确的解决scheme。 什么是更好的方法来完成这个? 我需要能够适当地将名称的处理转移到不同的后端服务器。 例如,后端服务器A可能正在处理对example.com的请求。 监视过程可能会决定后端服务器A是陈旧的(内存使用量过多,有新版本的服务器代码来处理example.com等)。 监控进程启动Backend-Server-B,后者将很快处理对example.com的请求。 Apache应该将任何对example.com的新请求指向Backend-Server-B,但是允许Backend-Server-A当前正在处理的任何待处理请求在我的监控进程closuresBackend-Server-A之前完成。 ( 注 :我最初发布在堆栈溢出。)
我有一个Apache作为HTTP服务器运行,也是由同一个Apache机器交付的SVN服务器。 configuration类似的东西 <Location /repos> DAV svn SVNParentPath /srv/repos </Location> 我如何防止Apachelogging所有SVN“PROPFIND”和“OPTIONS”访问请求?
我们目前的设置有使用mod_php由Apache服务的PHP脚本。 我们刚刚开发了一个需要通过CGI(它使用pcntl来分离一些进程)而不是mod_php的新脚本。 有人可以给我一个这样的例子configuration? 理想情况下,除了这个之外,我们可以通过mod_php运行所有的脚本,但是如果我们必须全部运行它们,那么我可以忍受这一点。 服务器的详细信息: Apache / 2.2.11(Ubuntu)PHP / 5.2.6-3ubuntu4与Suhosin-Patch 当前的configuration与它们来的一样简单( / etc / apache2 / sites-available / default ): <VirtualHost *:80> ServerAdmin webmaster@localhost DocumentRoot /var/www <Directory /> Options FollowSymLinks </Directory> <Directory /var/www/> Options FollowSymLinks MultiViews Order allow,deny allow from all </Directory> ErrorLog /var/log/apache2/error.log LogLevel warn CustomLog /var/log/apache2/access.log combined </VirtualHost> 先谢谢您的帮助。
我使用AuthType Basic通过SSL安全连接validationapache2服务器的客户端。 我想这些是安全的,因为用户名和密码在发送到服务器之前被encryption。 是对的吗?
我必须用Apache 2pipe理一个Web服务器来提供一些不同的网站 – 每个站点都有自己的域名。 服务器有一个IP地址,例如:78.9.10.11。 对于每个站点,VirtualHost都是这样定义的: <VirtualHost *:80> ServerName mydomain.com ServerAlias *.mydomain.com …. </VirtualHost> 它工作正常,但有一个configuration问题:如果有人试图通过其IP地址( http://78.9.10.11 )访问服务器,第一个VirtualHost交付 – 我不想要的。 相反,访问应该被阻止,或者应该提供一个特殊的网站(来呈现某种错误信息)。 服务器只能按域名交付网站。 我如何定义一个用于IP访问的VirtualHost?