42

I'd like to stop refreshing the list of processes. My problem is it refreshes itself too often.

How can I do it? I use htop.

Kamil Maciorowski
  • 69,815
  • 22
  • 136
  • 202
user1871996
  • 535
  • 1
  • 5
  • 6

3 Answers3

46

UPDATE: For new versions (>=3.0) of the htop check out this answer

For versions < 3.0:

Most easy way is suspending the terminal with CTRLS, and unfreezing with CTRLQ while htop or any other flowing display is running. (Thanks to Keith for this reminder of easy tip)

Also, you can change refresh interval with putting -d key before running the htop for example:

# htop -d 100

The number 100 indicates the delay between updates, in tenths of seconds. You can change the refresh interval as you like. But there is no pausing support for now.

Alternatively, you can use screen capture tools for freezing the moment in graphical interface if you are on any desktop environment. In the short hand you can press PrtScr key at any time. Or you can install and use any kind of screenshot or screen recorder applications.

Sencer H.
  • 1,290
  • 13
  • 22
  • Thank you. What if I set too many seconds and after I want refresh - exists any options how do it? – user1871996 Feb 08 '16 at 14:14
  • I have no idea if there is an option exist. But if you use `top` instead of `htop` you can change refresh interval inside the app by typing `d` key. – Sencer H. Feb 09 '16 at 08:28
  • 2
    My man says: -d --delay=DELAY Delay between updates, in tenths of seconds – cubuspl42 May 01 '16 at 14:51
  • 6
    I'm surprised nobody said just press CTRL-S – Keith Mar 09 '18 at 12:11
  • 2
    I hate CTRL-S(uspend) short cut. It freezing terminal when I push that combination accidentally. I hate it so much, that's why I never remember existence of that :D Thank you for your reminder. – Sencer H. Sep 14 '18 at 07:25
  • there is a disadvantage of ctrl+s, you cannot select and copy the output. – Wang Apr 23 '19 at 13:24
  • All of these kind of suck when you want to freeze thesnapshot and re-order/alter columns, see tree view etc. – RichieHH Jan 01 '21 at 00:19
28

In htop version 3.0+, use Shift Z inside of htop to pause process list updates. You will still be able to navigate around this way.

If you forget the shortcut, you can find it with F1 from inside htop, or externally with man htop. Just note that they denote Shift + z as just one capital letter Z.

VasyaNovikov
  • 3,366
  • 3
  • 25
  • 33
Kiparis Wa
  • 389
  • 3
  • 3
19

As Keith said:

  • Ctrl + S Freezes the terminal. (You cannot interact with htop afterwards.)

  • Ctrl + Q Unfreezes the terminal again.

grandchild
  • 291
  • 2
  • 5