Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am using a mac (snow leopard). I am a ruby on rails developer and I watched a screencast on GNU screen and am trying it out. So far I like it.

On a window when I start server I get to see the log messages. However I can't seem to scroll up. I do get a scroll bar. However when I use the scroll bar and scroll up I don't see anything.

How do people use GNU screen and scroll up?

share|improve this question
up vote 39 down vote accepted

There's a 'copy mode' in screen, activated by pressing, ctrl-A, then [ quickly. This gives you a cursor that you can use to scroll backwards.

share|improve this answer
Thanks that works. Is there a faster way to go up rather than just having the up arrow pressed. – Nadal May 7 '10 at 15:27
@dorelal: The vim-like shortcuts Ctrl-U and Ctrl-D move up a half page and down a half page while in copy mode. Also, ESC will take you out of copy mode. – Trey Hunner May 7 '10 at 16:09
@dorelal I usually use the other shortcut ctrl-A, then Esc quickly, to get into copy mode rather than [. It is easier for me to remember. – Jarvin May 7 '10 at 19:27
What's this quickly? It does not seem to matter how fast you do it... – Kevin Panko Aug 18 '10 at 15:11
@kevin: quite right, the "quickly" was meant to explicitly convey "not simultaneously". – Babu Aug 18 '10 at 17:09

Add the following to your ~/.screenrc:

termcapinfo xterm ti@:te@
termcapinfo xterm-color ti@:te@

This will let you use the scrollbar instead of relying on screen's scrollback buffer.

share|improve this answer
This should really become a default setting. I keep on coming back here to get this, thanks! – Dagelf Oct 17 '14 at 13:43
....And again.... and again... the gift that keeps on giving... – Dagelf Jul 8 '15 at 16:40
...And again... – Dagelf Aug 4 '15 at 19:00
Or: termcapinfo xterm* ti@:te@ for both. – kenorb Jan 17 at 12:30

Take a look at GNU Screen: Working with the Scrollback Buffer for a good introduction.

share|improve this answer
that was an awesome introduction. thanks mate. – Nadal May 7 '10 at 17:00
And... it's gone. 404 – Tom Stephens Jan 7 '14 at 22:12
Replaced link with link – Doug Harris Jan 8 '14 at 16:01

The correct way is to use the copy mode like pointed out.

You could speed things a bit by automatically enter in the copy mode when you press your favourite scroll keys.

For example using PgUp and PgDown:

# easier scroll
bindkey "^[[5~" eval 'copy' 'stuff ^b'  # PgUp | Enter copy/scrollback mode and page up
bindkey "^[[6~" eval 'copy' "stuff ^f'  # PgDown | Enter copy/scrollback mode and page down
share|improve this answer
  • I use Ctrl+A Esc to go in copy mode.
  • Then use arrows or PageUp/PageDown to move through the scroll buffer.
  • To exit copy mode, just hit Esc.

that’s a little more intuitive by this way.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .