How to increase the size of the scroll buffer on the GNU screen

How to increase the number of lines that I can view in screen ?

I want to view lines from a point when I ran screen -S <screen_name> in the current operation. For example, how to increase the buffer length to 50,000 lines?

I already tried ^a :scrollback <number> , but it does not increase the lines that I can reach in my current terminal.

+6
source share
2 answers

You cannot retroactively increase the length of the scroll buffer in the current session to restore old lines that have already been discarded. However, if you change the current setting for the scrollback parameter ( Ca :scrollback <number> ), it will add more space for future terminal output. You can also set the defscrollback parameter to change the initial scrollback setting for new windows.

If you want to set the default value for all windows of all new screen sessions, create a ~/.screenrc file with

 defscrollback 50000 

or, if you sometimes want a big scroll, put it in a separate file, for example ~/screenrc-50k-scrollback and call screen as follows:

 screen -S <screen_name> -c ~/screenrc-50k-scrollback 

Check the current scroll throughput with Ca i ( info command).

 (22,1)/(25,40)+50000 +flow G0[BBBB] 0(bash) ^^^^^ 

Link: GNU Screen Guide Scroll Section

+5
source

I don’t know if I understood what you asked correctly, but if so, I think you can just increase the value of the Lines of scrollback , which you can find in the Window element to the left of your Session configuration.

-1
source

Source: https://habr.com/ru/post/947446/


All Articles