尝试在Windows上使用Apache 2.4.x设置负载平衡器。 错误:没有协议处理程序是有效的URL /path/。 如果您正在使用mod_proxy的DSO版本,请确保代理子模块包含在使用LoadModule的configuration中。 通过在docker服务器上部署的websocket代码访问webswing。 相同的configuration在Linux上工作。 configuration文件: ProxyPass /path balancer://cluster/path/ timeout=600 ProxyPassReverse /path balancer://cluster/path/ timeout=600 ProxyRequests Off ProxyTimeout 600 <Proxy "balancer://cluster"> Require valid-user AuthName "ClosedProxy" AuthType Basic Order deny,allow Allow from all Satisfy Any BalancerMember ws://server1 route=1 timeout=600 BalancerMember ws://server2 route=3 timeout=600 ProxySet stickysession=ROUTEID lbmethod=byrequests </Proxy>
我正在开发一个新的站点使用apache在一个centos 7.3框。 我有一个负载平衡器的设置。 一个服务器的网站完美的工作。 第二个网站或者超时,或者给我err_socket_not_connected。 configuration,权限等是相同的。 我可以导航到同一台服务器上的另一个站点。 我已经从第一个服务器的站点文件复制到第二个,试图禁用.htaccess,更改烫发等没有什么似乎工作。 没有任何httpd日志或var / log / messages
我们有一个CentOS 6.9服务器,有4个核心CPU和32GB RAM。 每天大概在同一时间,当我们终于必须重新启动服务器时,负载平均值从0.0逐渐变化到11 。 CPU :有时会尖峰,当像垃圾邮件,fail2ban这样的进程需要几秒钟的时间做些事情。 否则是1%左右。 一时之间php也占用了50%以上的CPU。 大部分时间空闲至less70%。 I/O :没有太多的I / O操作,但有时mysqld占用I / O的99.5% RAM :始终在可接受的范围内。 Bandwidth :在此期间没有太多的变化。 可接受的范围。 Disk Space :超过1TB的可用空间。 AV :冉clamd等工具,在wordpress安装中find了一些。 现在删除。 即使情况不佳,负载平均值不断增加,服务器变得太慢,我们不得不重新启动。 然后事情变得正常。 这不是一个cronjob问题,因为我也想过,因为有规律的例程,它必须是cron。 所以我使用了service crond stop并在延迟开始之前停止了几个小时。 滞后仍然发生。 在高负载平均时间内有很多进程正在运行。 有些是:多个mysqld , ../bin/suexec 501 501 php5 /bin/php ../bin/suexec 501 501 php5 , /bin/php , /fail2ban进程 我还从服务器收到许多邮件,说明System Load Alert 1 for […]
我创build了一个php脚本(使用XAMPP服务器和php_ldap.dll库)来更改AD用户密码(我正在使用Admin帐户进行身份validation): $server = "ldaps://xx.xx.xx.xx"; $dn = "dc=domainname,dc=com"; $port = 636; ldap_set_option(NULL, LDAP_OPT_DEBUG_LEVEL, 7); $con = ldap_connect($server, $port); ldap_set_option($con, LDAP_OPT_REFERRALS, 0); ldap_set_option($con, LDAP_OPT_PROTOCOL_VERSION, 3); $bind = ldap_bind($con, 'CN=Admin,CN=Users,DC=DOMIAN,DC=COM', 'password'); $user_search = ldap_search($con,$dn,'(sAMAccountName='.$user.')'); $user_get = ldap_get_entries($con, $user_search); $user_entry = ldap_first_entry($con, $user_search); $user_dn = ldap_get_dn($con, $user_entry); $user = 'validuser'; $oldPassword = 'oldpass'; $newPassword = 'newpass'; $encoded_newPassword = "{SHA}" […]
当试图迁移我的apache 2.2 web服务器到apache 2.4我无法转换这个特定的片段。 RewriteEngine On RewriteLogLevel 0 RewriteLog "logs/rewrite_80.log" Apache 2.4兼容的代码是什么?
我有一个运行httpd的centos服务器。 我在staging.example.com有一个网站,然后我有staging.example.com/blog或staging.example.com/wiki。 我正在博客部分工作。 这是一个WordPress的安装。 如果您转到staging.example.com/blog,则会转到blog / wp-admin / setup-config.php,如果您尝试inputstaging.example.com/blog/wp-admin,则会redirect到staging.example.com / wp-admin如果您按照链接安装wordpress,则转到staging.example.com/blog/wp-admin/core/core/core/core/core/core/core/core/core/core/core/core /core/core/core/core/core/core/core/core/core/install.php 我在/var/ww/html/example.com上提供了staging.example.com,博客位于/ var / www / html / blog wiki位于/ var / www / html / w 这是我的域特定的configuration: NameVirtualHost staging.example.com:80 <VirtualHost *:80> ServerName staging.example.com ServerAlias staging.example.com DocumentRoot /var/www/html/example.com RewriteEngine On RewriteCond %{HTTPS} off RewriteRule (.*) https://%{SERVER_NAME}$1 [R,L] </VirtualHost> NameVirtualHost staging.example.com:443 <VirtualHost *:443> ServerName staging.example.com […]
我在Debian上有Apache2,一些域名和多个子域名用于某些服务。 所以我试图为他们使用通配符虚拟主机: <VirtualHost *:8080> ServerName wildcard.domain.tld ServerAlias *.domain.tld UseCanonicalName Off VirtualDocumentRoot /home/domain.tld/public_html/service/%1/ DirectoryIndex index.php SetEnvIf HOST "^([^.]*)\.domain\.tld$" SERVICE=$1 <Directory /home/domain.tld/public_html/service/${SERVICE}/> Options FollowSymLinks MultiViews AllowOverride None RewriteEngine on RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ index.php [L] </Directory> </VirtualHost> 我正在使用mod_vhost_alias模块来使VirtualDocumentRoot与%1 (其中包含主机名的子域部分)以简单的使用。 但是我不能在Directory指令中使用它,所以我必须设置环境variables。 这是无用的,因为Directory没有抓住它,这就是问题所在! 如何将包含子域的variables传递给Directory伪指令? PS我很清楚这个问题是在重写,因为主页( / )正确加载VirtualDocumentRoot和DirectoryIndex指令都设置正确,但任何其他页面(比如说, subdomain1.domain.ltd/somepage )显示来自Apache的响应404 。 当我写my_service_name而不是${SERVICE} ,它适用于特定的服务。
当通过webform上传文件时,这些文件将由Apache进程拥有(例如,在Ubuntu上为www-data:www-data)。 我们希望用户拥有一个public_html目录。 问题是任何通过Web进程上传的文件都不能被该用户编辑/pipe理。 我怎样才能强制通过Web窗体上传的文件的所有权始终是用户:www – 数据其中用户是当然的Linux用户。 我注意到/ etc / apache2 / envvar中有两行我可以configuration这些行: export APACHE_RUN_USER=www-data export APACHE_RUN_GROUP=www-data 这是在一个file upload后产生的所有权来自哪里? 有什么我可以把APACHE_RUN_USER默认为通常find/用户/(用户)的用户? 还是有更好的方法来处理这个?
我的LAMP服务器最近冻结了,我重新启动了它。 我遇到了MySQL的一些内存问题之后,我可以确定表示我的交换文件在重新启动过程中被禁用。 我重新启用了我的交换文件,让MySQL停止崩溃,现在Apache似乎并没有为我的网站提供服务。 我的Apache错误日志里充满了像child process xxxx still did not exit, sending a SIGTERM这样的行child process xxxx still did not exit, sending a SIGTERM后面的child process xxxx still did not exit, sending a SIGKILL 。 其中每一个都有数以百计,所以看起来,Apache不断产生无法获取的subprocess。 但是,我不确定如何确定这些subprocess是什么或如何进一步排除故障。 有没有简单的方法来识别,并开始排除是什么原因导致他们冻结或失败,如果没有正确退出? 在我的虚拟机冻结之前,我没有遇到任何问题,我不得不重新启动和交换和MySQL混乱,所以如果有什么相关的,我应该检查,任何debugging技巧将不胜感激。 我已经几次重新启动了Apache服务,没有运气。
我在Ubuntu 16.04 Machine上遇到exception情况。 我安装了LAMP,ufw,fail2ban e现在作为一个DOS保护我安装了mod_evasive。 Mod_evasive似乎没有阻塞任何东西,不会logging任何东西,我在var / log / apache2 / error.logs中看到的唯一日志,当我重新加载页面足够快,以触发它: [evasive20:error] [pid 17849] [client *..***.179:9189] client denied by server configuration:.. 除此之外。 我经历了所有的步骤,创build了一个日志目录,授予权限,重新安装,尝试了所有的东西,但问题似乎并没有被固定在所有! 这是我目前的configuration: <IfModule mod_evasive20.c> DOSHashTableSize 3097 DOSPageCount 1 DOSSiteCount 5 DOSPageInterval 1 DOSSiteInterval 1 DOSBlockingPeriod 15 #DOSEmailNotify [email protected] #DOSSystemCommand "su – someuser -c '/sbin/… %s …'" DOSLogDir "/var/log/apache2/evasive.log" </IfModule> 任何想法? 编辑:我现在能够看到日志 – […]