Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD General Discussion
kadaan
Beginner


Joined: 23 Jan 2002
Posts: 12

PostPosted: Mon Jan 21, 2008 2:57 am   

Disconnected from inactivity
 
Whenever I go idle for a while with nothing being received/sent from the MUD, I get disconnected. cMUD still shows me as connected, but as soon as I send a command I get the "Disconnected from server" message.

I've tried going idle with both TF and normal telnet, and neither have the same problem, so I believe it's a cMUD problem and not the MUD nor my ISP.

Any ideas?
Reply with quote
Rainchild
Wizard


Joined: 10 Oct 2000
Posts: 1551
Location: Australia

PostPosted: Mon Jan 21, 2008 4:12 am   
 
It's usually caused by a router or firewall that you may have, when you sit idle for a while the router "forgets" that you were connected, but silently closes the connection (so your client thinks that it's still connected).

I asked Zugg to put in a "keep-alive" packet option, but I'm not sure if this made it into the code yet. In the mean time, I have a tick timer set up to every 90 seconds "#SENDP %char(8)" ... this just sends a backspace to the MUD which (hopefully) will be ignored (unless your MUD doesn't handle backspace properly). The 90 second tick keeps the routers happy, and I can be connected idle indefinately.

The other two programs may already have some kind of "keep-alive" feature turned on by default (and therefore you don't experience it). Or, the "idle-ness" might have been reset by chat on a channel, etc. For this issue, it's not the amount of time you haven't touched your computer, it's the amount of time between lines appearing.
Reply with quote
ralgith
Sorcerer


Joined: 13 Jan 2006
Posts: 715

PostPosted: Mon Jan 21, 2008 5:16 am   
 
I actually experience the same thing, and it IS time of not doing anything on the MUD. I can sit here and WATCH chat channels and such, and after awhile it closes out (my character isn't idling out, it IS the CMUD connection). However since I hadn't narrowed it down and no one else had said anything I hadn't yet reported it. But it is definitely something in CMUD. I can have z and C running side by side, and it only happens in C.
_________________
CrossOver: Windows Compatibility on Mac and Linux CMUD Advocate
Reply with quote
kadaan
Beginner


Joined: 23 Jan 2002
Posts: 12

PostPosted: Mon Jan 21, 2008 6:04 am   
 
I'm pretty sure it's not the router, as I highly doubt the default windows telnet app does anything special.

Yep, it happens when nothing is happening on the mud and I don't even get chat messages for 5-10 minutes.

I'll try setting up a tick timer, if that works I'll let you know!
Reply with quote
Surma
Newbie


Joined: 18 Jan 2008
Posts: 3

PostPosted: Mon Jan 21, 2008 8:26 am   
 
I've had the same problem, it does seem to be rather random however. At times I can stay 'idle' for hours, other times if I'm idle for more than a few seconds I get disconnected. In order to prevent this I've set an alarm that about every 15 seconds sends a #cr, this has cleared it up nicely.

I am convinced that there's something in cmud that's causing it to drop the connection. However in the face of other possibilities I'll try changing my routers port forwarding in hopes of clearing this up.
Reply with quote
Rainchild
Wizard


Joined: 10 Oct 2000
Posts: 1551
Location: Australia

PostPosted: Mon Jan 21, 2008 11:02 pm   
 
I don't think port forwarding will help at all, it goes like this:

CMUD makes an outbound connection to the MUD, router sees the connection as active, you do stuff on the MUD, router is happily passing data back and forth, aware that this connection is active. You go idle. A few minutes later (depends on router settings, manufacturer, etc - my home linksys is about 10 minutes) the router cleans up inactive sessions. When the MUD next sends a packet of data, the router goes "I don't know what that's for" and drops it, but it hasn't actually told CMUD that the connection has been closed. So it's not until you type something and CMUD tries to send it to the MUD and the router goes "oh yeah, that connection no longer exists, btw".

So because CMUD is establishing the session, there's no port forwarding necessary.

Raglith, your issue sounds more like the MUD detects that you haven't typed anything and drops you for idleness, which can probably also be fixed by a tick timer, however the one I suggested may or may not work. Some MUD's require you to actually type in a valid command to reset your idle counter, others just look for character input.

I certainly had both issues with zMUD and CMUD (and windows telnet), which is why I asked for that keep-alive packet thing and currently use a tick timer until that is implemented. Having said all that, I haven't played a MUD for an extended period of time recently so if some new bug has been introduced in 2.18 then I'll stand corrected, but from the descriptions presented it sounds like the same problem I have experienced for the last 8 years.
Reply with quote
ralgith
Sorcerer


Joined: 13 Jan 2006
Posts: 715

PostPosted: Mon Jan 21, 2008 11:49 pm   
 
You're not getting it Rainchild :)

I HAVE a tick timer. Set for 500 seconds. This works fine, as I said, I can have z and C SBS and only C drops. It is NOT the MUD dropping the connection. I can verify this as I happen to be the ADMIN and CODER for it :) Also if I'm SEEING the chats from other people, and just watching, obviously CMUD is still receiving packets fine, so it isn't a router drop since the comms are still going on. And it happens on other MUDs too. This IS something in CMUD, but not really a big issue either. As long as you stay active, it don't matter. Right now I can't work on reproducing it since I've yet to buy CMUD and my trial is out ;)

When I get CMUD, I'll time it out, and see if we can't start to narrow it down.
_________________
CrossOver: Windows Compatibility on Mac and Linux CMUD Advocate
Reply with quote
Rainchild
Wizard


Joined: 10 Oct 2000
Posts: 1551
Location: Australia

PostPosted: Tue Jan 22, 2008 1:02 am   
 
Ok, to test this further I did the following:

1) Connect to my MUD on the remotely hosted machine using my admin account, disabled my tick timer, and went to a quiet room with no channels. I coded the MUD to not drop admins regardless of idle-length.
2) Connect to my MUD on the remotely hosted machine using a player account, enabled my tick timer, and sat in a noisy room with channels on. The tick timer will send backspace to fool the MUD into thinking I'm not idle.
3) Connect to my MUD on the same machine as CMUD (ie localhost) with no tick timer.
4) Connect to my MUD on the same network as my machine (ie via a switch but not a router) with no tick timer.

