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

error " socket: too many open files" #3

Open
switchtan opened this issue Mar 15, 2020 · 2 comments
Open

error " socket: too many open files" #3

switchtan opened this issue Mar 15, 2020 · 2 comments

Comments

@switchtan
Copy link

maybe in server.go line 41,
dstServer, err := net.DialTCP("tcp", nil, request.RAWADDR)
the same request.RAWADDR,but still build a new connect.

but i don't know how to fix it

@switchtan
Copy link
Author

i fix a litte stuff in server.go line 60,

	```

SecureCopy(dstServer, client, auth.Encrypt)
readTimeout := 60 * 5 * time.Second
err = dstServer.SetReadDeadline(time.Now().Add(readTimeout))
if err != nil {
log.Println("setReadDeadline failed:", err)
}

@shikanon
Copy link
Owner

i fix a litte stuff in server.go line 60,


SecureCopy(dstServer, client, auth.Encrypt)
readTimeout := 60 * 5 * time.Second
err = dstServer.SetReadDeadline(time.Now().Add(readTimeout))
if err != nil {
log.Println("setReadDeadline failed:", err)
}

Yes, I am not set timeout to server.

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

2 participants