LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   How to limit/control console output? (https://www.linuxquestions.org/questions/linux-newbie-8/how-to-limit-control-console-output-357531/)

jaristr 08-27-2005 12:15 PM

How to limit/control console output?
 
Hi. I suppose this has been asked before but I can't find the answer so I'll just ask.
I am trying to use sfdisk but it prints too much in the console at a time so that you cant see whole output. Is there any way to limit the output?
I cannot scroll because this does not happen in x server.

Thank you!

kpachopoulos 08-27-2005 12:21 PM

Use a pipe: commannd | more. Then u can press enter to see the next page.

Nylex 08-27-2005 12:21 PM

You could use a pipe (|) and the "more" or "less" commands, eg. "sfdisk | less". See "man less" and "man more" for more info.

jrdioko 08-27-2005 12:42 PM

But remember, less is more than more :) (it lets you scroll up in addition to down).

jaristr 08-27-2005 11:45 PM

Great, thank you!

Grasshopper 08-28-2005 03:10 PM

I use <shift> + <Page Up> or <Shift>+<Page Down> to scroll around in a console session. It works for me under X when using the command line or from a conventional console without X running. Also you can use <shift> + <up arrow> and <shift> + <down arrow> to move one line at a time in the desired direction.

These commands have the benefit of allowing you to view output that has passed your viewable area even if you forgot to call the command with "less" or "more".


All times are GMT -5. The time now is 08:39 PM.