Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unix (Cygwin) whatis: returns all commands as "nothing appropriate"

For some odd reason, the "whatis" command in my Unix shell (cygwin) is not working. It constantly returns "ls: nothing appropriate" or "cd: nothing appropriate". I'm wondering if there is something incorrectly set-up. Does anyone have any light to shed? Thanks!

like image 227
Zhouster Avatar asked Aug 02 '12 09:08

Zhouster


People also ask

What is nothing appropriate command?

If you get error “nothing appropriate” when you try using the man command, it is as a result of the man database not updated. [root@HQDEV1 ~]# man -k copy copy: nothing appropriate. The man page database needs to be updated, that's why you get “nothing appropriate”.

What is the whatis command in Linux?

whatis command in Linux is used to get a one-line manual page descriptions. In Linux, each manual page has some sort of description within it. So this command search for the manual pages names and show the manual page description of the specified filename or argument.


3 Answers

I ran into a similar issue using the 64-bit Red Hat Cygwin installation.

In my case, /usr/sbin/makewhatis did not exist. Running man and a command worked, but neither apropos nor whatis returned anything other than "nothing appropriate".

After searching for a missing package and binging a bunch, I Read The Friendly Manual page for man and found out about mandb.

Running mandb solved my problem.

like image 87
Ayeinbran Avatar answered Oct 22 '22 19:10

Ayeinbran


From the Cygwin FAQ:

Why doesn't man -k (or apropos) work?

Before you can use man -k or apropos, you must create the whatis database. Just run the command

mandb

(it may take a minute to complete).

(Note: It used to say /usr/sbin/makewhatis instead of mandb in older versions of that FAQ.)

like image 23
me_and Avatar answered Oct 22 '22 17:10

me_and


Run sudo mandb once

Not sure if this helps, but when I ran mandb, I got this (over several attempts).

mandb    
0 man subdirectories contained newer manual pages.
0 manual pages were added.
0 stray cats were added.
0 old database entries were purged.

However,

sudo mandb
75 man subdirectories contained newer manual pages.
7235 manual pages were added.
0 stray cats were added.
0 old database entries were purged.

worked for real.

like image 38
Arpit Kaushal Avatar answered Oct 22 '22 18:10

Arpit Kaushal