[GH-ISSUE #4465] [E] [service.go:273] token in login doesn't match token from configuration #3531

Closed
opened 2026-05-05 14:16:08 -06:00 by gitea-mirror · 2 comments
Owner

Originally created by @shangjianan2 on GitHub (Oct 2, 2024).
Original GitHub issue: https://github.com/fatedier/frp/issues/4465

Bug Description

我按照https://cloud.tencent.com/developer/article/1837482 这个教程部署frp,运行客户端时报错信息如下

[root@192 frp_0.33.0_linux_amd64]# ./frpc -c ./frpc.ini
2024/10/02 08:13:10 [E] [service.go:273] token in login doesn't match token from configuration
2024/10/02 08:13:10 [W] [service.go:101] login to server failed: token in login doesn't match token from configuration
token in login doesn't match token from configuration

frpc Version

0.33.0

frps Version

0.33.0

System Architecture

centos

Configurations

客户端配置

[root@192 frp_0.33.0_linux_amd64]# cat frpc.ini 
[common]
server_addr = 8.152.2.188
server_port = 7000
token = 52010

[ssh]
type = tcp
local_ip = 127.0.0.1
local_port = 22
remote_port = 6000

服务端配置

[root@iZ2zeabyd4gtcdve3j31zdZ frp_0.33.0_linux_amd64]# cat /etc/frp/frps.ini
[common]
bind_port = 7000
# 授权码,请改成更复杂的
token = 52010  # 这个token之后在客户端会用到

# frp管理后台端口,请按自己需求更改
dashboard_port = 7500
# frp管理后台用户名和密码,请改成自己的
dashboard_user = admin
dashboard_pwd = admin
enable_prometheus = true

# frp日志配置
log_file = /var/log/frps.log
log_level = info
log_max_days = 3
You have mail in /var/spool/mail/root

Logs

服务端报错信息

[root@iZ2zeabyd4gtcdve3j31zdZ frp_0.33.0_linux_amd64]# cat /var/log/frps.log 
2024/10/02 08:06:25 [I] [service.go:178] frps tcp listen on 0.0.0.0:7000
2024/10/02 08:06:25 [I] [service.go:277] Dashboard listen on 0.0.0.0:7500
2024/10/02 08:06:25 [I] [root.go:209] start frps success
2024/10/02 08:07:07 [I] [service.go:432] [817a1c0113e6bbdd] client login info: ip [120.244.197.58:35816] version [0.33.0] hostname [] os [linux] arch [amd64]
2024/10/02 08:07:07 [W] [service.go:334] register control error: token in login doesn't match token from configuration
2024/10/02 08:09:11 [I] [service.go:432] [f6e183c722f9b76f] client login info: ip [120.244.197.58:35349] version [0.33.0] hostname [] os [linux] arch [amd64]
2024/10/02 08:09:11 [W] [service.go:334] register control error: token in login doesn't match token from configuration
2024/10/02 08:13:10 [I] [service.go:432] [71fd90e23acb0b18] client login info: ip [120.244.197.58:35418] version [0.33.0] hostname [] os [linux] arch [amd64]
2024/10/02 08:13:10 [W] [service.go:334] register control error: token in login doesn't match token from configuration
2024/10/02 08:14:22 [I] [service.go:432] [51b905b601d6d968] client login info: ip [120.244.197.58:35448] version [0.33.0] hostname [] os [linux] arch [amd64]
20

Steps to reproduce

  1. 我查看了https://github.com/fatedier/frp/issues/3675 这个问题,感觉和我的问题不相符。我所用的这个版本的配置文件字段不是驼峰格式,所以没有尝试此修改
  2. 按照https://github.com/fatedier/frp/issues/2099 我尝试用./frpc -c $PWD/frpc.ini启动,依旧有问题
[root@192 frp_0.33.0_linux_amd64]# ./frpc -c $PWD/frpc.ini
2024/10/02 08:25:51 [E] [service.go:273] token in login doesn't match token from configuration
2024/10/02 08:25:51 [W] [service.go:101] login to server failed: token in login doesn't match token from configuration
token in login doesn't match token from configuration

  1. 按照https://github.com/fatedier/frp/issues/3899 我注释掉common这行,并将服务端和客户端的token都加上了双引号,依旧相同错误
    ...

Affected area

  • Docs
  • Installation
  • Performance and Scalability
  • Security
  • User Experience
  • Test and Release
  • Developer Infrastructure
  • Client Plugin
  • Server Plugin
  • Extensions
  • Others
Originally created by @shangjianan2 on GitHub (Oct 2, 2024). Original GitHub issue: https://github.com/fatedier/frp/issues/4465 ### Bug Description 我按照https://cloud.tencent.com/developer/article/1837482 这个教程部署frp,运行客户端时报错信息如下 ``` [root@192 frp_0.33.0_linux_amd64]# ./frpc -c ./frpc.ini 2024/10/02 08:13:10 [E] [service.go:273] token in login doesn't match token from configuration 2024/10/02 08:13:10 [W] [service.go:101] login to server failed: token in login doesn't match token from configuration token in login doesn't match token from configuration ``` ### frpc Version 0.33.0 ### frps Version 0.33.0 ### System Architecture centos ### Configurations 客户端配置 ``` [root@192 frp_0.33.0_linux_amd64]# cat frpc.ini [common] server_addr = 8.152.2.188 server_port = 7000 token = 52010 [ssh] type = tcp local_ip = 127.0.0.1 local_port = 22 remote_port = 6000 ``` 服务端配置 ``` [root@iZ2zeabyd4gtcdve3j31zdZ frp_0.33.0_linux_amd64]# cat /etc/frp/frps.ini [common] bind_port = 7000 # 授权码,请改成更复杂的 token = 52010 # 这个token之后在客户端会用到 # frp管理后台端口,请按自己需求更改 dashboard_port = 7500 # frp管理后台用户名和密码,请改成自己的 dashboard_user = admin dashboard_pwd = admin enable_prometheus = true # frp日志配置 log_file = /var/log/frps.log log_level = info log_max_days = 3 You have mail in /var/spool/mail/root ``` ### Logs 服务端报错信息 ``` [root@iZ2zeabyd4gtcdve3j31zdZ frp_0.33.0_linux_amd64]# cat /var/log/frps.log 2024/10/02 08:06:25 [I] [service.go:178] frps tcp listen on 0.0.0.0:7000 2024/10/02 08:06:25 [I] [service.go:277] Dashboard listen on 0.0.0.0:7500 2024/10/02 08:06:25 [I] [root.go:209] start frps success 2024/10/02 08:07:07 [I] [service.go:432] [817a1c0113e6bbdd] client login info: ip [120.244.197.58:35816] version [0.33.0] hostname [] os [linux] arch [amd64] 2024/10/02 08:07:07 [W] [service.go:334] register control error: token in login doesn't match token from configuration 2024/10/02 08:09:11 [I] [service.go:432] [f6e183c722f9b76f] client login info: ip [120.244.197.58:35349] version [0.33.0] hostname [] os [linux] arch [amd64] 2024/10/02 08:09:11 [W] [service.go:334] register control error: token in login doesn't match token from configuration 2024/10/02 08:13:10 [I] [service.go:432] [71fd90e23acb0b18] client login info: ip [120.244.197.58:35418] version [0.33.0] hostname [] os [linux] arch [amd64] 2024/10/02 08:13:10 [W] [service.go:334] register control error: token in login doesn't match token from configuration 2024/10/02 08:14:22 [I] [service.go:432] [51b905b601d6d968] client login info: ip [120.244.197.58:35448] version [0.33.0] hostname [] os [linux] arch [amd64] 20 ``` ### Steps to reproduce 1. 我查看了https://github.com/fatedier/frp/issues/3675 这个问题,感觉和我的问题不相符。我所用的这个版本的配置文件字段不是驼峰格式,所以没有尝试此修改 2. 按照https://github.com/fatedier/frp/issues/2099 我尝试用`./frpc -c $PWD/frpc.ini`启动,依旧有问题 ``` [root@192 frp_0.33.0_linux_amd64]# ./frpc -c $PWD/frpc.ini 2024/10/02 08:25:51 [E] [service.go:273] token in login doesn't match token from configuration 2024/10/02 08:25:51 [W] [service.go:101] login to server failed: token in login doesn't match token from configuration token in login doesn't match token from configuration ``` 3. 按照https://github.com/fatedier/frp/issues/3899 我注释掉common这行,并将服务端和客户端的token都加上了双引号,依旧相同错误 ... ### Affected area - [ ] Docs - [ ] Installation - [ ] Performance and Scalability - [ ] Security - [ ] User Experience - [ ] Test and Release - [ ] Developer Infrastructure - [ ] Client Plugin - [ ] Server Plugin - [ ] Extensions - [ ] Others
Author
Owner

@superzjg commented on GitHub (Oct 2, 2024):

既然是刚刚部署的,建议用最新版v0.60.0然后用 toml 格式(驼峰)配置,那个教程的0.33很老了。
中文配置示例:https://gofrp.org/zh-cn/docs/examples/

完整配置文件说明:
https://github.com/fatedier/frp/blob/dev/conf/frpc_full_example.toml
https://github.com/fatedier/frp/blob/dev/conf/frps_full_example.toml

<!-- gh-comment-id:2387357230 --> @superzjg commented on GitHub (Oct 2, 2024): 既然是刚刚部署的,建议用最新版v0.60.0然后用 toml 格式(驼峰)配置,那个教程的0.33很老了。 中文配置示例:https://gofrp.org/zh-cn/docs/examples/ 完整配置文件说明: https://github.com/fatedier/frp/blob/dev/conf/frpc_full_example.toml https://github.com/fatedier/frp/blob/dev/conf/frps_full_example.toml
Author
Owner

@shangjianan2 commented on GitHub (Oct 2, 2024):

既然是刚刚部署的,建议用最新版v0.60.0然后用 toml 格式(驼峰)配置,那个教程的0.33很老了。 中文配置示例:https://gofrp.org/zh-cn/docs/examples/

完整配置文件说明: https://github.com/fatedier/frp/blob/dev/conf/frpc_full_example.toml https://github.com/fatedier/frp/blob/dev/conf/frps_full_example.toml

好使了,多谢

<!-- gh-comment-id:2387428740 --> @shangjianan2 commented on GitHub (Oct 2, 2024): > 既然是刚刚部署的,建议用最新版v0.60.0然后用 toml 格式(驼峰)配置,那个教程的0.33很老了。 中文配置示例:https://gofrp.org/zh-cn/docs/examples/ > > 完整配置文件说明: https://github.com/fatedier/frp/blob/dev/conf/frpc_full_example.toml https://github.com/fatedier/frp/blob/dev/conf/frps_full_example.toml 好使了,多谢
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#3531
No description provided.