mirror of
https://github.com/fatedier/frp.git
synced 2026-05-15 08:05:49 -06:00
[GH-ISSUE #2053] 0.34.1版本,logs.BeeLogger.SetLogger: open ./frps.log: permission denied #1635
Labels
No labels
In Progress
WIP
WaitingForInfo
bug
doc
duplicate
easy
enhancement
future
help wanted
invalid
lifecycle/stale
need-issue-template
need-usage-help
no plan
proposal
pull-request
question
todo
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/frp#1635
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @kiok1210 on GitHub (Nov 5, 2020).
Original GitHub issue: https://github.com/fatedier/frp/issues/2053
服务启动时报错
[root@mail frp_0.34.1_linux_amd64]# systemctl status frps
● frps.service - Frp Server Service
Loaded: loaded (/etc/systemd/system/frps.service; disabled; vendor preset: disabled)
Active: active (running) since Thu 2020-11-05 16:54:51 CST; 5s ago
Main PID: 22082 (frps)
Tasks: 5
Memory: 9.9M
CGroup: /system.slice/frps.service
└─22082 /opt/frp/frp_0.34.1_linux_amd64/frps -c /opt/frp/frp_0.34.1_linux_amd64/frps.ini
Nov 05 16:54:51 mail.linuxido.com systemd[1]: Started Frp Server Service.
Nov 05 16:54:51 mail.linuxido.com frps[22082]: logs.BeeLogger.SetLogger: open ./frps.log: permission denied
@Becods commented on GitHub (Nov 5, 2020):
权限问题,请检查用户是否有该目录的读写权限
@kiok1210 commented on GitHub (Nov 5, 2020):
一、
使用了systemd的方式启动的
systemctl restart frps
二、尝试了三种权限
1、root
2、frps
useradd frps
chown -R frps:frps /opt/frp/frp_0.34.1_linux_amd64
3、chmod 777 frp_0.34.1_linux_amd64
还是同样的问题
三、如果将frps.ini中log路径换成绝对路径,则会变为
No such file or directory
@kiok1210 commented on GitHub (Nov 5, 2020):
已解决,可以关闭了,没有更换user
注释掉指定user
或者指定user为frps
[Unit]
Description=Frp Server Service
After=network.target
[Service]
Type=simple
#User=nobody
Restart=on-failure
RestartSec=5s
ExecStart=/opt/frp/frp_0.34.1_linux_amd64/frps -c /opt/frp/frp_0.34.1_linux_amd64/frps.ini
[Install]
WantedBy=multi-user.target