cancel
Showing results for 
Search instead for 
Did you mean: 

When putty is full screen and you backspace a long command, cursor jumps up a line

When putty is full screen and you backspace a long command, cursor jumps up a line

Keith9
Contributor III

This is a question that I have in regards to a 4 year old post.  Where are we with this?

 

This was 4 years ago and still I see this issue.

Using Putty to SSH to EXOS 5520 on 31.1.1.3.

If you type something like sh port 1:1-48, you have to maximize your putty window to see it right so its not jumping around.  So once putty is maximized when you get out of that view and lets say you want to run a few other commands, larger commands.

Say you type a somewhat longer command i dont know, like this for example:

enable sharing 1:57 grouping 1:57,2:57 algorithm address-based L3_L4 lacp
and now you want to create another load sharing group (or whatever it is thats simular but needs minor changes), you hit the up arrow to recall the last command, and then arrow back to the numbers maybe you want to change it to :

enable sharing 1:58 grouping 1:58,2:58 algorithm address-based L3_L4 lacp
Well as you start arrowing back to the first group of numbers, the cursor jumps up a line and the command dissapears.  Its there, if you count how many spaces you need to go and delete and type and hit enter you can get the command updated and in, but usually thats not good to work blindly like that.

So 4 years later many software revisions later, any help with this issue?  I haven’t recalled ever having this on a cisco or linux device.

1 ACCEPTED SOLUTION

Ludovico_Steven
Extreme Employee

I wrote my own terminal, so I have a few clues as to what’s going on.

The reason the cursor jumps is that the switch thinks the size of the terminal is smaller than what it is.

In your example, after recalling the command and coming back with the cursor, the switch thinks that the command is wrapped on 2 lines (the terminal would automatically print on next line if the line too long) so when it thinks you’ve reached the beginning of the 2nd line, it will jump up 1 line and position the cursor at the end of this line (according to the size the switch thinks the terminal is).

I had a try with Putty, and XOS (even tried a 5520) works well, both Telnet and SSH. Every time I resize the putty window, the XOS automatically adjusts to the new terminal size and there is no jumping.

Then I tried on XMC Webshell, and here it is flagrant. Any resize you do with XMC Webshell is not signalled back to the switch. This would be a bug on the XMC Webshell. I already don’t like the XMC Webshell much, so this is another nail in that coffin!

But with Putty it works ok. Then I tried your exact steps, did the show ports command (which you probably did without specifying “no-refresh”), and I re-sized the putty window WHILE the XOS was still refreshing the output. ESCaped that and then sure enough I could make the cursor jump. So the problem is that XOS does not adjust the terminal size if the terminal signals a new size while it is constantly refreshing the output of the command. However it is very easy to correct the behaviour, once you ESCaped the refreshed output (and you have an XOS CLI prompt showing), simply re-adjust the putty window size, and then that will sync it up on XOS as well.

I can raise these with GTAC if you like; but you can also do that.

 

 

 

View solution in original post

7 REPLIES 7

Stefan_K_
Valued Contributor

Oh, I somehow thought we were talking about the XMC terminal. But yes, it applies to both Putty and XMC Terminal. The command you mentioned might fix it in both cases… Will give it a try, thank you!

Best regards
Stefan

SamPirok
Community Manager Community Manager
Community Manager

I believe you can adjust that on the switch side with the command: configure cli columns <#> lines <#>

Putty might also have a way to adjust that if you wanted to try a fix on the terminal emulator side instead. 

Stefan_K_
Valued Contributor

Well, all I can say is, that I experience this all the time and it’s really annoying since I use the XMC Terminal all the time when working remotely for different customers. A fix would be great...

GTM-P2G8KFN