谁拥有 /var/log/tor 日志?无法启动

Who owns /var/log/tor logs? Can`t get tor to start

我编译并安装了 tor(在 raspbian 上)。 我现在要做的就是用 tor.

开始 tor

但我得到的只是

Mar 15 16:51:36.713 [notice] Tor v0.2.7.6 running on Linux with Libevent 2.0.21-stable, OpenSSL 1.0.1k and Zlib 1.2.8.
Mar 15 16:51:36.716 [notice] Tor can't help you if you use it wrong! Learn how to be safe at https://www.torproject.org/download/download#warning
Mar 15 16:51:36.718 [notice] Read configuration file "/usr/local/etc/tor/torrc".
Mar 15 16:51:36.757 [notice] Based on detected system memory, MaxMemInQueues is set to 278 MB. You can override this by setting MaxMemInQueues by hand.
Mar 15 16:51:36.774 [notice] Opening OR listener on 0.0.0.0:443
Mar 15 16:51:36.778 [notice] Opening Directory listener on 0.0.0.0:80
Mar 15 16:51:36.000 [warn] Couldn't open file for 'Log notice file /var/log/tor/notices.log': Permission denied
Mar 15 16:51:36.000 [notice] Closing partially-constructed OR listener on 0.0.0.0:443
Mar 15 16:51:36.000 [notice] Closing partially-constructed Directory listener on 0.0.0.0:80
Mar 15 16:51:36.000 [warn] Failed to parse/validate config: Failed to init Log options. See logs for details.
Mar 15 16:51:36.000 [err] Reading config failed--see warnings above.

使用 sudo tor 没有问题,它 运行 很顺利,但通常我没有 运行 tor 作为 root。 现在我不知道如何处理日志的所有权。 当我执行 sudo chmod 777 -R /var/log/tor 或 运行s 但安全性较低时。

root@Debian:/var/log# ls -al /usr/local/bin/tor
-rwxr-xr-x 1 debian-tor adm 2091616 Mär 15 14:58 /usr/local/bin/tor

谢谢!

成功! :-D 我用 chmod 660 * 更改了日志的权限。 这是结果:

-rw-rw---- 1 debian-tor debian-tor 25124 Mär 15 20:49 notices.log.

和日志文件夹 /var/log/tor

drwxr-s--- 2 debian-tor debian-tor 4096 Mär 15 06:25 tor

是这样的。

感谢 drew010!

但有一个问题是给我的。是没问题还是权利风险太大?