首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Miniupnp认为我的路由器不支持UPnP

Miniupnp认为我的路由器不支持UPnP
EN

Unix & Linux用户
提问于 2015-02-05 04:52:58
回答 1查看 4.2K关注 0票数 3

我的网络上有一个真正的即插即用的IP摄像头。一旦我插入以太网电缆,它就可以从“外部”访问,而无需触摸路由器的配置。所以我知道我的路由器支持UPnP。我还可以看到UPnP服务器正在监听5431

我正在尝试启用临时FTP服务器(在本例中更改为端口29 ),希望朋友能够访问该服务器。我安装了miniupnp并运行了以下命令。

代码语言:javascript
复制
$ upnpc -l
upnpc : miniupnpc library test client. (c) 2005-2013 Thomas Bernard
Go to http://miniupnp.free.fr/ or http://miniupnp.tuxfamily.org/
for more information.
No IGD UPnP Device found on the network !

miniupnp显然很难找到我的路由器,或者认为它没有启用UPnP。

我如何解决这个问题?

编辑:我刚刚在我的IP摄像头中安装了一个telnet会话。巧合的是,它也在运行miniupnp,我运行了二进制文件,它返回了:

代码语言:javascript
复制
# ./upnpc-static -l    
upnpc : miniupnpc library test client. (c) 2006-2010 Thomas Bernard
Go to http://miniupnp.free.fr/ or http://miniupnp.tuxfamily.org/
for more information.
List of UPNP devices found on the network :
 desc: http://192.168.0.1:5431/dyndev/uuid:c03e0f29-4fec-ec4f-290f-3ec03e29ec0000
 st: urn:schemas-upnp-org:device:InternetGatewayDevice:1

Found valid IGD : http://192.168.0.1:5431/uuid:c03e0f29-4fec-ec4f-290f-3ec03e29ec0002/WANPPPConnection:1
Local LAN ip address : 192.168.0.30
Connection Type : IP_Routed
Status : Connected, uptime=127693s, LastConnectionError : 
  Time started : Wed Feb  4 01:06:15 2015
MaxBitRateDown : 20819000 bps   MaxBitRateUp 1209000 bps
ExternalIPAddress = 90.220.126.102
 0 TCP    80->192.168.0.30:80    'ipcam-h264' ''
 1 UDP 41441->192.168.0.4:41441 'Skype UDP at 192.168.0.4:41441 (2956)' ''
 2 TCP 41441->192.168.0.4:41441 'Skype TCP at 192.168.0.4:41441 (2956)' ''
GetGenericPortMappingEntry() returned 713 (SpecifiedArrayIndexInvalid)

所以我的IP摄像头上的同一个程序就是找到IGD,而我的笔记本电脑却不在。

EN

回答 1

Unix & Linux用户

发布于 2022-11-06 00:00:04

如果启用了防火墙(如iptables或ufw),则必须允许来自路由器的UDP数据包进入

对于ufw来说是这样的

代码语言:javascript
复制
sudo ufw allow from 192.168.1.1 to any proto udp
票数 1
EN
页面原文内容由Unix & Linux提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://unix.stackexchange.com/questions/183036

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档