LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-30-2017, 11:57 PM   #1
bernalheights
LQ Newbie
 
Registered: May 2017
Posts: 2

Rep: Reputation: Disabled
'Man' command does not work "No manual entry for ls"


Hi, would love some help:

I am using the most recent version of Ubuntu. I am trying to use the 'man' command, however no matter what I type the response is:

daria@daria-MacBookPro:/usr/bin$ man ls
No manual entry for ls
See 'man 7 undocumented' for help when manual pages are not available.
daria@daria-MacBookPro:/usr/bin$ man 7 undocumented
No manual entry for undocumented in section 7
daria@daria-MacBookPro:/usr/bin$

No idea what to do about this. Some things I have tried from other threads, that I don't entirely know how to interpret:

daria@daria-MacBookPro:/usr/bin$ which man
/usr/bin/man

daria@daria-MacBookPro:/usr/bin$ mandb
mandb: warning: $MANPATH set, ignoring /etc/manpath.config
0 man subdirectories contained newer manual pages.
0 manual pages were added.
0 stray cats were added.
0 old database entries were purged.


daria@daria-MacBookPro:/usr/bin$ $echo $MANPATH
bash: /usr/local/man:/usr/local/mysql/man:/usr/local/git/man:/usr/local/man: No such file or directory

is this because man is in /usr/bin/man but the path is /usr/local/man? if so, how do I fix this?

Thank you
 
Old 05-31-2017, 12:36 AM   #2
Shadow_7
Senior Member
 
Registered: Feb 2003
Distribution: debian
Posts: 4,137
Blog Entries: 1

Rep: Reputation: 873Reputation: 873Reputation: 873Reputation: 873Reputation: 873Reputation: 873Reputation: 873
You can temporarily override it.

$ MANPATH=/usr/share/man man ls

package coreutils has file /usr/share/man/man1/ls.1.gz, so at worse?

$ man /usr/share/man/man1/ls.1.gz

or

$ man 1 ls

depending on how retro your utilities are. My man man shows /etc/manpath.config to contain the default paths.

$ cat /etc/manpath.config | grep -v ^#

The grep to omit comments. But maybe a debian-ism. You could also:

$ unset MANPATH

If the warning --- mandb: warning: $MANPATH set, ignoring /etc/manpath.config --- is of concern.

$ which man

To see what location is being assumed for your binary. Or just full path it:

$ /usr/bin/man ls

To check for embellishments you might try:

$ alias man

or

$ \man

To ensure that an alias isn't used. Lots of little *nix-isms to fiddle about with.
 
1 members found this post helpful.
Old 05-31-2017, 12:47 AM   #3
bernalheights
LQ Newbie
 
Registered: May 2017
Posts: 2

Original Poster
Rep: Reputation: Disabled
Oh neat, thank you, MANPATH=/usr/share/man man ls works! How do I permanently fix the path?
 
Old 05-31-2017, 06:45 AM   #4
pan64
LQ Guru
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 16,490

Rep: Reputation: 5532Reputation: 5532Reputation: 5532Reputation: 5532Reputation: 5532Reputation: 5532Reputation: 5532Reputation: 5532Reputation: 5532Reputation: 5532Reputation: 5532
probably you need to insert it into /etc/manpath.config
 
Old 05-31-2017, 08:23 AM   #5
Shadow_7
Senior Member
 
Registered: Feb 2003
Distribution: debian
Posts: 4,137
Blog Entries: 1

Rep: Reputation: 873Reputation: 873Reputation: 873Reputation: 873Reputation: 873Reputation: 873Reputation: 873
$ export MANPATH=/usr/share/man
$ man ls

Although something is probably setting it at boot / login, and it would need to permanently be changed there. Perhaps .bashrc? Or /etc/profile? Or /etc/skel/.bashrc?
 
1 members found this post helpful.
Old 05-31-2017, 01:07 PM   #6
Shadow_7
Senior Member
 
Registered: Feb 2003
Distribution: debian
Posts: 4,137
Blog Entries: 1

Rep: Reputation: 873Reputation: 873Reputation: 873Reputation: 873Reputation: 873Reputation: 873Reputation: 873
Although the lazy in me would probably make an alias.

alias man='MANPATH=/usr/share/man man'

Looks like the ls alias is a part of my .bashrc (debian default). So that would probably need to be in .bashrc for it to persist.
 
Old 06-01-2017, 06:17 PM   #7
AwesomeMachine
LQ Guru
 
Registered: Jan 2005
Location: USA and Italy
Distribution: Debian testing/sid; OpenSuSE; Fedora; Mint
Posts: 5,513

Rep: Reputation: 1009Reputation: 1009Reputation: 1009Reputation: 1009Reputation: 1009Reputation: 1009Reputation: 1009Reputation: 1009
No, the ls alias is usually just to add color to the ls command. Aliases are sourced in .bashrc. But user-generated ones are stored in some other file.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Manual entry for gzcat abhinav4 Linux - Newbie 6 08-17-2011 06:29 PM
man -t manual | ps2pdf - > manual.pdf error Amdx2_x64 Linux - General 2 07-01-2011 03:22 AM
is there any manual entry for gcc other than man gcc akhand_jyoti Linux - Newbie 2 01-16-2010 02:13 AM
man command not working.....used to work before!!! devayani Linux - Newbie 2 09-24-2007 08:42 AM
The command man dont work Mago de Oz AIX 3 05-09-2006 03:44 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:37 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration