[GH-ISSUE #1125] cli设置frps的log_file无效,日志会打印在屏幕中 #881

Closed
opened 2026-05-05 12:33:34 -06:00 by gitea-mirror · 0 comments
Owner

Originally created by @status301 on GitHub (Mar 11, 2019).
Original GitHub issue: https://github.com/fatedier/frp/issues/1125

Issue is only used for submiting bug report and documents typo. If there are same issues or answers can be found in documents, we will close it directly.
(为了节约时间,提高处理问题的效率,不按照格式填写的 issue 将会直接关闭。)

Use the commands below to provide key information from your environment:
You do NOT have to include this information if this is a FEATURE REQUEST

What version of frp are you using (./frpc -v or ./frps -v)?
[root@hk frp_0.25.0_linux_amd64]# ./frps -v
0.25.0
[root@hk frp_0.25.0_linux_amd64]#

What operating system and processor architecture are you using (go env)?
[root@hk frp_0.25.0_linux_amd64]# go env
GOARCH="amd64"
GOHOSTARCH="amd64"
GOTOOLDIR="/usr/lib/golang/pkg/tool/linux_amd64"

Configures you used:
cli:
[root@hk frp_0.25.0_linux_amd64]# ./frps --bind_port 65401 --kcp_bind_port 65402 --vhost_http_port 65403 --vhost_https_port 65404 --bind_udp_port 65405 --token Frp-Token --dashboard_port 65406 --dashboard_user Frp-Token --dashboard_pwd Frp-Token --log_file ./frps.log --log_level trace --log_max_days 3

Steps to reproduce the issue:

  1. ./frps --bind_port 65401 --kcp_bind_port 65402 --vhost_http_port 65403 --vhost_https_port 65404 --bind_udp_port 65405 --token Frp-Token --dashboard_port 65406 --dashboard_user Frp-Token --dashboard_pwd Frp-Token --log_file ./frps.log --log_level trace --log_max_days 3

Describe the results you received:
没有将日志存入frps.log,而是打印在屏幕上的
[root@hk frp_0.25.0_linux_amd64]# ./frps --bind_port 65401 --kcp_bind_port 65402 --vhost_http_port 65403 --vhost_https_port 65404 --bind_udp_port 65405 --token Frp-Token --dashboard_port 65406 --dashboard_user Frp-Token --dashboard_pwd Frp-Token --log_file ./frps.log --log_level trace --log_max_days 3
2019/03/11 23:08:05 [I] [service.go:136] frps tcp listen on 0.0.0.0:65401
2019/03/11 23:08:05 [I] [service.go:145] frps kcp listen on udp 0.0.0.0:65402
2019/03/11 23:08:05 [I] [service.go:178] http service listen on 0.0.0.0:65403
2019/03/11 23:08:05 [I] [service.go:199] https service listen on 0.0.0.0:65404
2019/03/11 23:08:05 [I] [service.go:218] nat hole udp service listen on 0.0.0.0:65405
2019/03/11 23:08:05 [I] [service.go:229] Dashboard listen on 0.0.0.0:65406
2019/03/11 23:08:05 [I] [root.go:204] Start frps success
^C
[root@hk frp_0.25.0_linux_amd64]

Describe the results you expected:
--log_file ./frps.log --log_level trace --log_max_days 3

Additional information you deem important (e.g. issue happens only occasionally):
可以使用 >>frp.log

Can you point out what caused this issue (optional)

Originally created by @status301 on GitHub (Mar 11, 2019). Original GitHub issue: https://github.com/fatedier/frp/issues/1125 Issue is only used for submiting bug report and documents typo. If there are same issues or answers can be found in documents, we will close it directly. (为了节约时间,提高处理问题的效率,不按照格式填写的 issue 将会直接关闭。) Use the commands below to provide key information from your environment: You do NOT have to include this information if this is a FEATURE REQUEST **What version of frp are you using (./frpc -v or ./frps -v)?** [root@hk frp_0.25.0_linux_amd64]# ./frps -v 0.25.0 [root@hk frp_0.25.0_linux_amd64]# **What operating system and processor architecture are you using (`go env`)?** [root@hk frp_0.25.0_linux_amd64]# go env GOARCH="amd64" GOHOSTARCH="amd64" GOTOOLDIR="/usr/lib/golang/pkg/tool/linux_amd64" **Configures you used:** cli: [root@hk frp_0.25.0_linux_amd64]# ./frps --bind_port 65401 --kcp_bind_port 65402 --vhost_http_port 65403 --vhost_https_port 65404 --bind_udp_port 65405 --token Frp-Token --dashboard_port 65406 --dashboard_user Frp-Token --dashboard_pwd Frp-Token --log_file ./frps.log --log_level trace --log_max_days 3 **Steps to reproduce the issue:** 1. ./frps --bind_port 65401 --kcp_bind_port 65402 --vhost_http_port 65403 --vhost_https_port 65404 --bind_udp_port 65405 --token Frp-Token --dashboard_port 65406 --dashboard_user Frp-Token --dashboard_pwd Frp-Token --log_file ./frps.log --log_level trace --log_max_days 3 **Describe the results you received:** 没有将日志存入frps.log,而是打印在屏幕上的 [root@hk frp_0.25.0_linux_amd64]# ./frps --bind_port 65401 --kcp_bind_port 65402 --vhost_http_port 65403 --vhost_https_port 65404 --bind_udp_port 65405 --token Frp-Token --dashboard_port 65406 --dashboard_user Frp-Token --dashboard_pwd Frp-Token --log_file ./frps.log --log_level trace --log_max_days 3 2019/03/11 23:08:05 [I] [service.go:136] frps tcp listen on 0.0.0.0:65401 2019/03/11 23:08:05 [I] [service.go:145] frps kcp listen on udp 0.0.0.0:65402 2019/03/11 23:08:05 [I] [service.go:178] http service listen on 0.0.0.0:65403 2019/03/11 23:08:05 [I] [service.go:199] https service listen on 0.0.0.0:65404 2019/03/11 23:08:05 [I] [service.go:218] nat hole udp service listen on 0.0.0.0:65405 2019/03/11 23:08:05 [I] [service.go:229] Dashboard listen on 0.0.0.0:65406 2019/03/11 23:08:05 [I] [root.go:204] Start frps success ^C [root@hk frp_0.25.0_linux_amd64] **Describe the results you expected:** --log_file ./frps.log --log_level trace --log_max_days 3 **Additional information you deem important (e.g. issue happens only occasionally):** 可以使用 >>frp.log **Can you point out what caused this issue (optional)**
gitea-mirror 2026-05-05 12:33:34 -06:00
  • closed this issue
  • added the
    bug
    label
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/frp#881
No description provided.