Server Help

ASSS Questions - Laggy shutdown on Windows

Cyan~Fire - Sat Sep 24, 2005 9:57 pm
Post subject: Laggy shutdown on Windows
Since this is a compile-out-of-the-box, I assume other people have this problem. ASSS actually terminates 40-50s after I hit ctrl+C.

This most in-depth info I've found using gdb is this (I'm no expert), captured somewhere around 10s after ctrl+C:
Code: Show/Hide
* 3 thread 1100.0x3d0  0x77fa018d in _libwsock32_a_iname ()
  2 thread 1100.0x70  0x61186380 in ptw32_cancel_self ()
  1 thread 1100.0x78  0x77f82829 in _libwsock32_a_iname ()

I don't know if this means anything to anybody, if you want me to do sometime else, tell me.

I wish I could get Dev-C++ to use the right working directory.
Mr Ekted - Sat Sep 24, 2005 10:31 pm
Post subject:
kill -9
Bak - Sun Sep 25, 2005 2:47 am
Post subject:
remove the deadlock module and try again
Cyan~Fire - Sun Sep 25, 2005 10:40 am
Post subject:
No, it's not only deadlock because it waits much longer than 10s. This is new in 1.4.0.
Cyan~Fire - Sun Sep 25, 2005 11:38 am
Post subject:
Ahhh, I've got it. I was shutting down before a minute was up, so deadlock was finishing that minute before me. Net also waits 10s on select, but that's not too big of a deal.
Mr Ekted - Sun Sep 25, 2005 5:10 pm
Post subject:
Cyan~Fire wrote:
Net also waits 10s on select, but that's not too big of a deal.


Don't ever use select() with long timeouts unless it also catches other events like "kill process". An app waiting 60 seconds to close after the user asks it to shudown is unacceptible.
Cyan~Fire - Sun Sep 25, 2005 8:42 pm
Post subject:
Well the deadlock module is the one waiting 60s, and that's only once. If I'm understanding the code properly (it's using the pthread library about which I know nothing), it should cancel immediately on unloading the module, but it seems that's not happening. I can live with a 10s delay from select(), though.
Dr Brain - Sun Sep 25, 2005 8:49 pm
Post subject:
I've never had any issue with ASSS not shutting down immediatly on windows. The problem is either something introduced in a version more recent that what I last used, or a pecularity in your compiling enviroment.
Cyan~Fire - Mon Sep 26, 2005 4:34 pm
Post subject:
It happens on the pre-compiled build too, so it's either the version or the system. Did you use the deadlock module?
Dr Brain - Mon Sep 26, 2005 5:13 pm
Post subject:
I don't think deadlock compiled for me, so probably not.

But I never had the problem with net, either.
Cyan~Fire - Tue Sep 27, 2005 7:07 pm
Post subject:
Possibly you were using ?shutdown instead of Ctrl+C, and therefore the command receipt ended the recv thread immediately?

Edit: Cancel that. Just tested, and still the delay. Maybe I'll post it as a bug.
Grelminar - Wed Sep 28, 2005 3:08 am
Post subject:
I reduced the select timeout in net to 1 second.

About deadlock delaying the shutdown, that really shouldn't be happening because of the "pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, NULL)". Reports on this thread seemed to indicate that it worked...
All times are -5 GMT
View topic
Powered by phpBB 2.0 .0.11 © 2001 phpBB Group