Hopefully someone here will know what's up with this:
I'm using putty to access a server via SSH. When I press 'up' on the keyboard, I expect to get back the line I previously entered. I don't - instead, I get ^[[A. This is not very helpful. I don't get this when accessing another server. Is this a setting the server makes, rather than the accessing client?
Also it could be the terminal settings on the hosts itself, I just started getting back into linux so I can't tell you exactly where to go.
Steam/PSN/XBL/Minecraft / LoL / - Benevicious | WoW - Duckwood - Rajhek
Try checking the TERMINFO environment variable (or "infocmp | head -n 2") on both machines and see what they return.
Do a google for "up arrow command history (shell)" and see if you get anything that'll help you.
That should at least give you the last commmand.
I thought this would have some effect, but it doesn't.
Zese words, they mean nothing to me.
I've also realised now that this means the left and right arrows don't work either. I get ^[[D and ^[[C instead of the cursor moving.
What operating system is the server running? What is your login shell?
Since !! works, I'm pretty certain you're using either csh or tcsh, in which case you want to follow the directions here. Note that you still won't have the up-arrow functionality you're used to on the other server, where your shell is almost certainly bash. You'll have a bunch of less-slick but functionally-equivalent abilities.
Try copying the /usr/share/terminfo/x/xterm file from the machine that works to ~/.terminfo/x/xterm on the problematic machine and see if it works after re-connecting.
If I had to guess, I'd say csh.
Though, !! is supported by bash, at least on ubuntu.
I don't actually have much write access to this server, so I'll have to suck it up and learn the CSH commands. Why on earth don't they have left and right set up to navigate through text on the command line though?
You're using SSH, but it's essentially just a transport protocol. You're still using a specific shell on the remote system, and putty (your terminal emulator) accepts the same control sequences as xterm plus some extras.
Anyway, I mentioned copying it to your home directory on the misbehaving machine (most people have write access there), but would you mind copying/pasting the full output of "infocmp" from both machines? I might test it myself later (sorta busy right now), but I want to do a comparison between the two. terminfo is used to determine what control sequences a terminal emulator will accept, and I think those two differ in more ways than just the description.
The one that works the way I'm used to:
And the other:
I'll repeat my earlier suggestion: Try copying the /usr/share/terminfo/x/xterm file from the machine that works to ~/.terminfo/x/xterm on the problematic machine (in your home directory) and see if it works after re-connecting. The home directory entry should be used first and things should work as expected.
previous line: ESC and then K, further history keep hitting K
To edit that line is L to move right, H to move right and then I to start an insert (like VI)
With this handy list you can change shells to any listed in the result set by using chsh.
For example: to change to bash on my machine.