首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Apache LockFile问题

Apache LockFile问题
EN

Stack Overflow用户
提问于 2020-06-23 13:33:03
回答 1查看 759关注 0票数 0

我正在尝试从Debian7上的Apache2.2迁移到CentOS 7上的Apache2.4。当httpd启动时,它无法启动,如下所示。

代码语言:javascript
复制
root# journalctl -xe
Jun 23 14:26:04 ww-test httpd[17716]: AH00526: Syntax error on line 47 of /etc/httpd/conf/httpd.conf:
Jun 23 14:26:04 ww-test httpd[17716]: Invalid command 'LockFile', perhaps misspelled or defined by a module not included in the server configuration
Jun 23 14:26:04 ww-test systemd[1]: httpd.service: main process exited, code=exited, status=1/FAILURE
Jun 23 14:26:04 ww-test kill[17718]: kill: cannot find process ""
Jun 23 14:26:04 ww-test systemd[1]: httpd.service: control process exited, code=exited status=1
Jun 23 14:26:04 ww-test systemd[1]: Failed to start The Apache HTTP Server.
代码语言:javascript
复制
vi httpd.conf
45 # The accept serialization lock file MUST BE STORED ON A LOCAL DISK.
46 #
47 LockFile ${APACHE_LOCK_DIR}/accept.lock
48

我安装了相关的软件包,如下所示,尽管我不确定它是否是正确的。

代码语言:javascript
复制
============================================================================================================================================================================================
 Package                                   Arch                              Version                                   Repository                                                      Size
============================================================================================================================================================================================
Installing:
 lockfile-progs                            x86_64                            0.1.15-7.el7                              /lockfile-progs-0.1.15-7.el7.x86_64                             50 k
Installing for dependencies:
 liblockfile                               x86_64                            1.08-17.el7                               base                                                            21 k

Transaction Summary

感谢您的阅读。

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2020-06-23 13:54:34

替换此行:

代码语言:javascript
复制
LockFile ${APACHE_LOCK_DIR}/accept.lock

至:

代码语言:javascript
复制
Mutex file:/var/httpd/locks default

指令AcceptMutex、LockFile、RewriteLock、SSLMutex、SSLStaplingMutex和WatchdogMutexPath已被替换为单个互斥指令。您需要评估这些已删除指令在2.2配置中的任何用法,以确定它们是可以直接删除,还是需要使用互斥锁替换

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/62527948

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档