Putty + Bash + Screen, up arrow for history not working (Ubuntu 11.10)
I have a fresh install of Ubuntu Server 11.10 that I am logging into SSH via PuTTy. When I am inside screen, I cannot use the up arrow to recall bash history (though this works outside of screen). I cannot seem to find the exact same problem on the Interwebs (though many similar ones). My .screenrc is below:
# Look and feel
caption always "%{= bb}%{+b w}Screen: %n | %h %=%t %c"
hardstatus alwayslastline "%-Lw%{= BW}%50>%n%f* %t%{-}%+Lw%<"
# Our warning of activity
activity "Activity in %t(%n)"
# Left Right meta key mods
#ALT-,. and ALT-<>
bindkey "^[<" eval number !echo $WINDOW-1|bc
bindkey "^[>" eval number !echo $WINDOW+1|bc
bindkey "^[," prev
bindkey "^[." next
#disable startup banner
startup_message off
#see http://www4.informatik.uni-erlangen.de/~jnweiger/screen-faq.html
termcap xterm 'XT:AF=\E[3%dm:AB=\E[4%dm:AX'
terminfo xterm 'XT:AF=\E[3%p1%dm:AB=\E[4%p1%dm:AX'
termcapinfo xterm 'XT:AF=\E[3%p1%dm:AB=\E[4%p1%dm:AX:hs:ts=\E]2;:fs=\007:ds=\E]2;screen\007'
termcap xtermc 'XT:AF=\E[3%dm:AB=\E[4%dm:AX'
terminfo xtermc 'XT:AF=\E[3%p1%dm:AB=\E[4%p1%dm:AX'
termcapinfo xtermc 'XT:AF=\E[3%p1%dm:AB=\E[4%p1%dm:AX:hs:ts=\E]2;:fs=\007:ds=\E]2;screen\007'
#scrollback
termcapinfo xterm ti@:te@
shell -$SHELL
UPDATE: The up arrow works properly in other apps such as vim and less. This problem occurs on the physical console as well as in PuTTy.
Solution 1:
I had a similar problem. Turns out the user account I created didn't have a default shell set.
Solution 2:
I use Ctrl-a Esc to enter copy/scrollback mode and then navigate using h j k l or arrow keys.
Read this for navigation options - http://web.mit.edu/gnu/doc/html/screen_11.html