Articles of apache 2.2

Apache Proxy – 代理服务器后端的SSLvalidation失败(客户端)

我正在运行configuration为反向代理的Apache 2.2.11。 代理的“前端”工作正常,后端也一样,直到我们在代理的后端(客户端)启用基于SSL证书的身份validation。 我的HTTPD conf文件包含: SSLProxyMachineCertificateFile /opt/apache/sfdc/myauth/myauth 根据文档,我已将密钥和证书组合到“myauth”文件中。 我正在使用相同的证书和密钥来保护代理正面的HTTPS连接。 这是串联的猫../server.key ../server.pem >> myauth 私钥没有密码保护。 我的Apache日志表明: [debug] ssl_engine_kernel.c(1526): Proxy client certificate callback: (obsucredhostname.com:8010) entered [debug] ssl_engine_kernel.c(1571): Proxy client certificate callback: (obsucredhostname.com:8010) no client certificate found!? 是否可以使用与用于保护前端SSL相同的证书密钥对? 我的前端由godaddys签署服务保证。 或者,我需要使用一个单独的和独特的一对?

.htaccess忽略,具体到EC2 – 不是通常的嫌疑人

我运行8-10个基于EC2的Web服务器,所以我的经验是很多小时,但仅限于CentOS; 特别是亚马逊的分销。 我正在使用yum安装Apache,因此获得了Amazon的默认编译Apache。 我想要使​​用mod_rewrite实现从非www(bare / root)域的规范redirect到www.domain.com的search引擎优化,但是我的.htaccess文件一致地忽略了。 我的故障排除步骤(下面概述)使我相信这是亚马逊构buildApache的特定事件。 testing用例 启动EC2实例,例如Amazon Linux AMI 2013.03.1 SSH到服务器 运行命令: $ sudo yum install httpd $ sudo apachectl start $ sudo vi /etc/httpd/conf/httpd.conf $ sudo apachectl restart $ sudo vi /var/www/html/.htaccess 在httpd.conf中,我更改了以下内容,在DOCROOT部分/范围中: AllowOverride All 在.htaccess中,补充说: (编辑,我后来添加了RewriteEngine On ) RewriteCond %{HTTP_HOST} ^domain\.com$ [NC] RewriteRule ^/(.*) http://www.domain.com/$1 [R=301,L] .htaccess上的权限是正确的,AFAI可以告诉: $ ls -al /var/www/html/.htaccess […]

如何在Apache SetEnv指令中将换行符放入环境variables中?

我想在一个环境variables中有一个换行符。 我试过了 SetEnv DI_collection_clients_list "client1 client2" 这导致了 Invalid command 'client2"', perhaps misspelled or defined by a module not included in the server configuration 当重新启动Apache。 我也试过了 SetEnv DI_collection_clients_list "client1\nclient2" 这导致variables当然有\n而不是换行符。

dynamicvariablesSetEnv vhost Ubuntu Apache2

如果这个问题已经被问到,我很抱歉。 我正在寻找一个解决scheme,使SetEnv使用%2variables。 这甚至可能吗? 我的虚拟主机: <VirtualHost *:80> ServerName dev.someuri.nl ServerAlias *.*.dev.someuri.nl VirtualDocumentRoot /home/%2/www/%1 LogLevel debug SetEnv DEVELOP_ENV dev SetEnv DEVELOP_NAME %2 </VirtualHost>

Apache mod_pagespeed就在* / forum /

是否可以在网站的一部分configurationmod_pagespeed? 我有一个site.com/forum/,并希望在/ forum / pages上使用mod_pagespeed。

PHP-FPM SuExecUserGroup不能正常工作

