Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to view screen session output?

I've created a session in screen. It produced some output. Now I want to see it. So I attached the needed session, but could only see output limited by the size of console size. If I scroll up I see previous console commands, not screens output. If I try to navigate using arrows then just arrow keys codes are inserted. Is there any way to get the output of the screen session? Thanks!

like image 657
sbeliakov Avatar asked Oct 23 '13 16:10

sbeliakov


People also ask

How do I view screen sessions in Linux?

To check whether we are in Screen session or not, simply press Ctrl+a and then Ctrl+t keys. This will show the time and host name if you are in Screen session.

How do I get to screen session?

To start a screen session, you simply type screen within your ssh session. You then start your long-running process, type Ctrl+A Ctrl+D to detach from the session and screen -r to reattach when the time is right. Once you have multiple sessions running, reattaching to one then requires that you pick it from the list.

How do I get out of a screen session?

If you exit screen, by typing exit, you lose that session. To detach it, type Ctrl-a Ctrl-d (most commands in screen start with Ctrl-a, this overrides the Ctrl-a command normally used when you want to jump to the start of a line). To reconnect to it, type 'screen -r'.


1 Answers

You need to use the scroll-back buffer in screen. You can navigate the scroll-back buffer by using Ctrl-a Esc or Ctrl-a [ then you can page up/down with any of these actions:

http://www.gnu.org/software/screen/manual/screen.html#Movement

Ctrl-b or Ctrl-f to move back and forth by a page.

Esc will pop you back out of scroll-back navigation.

like image 165
DrLivingston Avatar answered Oct 18 '22 22:10

DrLivingston