[GH-ISSUE #1680] 转发UDP端口只监听ipv6不监听ipv4 #1330

Closed
opened 2026-05-05 12:50:50 -06:00 by gitea-mirror · 7 comments
Owner

Originally created by @Cathgao on GitHub (Mar 2, 2020).
Original GitHub issue: https://github.com/fatedier/frp/issues/1680

客户端配置:
type = udp
local_ip = 127.0.0.1
remote_port = 27015
local_port = 27015

服务器与客户端均没有开启ipv6
服务器端使用netstat -ano查看只有UDP6 :::27015没有UDP 0.0.0.0:27015
frps

Originally created by @Cathgao on GitHub (Mar 2, 2020). Original GitHub issue: https://github.com/fatedier/frp/issues/1680 客户端配置: type = udp local_ip = 127.0.0.1 remote_port = 27015 local_port = 27015 服务器与客户端均没有开启ipv6 服务器端使用netstat -ano查看只有UDP6 :::27015没有UDP 0.0.0.0:27015 ![frps](https://user-images.githubusercontent.com/21031564/75668088-b7286280-5cb3-11ea-8303-13fa8dc75e37.png)
Author
Owner

@QQ2017 commented on GitHub (Mar 15, 2020):

换一个端口试试呢?

<!-- gh-comment-id:599157011 --> @QQ2017 commented on GitHub (Mar 15, 2020): 换一个端口试试呢?
Author
Owner

@ouxlwhu commented on GitHub (Mar 16, 2020):

服务端也遇到这个问题,换过端口,都起作用
只能监听ipv6的,ipv4的没有,导致客户端连不上服务端
[root@linux_amd64]# netstat -nap | grep 56000
tcp6 0 0 :::56000 :::* LISTEN 18652/./frps
[root@linux_amd64]# cat frps.ini
[common]
bind_port = 56000

使用release中的v0.32.0和v0.21.0都是这样,其他版本没试过
在两种环境中试过:
1.
sonic@aster241:$ uname -a
Linux aster241 4.15.0-66-generic #75
16.04.1-Ubuntu SMP Tue Oct 1 14:01:08 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
2.
[root@linux_amd64]# uname -a
Linux iZm5e97u0ftapn9pk5ul65Z 3.10.0-957.5.1.el7.x86_64 #1 SMP Fri Feb 1 14:54:57 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux

<!-- gh-comment-id:599413152 --> @ouxlwhu commented on GitHub (Mar 16, 2020): 服务端也遇到这个问题,换过端口,都起作用 只能监听ipv6的,ipv4的没有,导致客户端连不上服务端 [root@linux_amd64]# netstat -nap | grep 56000 tcp6 0 0 :::56000 :::* LISTEN 18652/./frps [root@linux_amd64]# cat frps.ini [common] bind_port = 56000 使用release中的v0.32.0和v0.21.0都是这样,其他版本没试过 在两种环境中试过: 1. sonic@aster241:~$ uname -a Linux aster241 4.15.0-66-generic #75~16.04.1-Ubuntu SMP Tue Oct 1 14:01:08 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux 2. [root@linux_amd64]# uname -a Linux iZm5e97u0ftapn9pk5ul65Z 3.10.0-957.5.1.el7.x86_64 #1 SMP Fri Feb 1 14:54:57 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Author
Owner
<!-- gh-comment-id:599423703 --> @ouxlwhu commented on GitHub (Mar 16, 2020): 找到一个文档描述,认为这种情况不是问题 https://blog.csdn.net/weixin_30662011/article/details/95843673?depth_1-utm_source=distribute.pc_relevant.none-task&utm_source=distribute.pc_relevant.none-task
Author
Owner

@Cathgao commented on GitHub (Mar 16, 2020):

找到一个文档描述,认为这种情况不是问题
https://blog.csdn.net/weixin_30662011/article/details/95843673?depth_1-utm_source=distribute.pc_relevant.none-task&utm_source=distribute.pc_relevant.none-task

但我的事实上就是ipv4对这个端口没法连上

<!-- gh-comment-id:599471611 --> @Cathgao commented on GitHub (Mar 16, 2020): > 找到一个文档描述,认为这种情况不是问题 > https://blog.csdn.net/weixin_30662011/article/details/95843673?depth_1-utm_source=distribute.pc_relevant.none-task&utm_source=distribute.pc_relevant.none-task 但我的事实上就是ipv4对这个端口没法连上
Author
Owner

@fatedier commented on GitHub (Mar 29, 2020):

Maybe not a problem about frp, search google for more info.

<!-- gh-comment-id:605633162 --> @fatedier commented on GitHub (Mar 29, 2020): Maybe not a problem about frp, search google for more info.
Author
Owner

@jackluo2012 commented on GitHub (Oct 20, 2020):

遇到了同样的问题,怎么解决的

<!-- gh-comment-id:712572948 --> @jackluo2012 commented on GitHub (Oct 20, 2020): 遇到了同样的问题,怎么解决的
Author
Owner

@ZeddShi commented on GitHub (Jul 12, 2022):

一般是因为服务器端口没开,例如阿里云安全组没配

<!-- gh-comment-id:1181258425 --> @ZeddShi commented on GitHub (Jul 12, 2022): 一般是因为服务器端口没开,例如阿里云安全组没配
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#1330
No description provided.