Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

无法启动,Privoxy 出现 Fatal error #351

Closed
PillarDweller opened this issue Dec 28, 2019 · 8 comments
Closed

无法启动,Privoxy 出现 Fatal error #351

PillarDweller opened this issue Dec 28, 2019 · 8 comments

Comments

@PillarDweller
Copy link

PillarDweller commented Dec 28, 2019

预期行为

客户端正常启动

实际行为

Windows 系统提示 Privoxy Fatal error 后,v2rayN 客户端自动退出。

复现方法

  1. 打开 v2rayN.exe

日志信息,位置在当前目录下的guiLogs

--------------------------------info[21:07:22]--------------------------------
System.Exception: Webserver prefixes http://*:1082/pac/

 
--------------------------------拒绝访问。[21:07:22]--------------------------------
System.Net.HttpListenerException (0x80004005): 拒绝访问。
   在 System.Net.HttpListener.AddAllPrefixes()
   在 System.Net.HttpListener.Start()
   在 v2rayN.Base.HttpWebServer..ctor(String[] prefixes, Func`2 method)

 
--------------------------------info[21:07:22]--------------------------------
System.Exception: Webserver InitServer 拒绝访问。

 
--------------------------------info[21:07:22]--------------------------------
System.Exception: WebserverB at 127.0.0.1

 
--------------------------------CurrentDomain_UnhandledException[21:07:22]--------------------------------
System.Net.Sockets.SocketException (0x80004005): 以一种访问权限不允许的方式做了一个访问套接字的尝试。
   在 System.Net.Sockets.Socket.DoBind(EndPoint endPointSnapshot, SocketAddress socketAddress)
   在 System.Net.Sockets.Socket.Bind(EndPoint localEP)
   在 System.Net.Sockets.TcpListener.Start(Int32 backlog)
   在 v2rayN.Base.HttpWebServerB.StartListen()
   在 System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
   在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   在 System.Threading.ThreadHelper.ThreadStart()

环境信息

v2rayN 3.4(3.3 和 3.2 均有同样问题)
OS Name Microsoft Windows 10 Pro
OS Version 10.0.19041.1
.NET Framework 4.8.4084.0

额外信息(可选)

Privoxy 错误截图
Screenshot_2019-12-28_21-07-29.png

已用在 powershell 使用 netstat -ano 查看过相关端口,没有被占用。

@2dust
Copy link
Owner

2dust commented Mar 31, 2020

端口被占用

@2dust 2dust closed this as completed Mar 31, 2020
@yiran-THU
Copy link

@2dust
遇到同样情况,用netstat命令查看过了,端口未被占用。请问还有其他的原因吗?

@kaigedong
Copy link

kaigedong commented Apr 10, 2020

可以成功启动,但是打开后弹窗提示“Fatal error: can't bind to 127.0.0.1:1081: (error number 0)”.
netstat 查看端口并没有被占用。
设置v2rayN开机启动,重启计算机还是不行。

这种状况不是每次开机都会发生。之前有时候过了半个小时自动会好。

我socks代理端口设置的是1080,http代理应该是软件自动设置的1081

软件打开下面的“信息“显示:

启动服务(2020/4/10 11:17:31)...
2020/04/10 11:17:33 Using default config:  C:\Users\bobo\Documents\v2rayN-Core\config.json

V2Ray 4.23.1 (V2Fly, a community-driven edition of V2Ray.) Custom (go1.13 windows/386)
A unified platform for anti-censorship.
2020/04/10 11:17:33 [Info] v2ray.com/core/common/platform/ctlcmd: <v2ctl message> 
v2ctl> Read config:  C:\Users\bobo\Documents\v2rayN-Core\config.json
Failed to start v2ray.com/core/app/proxyman/inbound: failed to listen TCP on 1080 > v2ray.com/core/transport/internet: failed to listen on address: 127.0.0.1:1080 > listen tcp 127.0.0.1:1080: bind: An attempt was made to access a socket in a way forbidden by its access permissions.

相关log如下:

--------------------------------进程已退出,因此无法获得所请求的信息。[11:17:31]--------------------------------
System.InvalidOperationException: 进程已退出,因此无法获得所请求的信息。
   在 System.Diagnostics.Process.EnsureState(State state)
   在 System.Diagnostics.Process.get_MainWindowHandle()
   在 System.Diagnostics.Process.CloseMainWindow()
   在 v2rayN.Handler.V2rayHandler.KillProcess(Process p)

 
--------------------------------2020/04/10 11:17:33 Using default config:  C:\Users\bobo\Documents\v2rayN-Core\config.json
[11:17:33]--------------------------------
System.Exception: 2020/04/10 11:17:33 Using default config:  C:\Users\bobo\Documents\v2rayN-Core\config.json

   在 v2rayN.Handler.V2rayHandler.V2rayStart()

 
--------------------------------进程已退出,因此无法获得所请求的信息。[11:18:48]--------------------------------
System.InvalidOperationException: 进程已退出,因此无法获得所请求的信息。
   在 System.Diagnostics.Process.EnsureState(State state)
   在 System.Diagnostics.Process.get_MainWindowHandle()
   在 System.Diagnostics.Process.CloseMainWindow()
   在 v2rayN.Handler.V2rayHandler.KillProcess(Process p)

 
--------------------------------进程已退出,因此无法获得所请求的信息。[11:18:49]--------------------------------
System.InvalidOperationException: 进程已退出,因此无法获得所请求的信息。
   在 System.Diagnostics.Process.EnsureState(State state)
   在 System.Diagnostics.Process.get_MainWindowHandle()
   在 System.Diagnostics.Process.CloseMainWindow()
   在 v2rayN.HttpProxyHandler.PrivoxyHandler.KillProcess(Process p)

 
--------------------------------info[11:19:41]--------------------------------
System.Exception: v2rayN start up v2rayN - V3.14 - 2020/04/08

最后一次重启软件,没有报错,可以正常代理了。

操作系统版本:19587.1000

@simon-sudo
Copy link

端口被占用

使用

.\NETSTAT.EXE -ano | .\findstr.exe "10809"

查看并没有找到被占用

@lywly
Copy link

lywly commented Dec 1, 2020

遇到了同样的问题,netstat -ano | findstr "10809" 查看端口没有被占用。各位找到其他解决办法了吗?

@yfdyh000
Copy link
Contributor

yfdyh000 commented Dec 2, 2020

遇到了同样的问题,netstat -ano | findstr "10809" 查看端口没有被占用。各位找到其他解决办法了吗?

shadowsocksrr/shadowsocksr-csharp#142 (comment) 或许相关。我还没试。

@GaoJones
Copy link

GaoJones commented Apr 2, 2021

我也遇到了同样的问题,求解

@nash-R
Copy link

nash-R commented Jun 28, 2021

https://www.cnblogs.com/lonelyisland/p/14655139.html
这种情况其实是因为win10保留动态端口的端口号范围和你设定的端口出现了冲突(内核系统级冲突,普通工具是看不到的), 所以我们要修改动态端口的许可范围, 上调到比如从30000这种不常用端口开始.
使用管理员权限cmd执行如下指令 然后必须重启一次电脑即可 解决冲突问题
netsh int ipv4 set dynamicport tcp start=30000 num=20000

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants