最近从 debian 8 更新到 debian 10,这意味着 Lighttpd 从 1.4.35 升级到 1.4.53,但自从升级以来,我一直在我们的数据库服务器上看到错误,指出原始客户端不再可访问。
我们的数据库服务器运行 Progress Openedge,我们使用 Progress 的消息服务,称为“Webspeed”。
我在网上查了一下,发现日志中提到了有问题的错误,但它与 IIS 4 升级到较新版本有关,其中较新版本的 CGI 超时时间较短。
我们将 mod_cgi 与 lighttpd 一起使用,因为它是唯一可以工作的东西(在这种情况下不能使用 FastCGI)。
在升级之前,我的 lighttpd 配置是 100% 工作的,升级之后,配置是一样的,但是它一直在抛出这些错误。
Webspeed 日志文件中的错误是: https ://knowledgebase.progress.com/articles/Article/P152
Lighttpd 配置:
server.modules = (
"mod_access",
"mod_accesslog",
"mod_alias",
"mod_compress",
"mod_expire",
"mod_redirect",
"mod_setenv",
)
server.upload-dirs = ( "/var/cache/lighttpd/uploads" )
server.errorlog = "/var/log/lighttpd/error.log"
server.pid-file = "/var/run/lighttpd.pid"
server.username = "www-data"
server.groupname = "www-data"
server.port = 80
server.document-root = "/var/www"
accesslog.filename = "/var/log/lighttpd/access.log"
# Keep-Alive stuff
# Was at 32 and 3
server.max-keep-alive-requests = 0
server.max-keep-alive-idle = 3
index-file.names = ( "index.php", "index.html", "index.lighttpd.html" )
url.access-deny = ( "~", ".inc" )
static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )
include_shell "/usr/share/lighttpd/use-ipv6.pl " + server.port
include_shell "/usr/share/lighttpd/create-mime.assign.pl"
include_shell "/usr/share/lighttpd/include-conf-enabled.pl"
include "myconf.conf"
myconf.conf 只是一般的东西加上一些假定的性能调整东西
server.modules += ( "mod_status" )
server.max-fds = 2048 #Normally 1024?
server.event-handler = "linux-sysepoll" #Normally level-triggered
server.use-noatime = "enable" #Normally disabled
$HTTP["remoteip"] == "nnn.nnn.nnn.0/24" {
status.status-url = "/server-status"
}
$HTTP["host"] == "www.example.com.au" {
server.document-root = "/var/www"
}
alias.url += ("/pse" => "/var/www/static/" )
alias.url += ("/assets" => "/var/www/assets/dist")
如前所述,与我运行 Debian 8 时相比,配置没有任何改变。
在网上看,关于 lighttpd 配置,我能找到的最好的方法是 server.max-read-idle 和 server.max-write-idle,但文档并没有真正详细介绍它们。
我可以对数据库服务器本身进行一些微调,但这只是将重试计数从默认值 10 更改为 0,这样如果客户端消失,Webspeed Messenger 就不会在放弃之前重试 10 次,无论如何都应该这样做,但也想要一个 lighttpd 修复。