Results were as follows:
1) Failed after 20 minutes (this was expected, because there was nothing keeping the connection alive in the router's connection table).
2) Still connected after 30 minutes (this was expected, because the tick timer kept the connection alive in the router's connection table).
3) Still connected after 30 minutes (this was expected, because there was no router involved).
4) Still connected after 30 minutes (this was expected, because there was no router involved).

Hence my conclusion that CMUD probably isn't to blame.

That being said, I didn't try to stay connected for 24 hours which would be a more extreme test, nor did I test a bunch of other clients to prove a pattern. I also had no triggers, etc so it was a fairly "clean" test. Maybe with a combination of triggers, old network drivers, telnet option negotiations, wireless networking, patchy input and a spot of latency (so you suddenly get a burst of packets) you will get different results.

Finally, Zugg did add SSH to CMUD (pro) which means that the socket code may have changed a little bit and with any change there's always a chance to introduce an issue, but from my testing - it's fine. I look forward to seeing your results once you have made your purchase.
Reply with quote
kadaan
Beginner


Joined: 23 Jan 2002
Posts: 12

PostPosted: Tue Jan 22, 2008 1:10 am   
 
It definitely is a zMUD/cMUD thing. I've tried it on two different muds (chaosmud/zombiemud,) 3 different clients (cMUD/tf/telnet,) 3 different ISPs (cox/charter/roadrunner,) and with/without connecting through my router. I'm 99% sure it's a zMUD/cMUD thing. It could be the way cMUD manages the connection, rather than the way the router does.

The tick timer seems to work though, I can actually go eat dinner and come back without being disconnected now, thanks!
Reply with quote
ralgith
Sorcerer


Joined: 13 Jan 2006
Posts: 715

PostPosted: Tue Jan 22, 2008 2:16 am   
 
Yea, if my tick timer was set low enough it would keep it from timing out.

And this is with a direct dialup connection too.

I'm wondering if it maybe isn't OS related, as in something in the way different versions of windows implement sockets. I've only experienced it on Vista Home Premium (my only Vista). I don't recall ever seeing it on XP. Hmm, :) If that is the case, one more reason to hate Pukesta!
_________________
CrossOver: Windows Compatibility on Mac and Linux CMUD Advocate
Reply with quote
Zugg
MASTER


