How to read the output from an interactive program without it scrolling off the screen?
Clash Royale CLAN TAG#URR8PPP
up vote
1
down vote
favorite
I am running fdisk
on a device and I'm trying to list the supported partition types. The problem is that it immediately scrolls off the screen and I can't see it.
I was using the latest Fedora on someone's Macbook yesterday and fdisk would pause with a :
(like the output of less
and allow scrolling or q
to break from the output.
I am running CentOS 7.5 in text mode from a minimal install on a VGA monitor connected through an HDMI adapter to the system.
Is this a limitation of my terminal, being in text mode (fdisk on the Macbook was run in a terminal on GNOME), the fact that it's an older version of fdisk, or something else entirely?
centos fdisk
add a comment |
up vote
1
down vote
favorite
I am running fdisk
on a device and I'm trying to list the supported partition types. The problem is that it immediately scrolls off the screen and I can't see it.
I was using the latest Fedora on someone's Macbook yesterday and fdisk would pause with a :
(like the output of less
and allow scrolling or q
to break from the output.
I am running CentOS 7.5 in text mode from a minimal install on a VGA monitor connected through an HDMI adapter to the system.
Is this a limitation of my terminal, being in text mode (fdisk on the Macbook was run in a terminal on GNOME), the fact that it's an older version of fdisk, or something else entirely?
centos fdisk
doesn't Shift-PageUp work anymore?
– mosvy
Nov 30 at 1:58
That's a thought - but he's using a MacBook (take a look at the keyboard). If it's recent hardware: no, he doesn't have that key :-)
– Thomas Dickey
Nov 30 at 2:07
2
Oops. But If Fn+Shift+Up doesn't work instead of Shift+PageUp, it's a bug.
– mosvy
Nov 30 at 2:18
Most terminal emulators have scrollback.
– D. Ben Knoble
Nov 30 at 4:15
add a comment |
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I am running fdisk
on a device and I'm trying to list the supported partition types. The problem is that it immediately scrolls off the screen and I can't see it.
I was using the latest Fedora on someone's Macbook yesterday and fdisk would pause with a :
(like the output of less
and allow scrolling or q
to break from the output.
I am running CentOS 7.5 in text mode from a minimal install on a VGA monitor connected through an HDMI adapter to the system.
Is this a limitation of my terminal, being in text mode (fdisk on the Macbook was run in a terminal on GNOME), the fact that it's an older version of fdisk, or something else entirely?
centos fdisk
I am running fdisk
on a device and I'm trying to list the supported partition types. The problem is that it immediately scrolls off the screen and I can't see it.
I was using the latest Fedora on someone's Macbook yesterday and fdisk would pause with a :
(like the output of less
and allow scrolling or q
to break from the output.
I am running CentOS 7.5 in text mode from a minimal install on a VGA monitor connected through an HDMI adapter to the system.
Is this a limitation of my terminal, being in text mode (fdisk on the Macbook was run in a terminal on GNOME), the fact that it's an older version of fdisk, or something else entirely?
centos fdisk
centos fdisk
asked Nov 30 at 1:33
Zhro
342313
342313
doesn't Shift-PageUp work anymore?
– mosvy
Nov 30 at 1:58
That's a thought - but he's using a MacBook (take a look at the keyboard). If it's recent hardware: no, he doesn't have that key :-)
– Thomas Dickey
Nov 30 at 2:07
2
Oops. But If Fn+Shift+Up doesn't work instead of Shift+PageUp, it's a bug.
– mosvy
Nov 30 at 2:18
Most terminal emulators have scrollback.
– D. Ben Knoble
Nov 30 at 4:15
add a comment |
doesn't Shift-PageUp work anymore?
– mosvy
Nov 30 at 1:58
That's a thought - but he's using a MacBook (take a look at the keyboard). If it's recent hardware: no, he doesn't have that key :-)
– Thomas Dickey
Nov 30 at 2:07
2
Oops. But If Fn+Shift+Up doesn't work instead of Shift+PageUp, it's a bug.
– mosvy
Nov 30 at 2:18
Most terminal emulators have scrollback.
– D. Ben Knoble
Nov 30 at 4:15
doesn't Shift-PageUp work anymore?
– mosvy
Nov 30 at 1:58
doesn't Shift-PageUp work anymore?
– mosvy
Nov 30 at 1:58
That's a thought - but he's using a MacBook (take a look at the keyboard). If it's recent hardware: no, he doesn't have that key :-)
– Thomas Dickey
Nov 30 at 2:07
That's a thought - but he's using a MacBook (take a look at the keyboard). If it's recent hardware: no, he doesn't have that key :-)
– Thomas Dickey
Nov 30 at 2:07
2
2
Oops. But If Fn+Shift+Up doesn't work instead of Shift+PageUp, it's a bug.
– mosvy
Nov 30 at 2:18
Oops. But If Fn+Shift+Up doesn't work instead of Shift+PageUp, it's a bug.
– mosvy
Nov 30 at 2:18
Most terminal emulators have scrollback.
– D. Ben Knoble
Nov 30 at 4:15
Most terminal emulators have scrollback.
– D. Ben Knoble
Nov 30 at 4:15
add a comment |
2 Answers
2
active
oldest
votes
up vote
1
down vote
The latest Fedora is newer by a year or two than the latest RHEL 7. A newer fdisk
is a possibility.
You could work around this by using script
to capture the output, and using less
on the resulting typescript
file (running fdisk
and less
separately of course).
You could also use the scrolling feature in screen
or tmux
, but those typically are not installed initially on a Linux system — they're optional/extra features.
He's talking Fedora and CentOS - both do that.
– Thomas Dickey
Nov 30 at 1:59
add a comment |
up vote
0
down vote
Would
fdisk /dev/sdc <<<l | less
do?
add a comment |
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
The latest Fedora is newer by a year or two than the latest RHEL 7. A newer fdisk
is a possibility.
You could work around this by using script
to capture the output, and using less
on the resulting typescript
file (running fdisk
and less
separately of course).
You could also use the scrolling feature in screen
or tmux
, but those typically are not installed initially on a Linux system — they're optional/extra features.
He's talking Fedora and CentOS - both do that.
– Thomas Dickey
Nov 30 at 1:59
add a comment |
up vote
1
down vote
The latest Fedora is newer by a year or two than the latest RHEL 7. A newer fdisk
is a possibility.
You could work around this by using script
to capture the output, and using less
on the resulting typescript
file (running fdisk
and less
separately of course).
You could also use the scrolling feature in screen
or tmux
, but those typically are not installed initially on a Linux system — they're optional/extra features.
He's talking Fedora and CentOS - both do that.
– Thomas Dickey
Nov 30 at 1:59
add a comment |
up vote
1
down vote
up vote
1
down vote
The latest Fedora is newer by a year or two than the latest RHEL 7. A newer fdisk
is a possibility.
You could work around this by using script
to capture the output, and using less
on the resulting typescript
file (running fdisk
and less
separately of course).
You could also use the scrolling feature in screen
or tmux
, but those typically are not installed initially on a Linux system — they're optional/extra features.
The latest Fedora is newer by a year or two than the latest RHEL 7. A newer fdisk
is a possibility.
You could work around this by using script
to capture the output, and using less
on the resulting typescript
file (running fdisk
and less
separately of course).
You could also use the scrolling feature in screen
or tmux
, but those typically are not installed initially on a Linux system — they're optional/extra features.
edited Nov 30 at 1:51
answered Nov 30 at 1:44
Thomas Dickey
51.8k594164
51.8k594164
He's talking Fedora and CentOS - both do that.
– Thomas Dickey
Nov 30 at 1:59
add a comment |
He's talking Fedora and CentOS - both do that.
– Thomas Dickey
Nov 30 at 1:59
He's talking Fedora and CentOS - both do that.
– Thomas Dickey
Nov 30 at 1:59
He's talking Fedora and CentOS - both do that.
– Thomas Dickey
Nov 30 at 1:59
add a comment |
up vote
0
down vote
Would
fdisk /dev/sdc <<<l | less
do?
add a comment |
up vote
0
down vote
Would
fdisk /dev/sdc <<<l | less
do?
add a comment |
up vote
0
down vote
up vote
0
down vote
Would
fdisk /dev/sdc <<<l | less
do?
Would
fdisk /dev/sdc <<<l | less
do?
answered Nov 30 at 18:47
RudiC
3,7171312
3,7171312
add a comment |
add a comment |
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f485049%2fhow-to-read-the-output-from-an-interactive-program-without-it-scrolling-off-the%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
doesn't Shift-PageUp work anymore?
– mosvy
Nov 30 at 1:58
That's a thought - but he's using a MacBook (take a look at the keyboard). If it's recent hardware: no, he doesn't have that key :-)
– Thomas Dickey
Nov 30 at 2:07
2
Oops. But If Fn+Shift+Up doesn't work instead of Shift+PageUp, it's a bug.
– mosvy
Nov 30 at 2:18
Most terminal emulators have scrollback.
– D. Ben Knoble
Nov 30 at 4:15