我已经安装了PHP,Apache和fastcgi_handler: emerge dev-lang/php www-apache/mod_fastcgi_handler 我设法通过更新/etc/apache2/modules.d/70_mod_php5.conf中的相关行 至: # AddHandler application/x-httpd-php .php .php5 .phtml # AddHandler application/x-httpd-php-source .phps AddHandler fcgi:/var/run/php-fpm.socket .php .php5 和/etc/conf.d/apache2来 APACHE2_OPTS="-D DEFAULT_VHOST -D INFO -D SSL -D SSL_DEFAULT_VHOST -D SUEXEC -D LANGUAGE -D PHP5 -D FASTCGI_HANDLER" 在我的文档根目录中,我有以下文件来validation安装: <?php echo '<pre>'; var_dump(exec('whoami')); var_dump(php_sapi_name()); 然后我有以下的虚拟主机: <IfDefine DEFAULT_VHOST> <VirtualHost localhost:80> ServerName local.testdomain.com ServerAlias local.testdomain.com SuExecUserGroup foobar foobar […]

为自己托pipe的CDNconfigurationhtaccess文件

我正在尝试为我的网站设置一个自己托pipe的cdn,但是我在htaccess文件中遇到了一些问题,并且无法使其工作。 目前,作为CDN的ftp服务器具有以下文件系统结构: / www/ www/htaccess www/index.html www/cdn/* incremental/* full/* 我的.htaccess现在看起来像这样: Options All -Indexes <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.html [L] </IfModule> #This snippet basically stops anyone viewing any file on your site that begins with "hta", this will protect it and make it somewhat safer. <Files […]

Nagiospipe理员没有权限

我使用yum在CentOS上安装并configuration了nagios 我在Web界面上看到“ It appears as though you do not have permission to view information for any of the hosts you requested… ”。 我已经创build了passwd文件,并检查了nagiosadmin在cgi.cfg文件中有权限。 但是,在Web界面上,即使我以nagiosadmin身份login,页面显示“ Logged in as $REDIRECT_REMOTE_USER=login”。 有任何想法吗? [编辑]我刚从源码编译无效[/编辑] [EDIT2] ScriptAlias /nagios/cgi-bin "/usr/local/nagios/sbin" <Directory "/usr/local/nagios/sbin"> # SSLRequireSSL Options ExecCGI AllowOverride None Order allow,deny Allow from all # Order deny,allow # Deny from all # […]

mod_page速度依赖问题

在我进一步去之前,mod pagespeed正在请求依赖关系。 我还有什么需要检查的吗? 我担心,因为我有一个apache2.2.22,但它的要求apache2.2-共同的。 dpkg: dependency problems prevent configuration of mod-pagespeed-beta:i386: mod-pagespeed-beta:i386 depends on apache2.2-common | apache2-api-20120211. mod-pagespeed-beta:i386 depends on libc6 (>= 2.4). mod-pagespeed-beta:i386 depends on libgcc1 (>= 1:4.1.1-21). mod-pagespeed-beta:i386 depends on libstdc++6 (>= 4.2.1-4). dpkg: error processing mod-pagespeed-beta:i386 (–install): dependency problems – leaving unconfigured Errors were encountered while processing: mod-pagespeed-beta:i386

Debian上的PHP5-FPM + Apache2 Wheezy:connect()与FastCGI失败

我在Debian Wheezy上有这个错误,我不明白我在想什么。 从php5-fpm的日志是确定的。 来自apache2日志的错误 : [error] (2)No such file or directory: FastCGI: failed to connect to server "/var/lib/apache2/fastcgi/php5.fastcgi": connect() failed [error] FastCGI: incomplete headers (0 bytes) received from server "/var/lib/apache2/fastcgi/php5.fastcgi" fastcgi.conf的内容: <IfModule mod_fastcgi.c> AddHandler fastcgi-script .fcgi #FastCgiWrapper /usr/lib/apache2/suexec FastCgiIpcDir /var/lib/apache2/fastcgi </IfModule> php5-fpm.conf的内容: <IfModule mod_fastcgi.c> Alias /php5.fastcgi /var/lib/apache2/fastcgi/php5.fastcgi AddHandler php-script .php FastCGIExternalServer /var/lib/apache2/fastcgi/php5.fastcgi -socket /var/run/php5-fpm.sock -idle-timeout […]