我每天都会在我的 apache 错误日志中收到许多这样的错误:
[错误] [客户端 127.0.0.1] 脚本 '/var/www/html/wp-cron.php' 未找到或无法统计
我想知道它是否与我的 httpd.conf 有关系,因为我的 DocumentRoot 设置为“/var/www/html”,但我的 WordPress 站点位于名为 httpdocs 的顶级目录中,而不是 html。wp-cron.php 存在,但它在 httpdocs 中,而不是 html,并且没有 html 目录。VPS 和 IP 上有多个 WordPress 站点和域。
日志中没有其他类似的错误,WordPress 似乎运行良好。但我想修复这些错误,因为它对服务器造成了一些额外的负担。
有没有办法在 httpd.conf 中添加重定向或别名,以便可以找到 wp-cron.php?或者这是一个不同的解决方案?
编辑: 找到答案;问题是主机文件条目:VPS 上多个域的主机文件条目?
使用模拟 6 进行网络统计,我很惊讶地看到超过 54 天的 404 超过一百万。我正确看待这个吗?这是 404 与“200 OK”页面浏览量的异常比率吗?我在实际 URL 列表中没有看到任何 404;损坏的 URL 列表在哪里?该站点是 unix/apache 上的 html、WordPress 和 asp 页面的组合,如果这很重要的话。
Requests Status Codes
6548392 200 OK
807 206 Partial content
1830136 301 Document moved permanently
61795 302 Document found elsewhere
3091342 304 Not modified since last retrieval
3042 400 Bad request
49012 403 Access forbidden
1043694 404 Document not found
2936 500 Internal server error
411 503 Service temporarily unavailable
Run Code Online (Sandbox Code Playgroud)
一般统计:
Successful requests: 9,640,541
Average successful requests per day: …
Run Code Online (Sandbox Code Playgroud) 在尝试通过 SSH 从 OS X 连接到带有 WHM 控制面板的 CentOS VPS 时,我不断收到“连接被拒绝”。WHM 中启用了 SSH,并且我已经生成了 SSH 密钥。我还尝试了关闭防火墙的 SSH 一分钟,但没有运气。
仔细阅读其他问题后,我跑了ssh -vv root@xx.xxx.xx.xx
,这给了我:
debug2: ssh_connect: needpriv 0
debug1: connect to address xx.xxx.xx.xx port 22: Connection refused
Run Code Online (Sandbox Code Playgroud)
跑步 nc -zvw 2 xx.xxx.xx.xx 22
给了我
nc: connect to xx.xxx.xx.xx port 22 (tcp) failed: Connection refused
Run Code Online (Sandbox Code Playgroud)
这些到底是什么意思?我还能尝试什么?
我正在 FreeBSD 9.2 服务器上工作,并已运行mysqltuner.pl
以检查 MySQL 的内存和缓存需求。现在我需要向my.cnf
FreeBSD添加一个文件,以便它使用该auto cnf
文件而不是该文件。
我可以这样复制my-default.cnf
:
cp /usr/local/share/mysql/my-default.cnf /usr/local/etc/my.cnf
然后my.cnf
将加载。
该my-default.cnf
文件显示了这些值(将延续到my.cnf
):
# Remove leading # and set to the amount of RAM for the most important data
# cache in MySQL. Start at 70% of total RAM for dedicated server, else 10%.
# innodb_buffer_pool_size = 128M
# *the above innodb line I can set*
# *But where do I get the values below?*
# …
Run Code Online (Sandbox Code Playgroud)