memcached服务报错: cannot read file data: Error 21

发布于 2022-09-07 04:22:55 字数 4271 浏览 25 评论 0

编译、安装memcached时提示找不到libevent库,于是通过软连接解决了找不到libevent库的问题。重新编译、安装memcached,启动时就报错,提示:cannot read file data: Error 21

[root@iZj6c0du2yloe6yh4292lkZ /]# /usr/local/bin/memcached -P /tmp/memcached.pid -d -m 20 -p 11211 -u root
/usr/local/bin/memcached: error while loading shared libraries: /lib64/libevent-2.1.so.6: cannot read file data: Error 21
[root@iZj6c0du2yloe6yh4292lkZ ~]# systemctl status memcached.service
● memcached.service - SYSV: The memcached daemon is a network memory cache service.
   Loaded: loaded (/etc/rc.d/init.d/memcached; bad; vendor preset: disabled)
   Active: failed (Result: exit-code) since Wed 2018-05-02 14:42:55 CST; 17s ago
     Docs: man:systemd-sysv-generator(8)
  Process: 14855 ExecStart=/etc/rc.d/init.d/memcached start (code=exited, status=1/FAILURE)

May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ systemd[1]: Starting SYSV: The memcached da....
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ systemd[1]: memcached.service: control proc...1
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ systemd[1]: Failed to start SYSV: The memca....
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ systemd[1]: Unit memcached.service entered ....
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ memcached[14855]: Starting memcached: chown:…ry
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ systemd[1]: memcached.service failed.
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ memcached[14855]: /bin/bash: memcached: comm...
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ memcached[14855]: [FAILED]
Hint: Some lines were ellipsized, use -l to show in full.
[root@iZj6c0du2yloe6yh4292lkZ ~]# journalctl -xe
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit session-968.scope has finished starting up.
-- 
-- The start-up result is done.
May 02 14:42:45 iZj6c0du2yloe6yh4292lkZ systemd-logind[491]: New session 968 of user root.
-- Subject: A new session 968 has been created for user root
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- Documentation: http://www.freedesktop.org/wiki/Software/systemd/multiseat
-- 
-- A new session with the ID 968 has been created for the user root.
-- 
-- The leading process of the session is 14829.
May 02 14:42:45 iZj6c0du2yloe6yh4292lkZ systemd[1]: Starting Session 968 of user root.
-- Subject: Unit session-968.scope has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit session-968.scope has begun starting up.
May 02 14:42:45 iZj6c0du2yloe6yh4292lkZ sshd[14829]: pam_unix(sshd:session): session opened for user root by (uid=0)
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ polkitd[478]: Registered Authentication Agent for unix-process:14849:48744428 (system bus name :1.1964 [/usr/bin/pkttyagent 
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ systemd[1]: Starting SYSV: The memcached daemon is a network memory cache service....
-- Subject: Unit memcached.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit memcached.service has begun starting up.
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ polkitd[478]: Unregistered Authentication Agent for unix-process:14849:48744428 (system bus name :1.1964, object path /org/f
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ systemd[1]: memcached.service: control process exited, code=exited status=1
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ systemd[1]: Failed to start SYSV: The memcached daemon is a network memory cache service..
-- Subject: Unit memcached.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit memcached.service has failed.
-- 
-- The result is failed.
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ systemd[1]: Unit memcached.service entered failed state.
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ memcached[14855]: Starting memcached: chown: cannot access ‘/var/run/memcached’: No such file or directory
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ systemd[1]: memcached.service failed.
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ memcached[14855]: /bin/bash: memcached: command not found
May 02 14:42:55 iZj6c0du2yloe6yh4292lkZ memcached[14855]: [FAILED]

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

寂寞花火° 2022-09-14 04:22:55

库不对啊。。重新编译安装下看看

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文