Joined: 25 Sep 2000
Posts: 23379
Location: Colorado, USA

PostPosted: Tue Jan 22, 2008 10:42 pm   
 
zMUD/CMUD doesn't do anything special. The other MUD clients you tried might be using some sort of "keepalive" feature. All zMUD/CMUD does is open a Telnet socket connection. As RainChild correctly said, a Telnet connection requires a constantly active socket (web browsers, on the other hand, use a different socket connection for each page element and do not need constant connection). With a Telnet connection, if a router anywhere in the path between your computer and the server drops the connection, Windows won't find out until CMUD tries to send a packet. Then, Windows will get a socket-closed message and try to reconnect.

It's possible that it's something in Vista, but I have personally seen it happen on both. It's usually a remote router issue and not a local Windows issue. There is a "Keepalive" socket option as mentioned by Rainchild that I plan to support in a future version of CMUD. Just haven't gotten to it yet.
Reply with quote
easal
Novice


Joined: 21 Jun 2005
Posts: 38

PostPosted: Tue Jan 22, 2008 10:49 pm   
 
Same is happening to me. At the moment I have a simple alarm to send input to the mud and keep the connection alive.

However, any non-command text sent to a IRE mud yields a message "That does not compute" or whatever, is there a way, other than getting all the messages and gagging them, to send a silent input of some sort?

This one is def my connection, not cmud, just so you know.

Thanks.
Reply with quote
Fang Xianfu
GURU


Joined: 26 Jan 2004
Posts: 5155
Location: United Kingdom

PostPosted: Tue Jan 22, 2008 11:02 pm   
 
I believe you can send a %cr to an IRE MUD and have it respond with only a prompt - experiment with some other possible characters using the %char function. Really, though, how inconvenient is an extra two lines every now and again? You'd only need it when the MUD sends the "you will timeout in one minute".
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)
Reply with quote
ralgith
Sorcerer


Joined: 13 Jan 2006
Posts: 715

PostPosted: Wed Jan 23, 2008 12:57 am   
 
@Zugg:

My question then is why would it only happen in CMUD, instead of both?
I just don't get that heh. And as the original poster pointed out, it isn't happening in basic windows telnet, which has 0 frills. Same with putty in telnet mode. I'm not saying it is CMUDs code, but maybe something in newer Delphi socket implementations, or something in the windows socket implementations... when I buy CMUD in a couple months I'll be more than glad to do some thorough testing on it to see if I can't help narrow it down, because it just doesn't make any sense at all that it wouldn't happen in all clients that don't have a keepalive.

However, @esal, most muds have a command "whoami" and this is what I use under my tick timer. This command just spits out the character's name, and does not add a waitstate to your command inputs, so you can send another command without any delay.

@General Topic:

I really don't see WHY it would only happen in CMUD this way, especially on a direct dialup connection. However, MAYBE it is router related, but for me at the ISP level. See, my ISP assigns me a private LAN IP, and every customer on a single dialin number has the same external internet IP. Which sucks since it means I can't host online games (not that I'd want to normally on dialup... but an occasional game of MegaMek is always fun :) ) and I have no idea how they've got their hardware and software configured. I've had many problems with them, but they're all I can get in this location. I mean, if I try to download a file over 5MB, it spits an error back at me that the file is too large. If I try and download a .tar.gz or a .tgz (same thing lol) it won't let me because it violates security protocols. Stupid stupid ISP. I'm thinking that I'll test CMUD on my buddy's high speed and try to eliminate that as a possibility. Between CMUD and helping out over at www.mordel.net I'm swamped with bug testing, and I love it lol!
_________________
CrossOver: Windows Compatibility on Mac and Linux CMUD Advocate
Reply with quote
easal
Novice


Joined: 21 Jun 2005
Posts: 38

PostPosted: Fri Feb 08, 2008 11:48 pm   
 
Sorry for the late reply.

Quote:
I believe you can send a %cr to an IRE MUD and have it respond with only a prompt - experiment with some other possible characters using the %char function. Really, though, how inconvenient is an extra two lines every now and again? You'd only need it when the MUD sends the "you will timeout in one minute".
No, it's that my connection is funky. It's dropping my connection, so it's more like my "stand" input is every 15 secs to avoid a disconnect.
%cr works a lot better though, thanks!
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net