Search code examples
performancefreezemanpage

man shows blank screen / long time to load


A weird thing has happened to my "man" command, typing man causes man to load, but incredibly slow. As in, it first displays a new blank line, then clears the screen, then stays blank for a few minutes, finally showing up the requested information.

At first I thought it was just hanging up, so I kept Ctrl-C'ing it for a few days, then decided to fix the problem and waited for it to do something.

Once a man page has showed up, further calls to the same page are normal. Newly requested man pages do the same thing.

Googling this up just shows marketing crap / ads.

Some sort of corrupted cache being rebuilt on-demand?

Anyone has noticed similar behaviour on man?


Solution

  • The rebuild on-demand (on a very busy system) seems like a likely explanation. If it's easily reproducible, then I would do this in the window where you are going to execute man:

    tty
    

    In another window execute this script:

    while [ 1 ]; do
       clear
       date
       ps -ft ttyvalfromotherwindow
       sleep 5
    done
    

    In yet another window, do this:

    top
    

    Together you'll probably figure out what is going on.