Scrolling up in terminal linux

How to Scroll Up in the Linux Terminal

If you’re a new Linux user trying to navigate the lines of inputs and outputs filling your terminal, it might be a bit overwhelming. Because recent lines remain visible, as your inputs increase and your outputs grow longer, your screen can quickly grow unrecognizable, buried in a wall of white text. When you don’t need this previous information, you can always clear the terminal, but what if you realize later that you’ve lost something important? Maybe you’re troubleshooting an issue, or looking to repeat a previously entered command. Regardless of why, if you’re looking for how to scroll up and down in the Linux terminal, then read on to learn several methods for easily navigating the Linux terminal using your keyboard.

How to Scroll Up and Down in Linux

As with many things in Linux, the ability to scroll up and down within your terminal depends on the specific terminal you are using. For most users, you should be able to scroll up and down, one line at a time using Shift+UpArrow or Shift+DownArrow. To jump an entire page at a time, try Shift+PageUp or Shift+PageDown.

If these commands don’t work, it’s likely your terminal is using different keybindings. While determining exactly which keyboard shortcuts work for your terminal requires you to know which terminal you’re running, there is a secondary method which is quite common as well. The other common method for moving up and down a line at a time involves using Ctrl+Shift+UpArrow or Ctrl+Shift+DownArrow. This same alternate pattern can be used to jump whole pages at a time using Ctrl+Shift+PageUp or Ctrl+Shift+PageDown.

Keep in mind, some terminals don’t allow scrolling at all, or only keep a very limited history of previous inputs. These options may be modifiable from within the terminal’s configuration file, but this will depend entirely on the terminal being used.

Some terminals also offer a designated “scroll mode,” allowing users to easily navigate using the arrow keys when active. To see if this is something your terminal offers, try hitting the Scroll Lock key on your keyboard. If your keyboard does not have a designated Scroll Lock key, try using the command Ctrl+A. This activates scrollback mode on GNU Screen, allowing users to move through the terminal easily using the keyboard. Whether or not this option is available to you is entirely dependent on the specific terminal you are running.

*Note: To exit scroll mode, simply hit the Esc key at any time.

And there you have it! Depending on your terminal, one of these methods may work better than the others, but for most instances, you can scroll up in the Linux terminal using either Shift+PageUp or Ctrl+Shift+PageUp.

For more information on Linux, check out the links below or search our Knowledge Base for more useful tips and tricks for Linux novices and veterans alike.

Читайте также:  Swap файл подкачки linux

Looking for more information on Linux ? Search our Knowledge Base !

Interested in more articles about Operating Systems ? Navigate to our Categories page using the bar on the left or check out these popular articles:

Popular tags within this category include: Linux , Windows , Apache , CentOS , Debian , Fedora , RedHat , and more.

Don’t see what you’re looking for? Use the search bar at the top to search our entire Knowledge Base.

The Hivelocity Difference

Seeking a better Dedicated Server solution? In the market for Private Cloud or Colocation services? Check out Hivelocity’s extensive list of products for great deals and offers.

With best-in-class customer service, affordable pricing, a wide-range of fully-customizable options, and a network like no other, Hivelocity is the hosting solution you’ve been waiting for.

Unsure which of our services is best for your particular needs? Call or live chat with one of our sales agents today and see the difference Hivelocity can make for you.

Источник

Scrolling Up and Down in the Linux Terminal

Scrolling Up and Down in the Linux Terminal

Are you looking for the technique of scrolling through your Linux terminal? Brace yourself. This article is written for you. Today you’ll learn how to scroll up and down in the Linux terminal. So, let’s begin.

Why You Need to Scroll in Linux Terminal

But before going ahead and learning about up and down scrolling in the terminal, let’s find out what’s the importance of scrolling in the Linux terminal. When you have a lot of output printed on your terminal screen, it becomes helpful to make your Linux terminal behave in a particular manner. You can clear the terminal at any time. This may make your work easier and quicker to complete. But what if you’re troubleshooting an issue and you need a previously entered command, then scrolling up or down comes to the rescue.

Various shortcuts and commands allow you to perform scrolling in the Linux terminal whenever you want. So, for easy navigation in your terminal using the keyboard, read on.

How to Scroll Up and Down in Linux Terminal

In the Linux terminal, you can scroll up by page using the Shift + PageUp shortcut. And to scroll down in the terminal, use Shift + PageDown. To go up or down in the terminal by line, use Ctrl + Shift + Up or Ctrl + Shift + Down respectively.

Key Combinations Used in Scrolling

Following are some key combinations that are useful in scrolling through the Linux terminal.

Ctrl+End: This allows you to scroll down to your cursor.

Ctrl+Page Up: This key combination lets you scroll up by one page.

Ctrl+Page Dn: This lets you scroll down by one page.

Ctrl+Line Up: To scroll up by one line, use this key combination.

Scrolling Up and Down with More Command

The more command allows you to see the text files within the command prompt. For bigger files (for example, log files), it shows one screen at one time. The more command is also used to scroll up and down within the page. To scroll up the display one line at a time, press the Enter key. To scroll a screenful at a time, use Spacebar. To do backward scrolling, press ‘b’.

Читайте также:  Gcc linux проверить версию

How to Disable Scrolling in the Terminal

