启动 stunnel 时 pid 文件错误

启动 stunnel 时 pid 文件错误

我正在尝试stunnel以客户端身份启动我的 mac 操作系统。但我无法让它运行,因为我在隧道的日志文件中注意到了这个报告的问题:

2015.10.10 16:10:24 LOG5[ui]: stunnel 5.23 on x86_64-apple-darwin14.5.0 platform
2015.10.10 16:10:24 LOG5[ui]: Compiled with OpenSSL 0.9.8zd 8 Jan 2015
2015.10.10 16:10:24 LOG5[ui]: Running  with OpenSSL 0.9.8za 5 Jun 2014
2015.10.10 16:10:24 LOG5[ui]: Update OpenSSL shared libraries or rebuild stunnel
2015.10.10 16:10:24 LOG5[ui]: Threading:PTHREAD Sockets:POLL,IPv6 TLS:ENGINE,OCSP
2015.10.10 16:10:24 LOG5[ui]: Reading configuration from file /usr/local/etc/stunnel/kafka-client.conf
2015.10.10 16:10:24 LOG5[ui]: UTF-8 byte order mark not detected
2015.10.10 16:10:24 LOG4[ui]: Service [kafka-producer1] needs authentication to prevent MITM attacks
2015.10.10 16:10:24 LOG4[ui]: Service [kafka-producer2] needs authentication to prevent MITM attacks
2015.10.10 16:10:24 LOG4[ui]: Service [kafka-producer3] needs authentication to prevent MITM attacks
2015.10.10 16:10:24 LOG4[ui]: Service [kafka-producer4] needs authentication to prevent MITM attacks
2015.10.10 16:10:24 LOG4[ui]: Service [zk-consumer1] needs authentication to prevent MITM attacks
2015.10.10 16:10:24 LOG4[ui]: Service [zk-consumer2] needs authentication to prevent MITM attacks
2015.10.10 16:10:24 LOG5[ui]: Configuration successful
2015.10.10 16:10:24 LOG3[main]: Cannot create pid file /usr/local/var/run/stunnel.pid
2015.10.10 16:10:24 LOG3[main]: create: No such file or directory (2)

在我的 stunnel 的 conf 文件中,我将 pid 文件配置为pid = /usr/local/var/run/stunnel.pid

究竟出了什么问题?为什么无法创建日志中报告的引用的 pid 文件?

任何答案表示赞赏。谢谢。

答案1

基本上,错误很简单:只是创建目录usr/local/var/run/

相关内容