Cisco Router as Terminal Server Buffering Issue

cisco-ios

I have configured a Cisco 2911 with an HWIC-1T card as a terminal server using the configuration below. I can telnet to port 2003 of the loopback address and establish a serial connection to a laptop connected to the HWIC-1T card.

interface serial 0/0/0
  physical-layer async
  no ip address
  encapsulation slip

line 0/0/0
  no exec
  transport input telnet
  transport output none

The stream of characters going from the serial connection to the telnet session works perfectly. However, the stream of characters going from the telnet session out to the serial connection to the laptop lags one character behind most of the time.

Meaning if I type "1234" into the telnet window, I will see just "123" come out the serial window. The last character isn't lost, just buffered in the router until I press the next key. Sometimes the router will buffer two characters and sometimes if I type two characters together in quick sessesion, both will be correctly displayed.

I know the router is doing the buffering because I ran Wireshark and saw the TCP packet with the last character enter the router and not immediately get displayed.
enter image description here

What am I doing wrong? Thanks in advance!

Best Answer

Disable the Nagle algorithm, as that can introduce lag on telnet connections. In general, Nagle is A Good Thing(tm), but I recall it doing this on telnet connections. (telnet? terminal server? ...I'm having flashbacks.) Something like no service nagle in global config (if I recall correctly.)

update

This turns out to not solve the OP's question; but it's still useful to keep here. I'm editing my answer so people who up-voted have the ability to undo their up-vote.

Related Topic