To disable the scrollbar, follow the steps given in this section. First, on the window, press the Menu button residing in the top-right corner. Then select Preferences. From the Profiles section in the sidebar, select the profile you’re currently using. Then select the Scrolling option. Finally, uncheck the Show scrollbar to disable the scrolling feature in the terminal. Your preference will be saved immediately.

Scrolling on the Output

To view the latest output whenever a command is executed and produces an output, you can lock scrolling. To do this, press the Menu button. Select Preferences. Select your current profile from the Profiles section. Then select Scrolling. Check Scroll on the output option. This enables scrolling through the output on your terminal.

Scrolling on the Input

You can enable automatic scrolling to the bottom of the screen whenever a text input is given into the prompt. To do this, press the Menu button from the top-right corner. Select the Preferences option. Choose your current profile from the Profiles section. Then select Scrolling. Finally, check Scroll on keystroke. That’s how you’re able to scroll on the input.

Scrollback Lines of Output

If you want to limit the Linux terminal’s output lines to be remembered, use the limit scrollback method. To do this, press the menu button of the window. Select Preferences. In the sidebar, choose your currently using profile from the Profiles section. Next, select the Scrolling option. Check Limit scrollback to. Then give a number as input to limit scrollback. You can also click on the + sign to increase and the — sign to decrease lines.

Enable Unlimited Scrollback

To enable unlimited scrollback, follow this section. First, press the menu button. Select Preferences. Choose your current profile from the Profiles section. Select Scrolling. Then uncheck the Limit scroll back to.

Conclusion

That’s a wrap! Today we learned how to scroll up and down in our Linux terminal. We also learned about some useful key combinations that are used in scrolling, more command usages, how to disable the scrollbar, scrolling on input and output, and how to enable unlimited scrollback. Make use of this article while practicing on your terminal.

Suparna is a freelance writer who writes about Linux including tips, tricks, and how-tos.

Источник

How do you scroll up/down on the console of a Linux VM [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.

This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.

I recognize that Up / Down will give you the command history. But, how do you look at past output by scrolling up and down? I have used Shift + Page Up / Page Down , Alt + Shift + Up / Down and Page Up / Page Down but none of these seem to work. It is a Redhat Linux box.

Is that a vmware thing? If you’re not using a regular terminal emulator, you won’t have terminal functions like scrollback.

15 Answers 15

SHIFT + Page Up and SHIFT + Page Down . If it doesn’t work try this and then it should:

Читайте также:  All linux desktop environments

Go the terminal program, and make sure
Edit/Profile Preferences/Scrolling/Scrollback/Unlimited
is checked.

The exact location of this option might be somewhere different though, I see that you are using Redhat.

Only the first line of this answer is useful on the Linux console, the rest might be useful on a GUI terminal like gnome-terminal, though unlimited is not needed.

Shift + Fn + UP or DOWN on a Macbook will allow you to scroll.

Thanks for this Lauren, and thanks @anizzomc. I was on my macbook pro running Ubuntu server in virtual box and was having a heck of a time trying to figure this out.

As the comments show, this is the only correct answer. Everyone else is talking about terminal emulators, which is not what the OP is asking. It is the only thing which worked for me on Ubuntu Server 14.04 emulation in Parallels on Macbook Pro

that’s simply because your PageUp/PageDown keys are mapped to Fn+Up/Down, it won’t work in other keyboards. And Fn is not a real key that the OS recognizes (except on Macs)

Alternative: you can use the less command.

This will allow you to scroll with the up and down arrow keys.

Basically your output has been piped with the less command.

Interesting enough this was the only way that actually worked when using the shell on a FreeNAS install disk.

FreeNAS is FreeBSD based, and there you scroll differently. First you press scroll lock to get into paging mode and then use plain arrows and page up / page down to scroll. Press scroll lock again to get back to typing mode.

ALTERNATIVE FOR LINE-BY-LINE SCROLLING

Ctrl + Shift + Up Arrow or Down Arrow

Unlike Shift + Page Up or Page Down , which scrolls the entire page, this will help with a smoother line-by-line scrolling, which is exactly what I was looking for.

SHIFT + Page Up and SHIFT + Page Down are the correct keys to operate on the linux (virtual) console, but vmware console doesn’t have those terminal settings. The virtual console has fixed scroll back size, it sounds like it’s limited to video memory size according to this Linux virtual console Scrolling behavior documentation.

In order to prevent the Matthew Effect, from now on I will try to upvote the second and correct answer to encourage ppl to answer the questions who already have a correct answer.

Another alternative, that might be already installed on your system is to use GNU screen :

# This starts screen which adds basic window management in terminals screen # This starts the copy mode you can use to scroll [ # Now use the arrows to scroll # To exit copy mode, do

See man screen for much more useful options (multiple windows, . ).

Shift Pageup/End works for me.

It seems as though this is not easily possible: The Arch Linux Wiki lists no way to do this on the console (while easily possible on the virtual terminal).

Ctrl — b then [ then you can use your normal navigation keys to scroll around (eg. Up Arrow or PgDn ). Press q to quit scroll mode.

Alternatively you can press Ctrl — b PgUp to go directly into copy mode and scroll one page up (which is what it sounds like you will want most of the time)

Источник

Оцените статью
Adblock
detector