PDA

View Full Version : Man pages not working



mlangdn
08-10-2003, 08:56 PM
[michael@localhost michael]$ man less
sh: line 1: /usr/bin/less: No such file or directory
Error executing formatting or display command.
System command (cd /usr/share/man && (echo ".pl 1100i"; /usr/bin/bzip2 -c -d '/usr/share/man/man1/less.1.bz2'; echo; echo ".pl \n(nlu+10") | /usr/bin/gtbl | /usr/bin/nroff -mandoc -c | /usr/bin/less -isrR) exited with status 127.
No manual entry for less
[michael@localhost michael]$


This is what happened when trying to access man pages. Any man command request returns this.

Anybody know what happened here? Could this be related to a freeze that happened last week and the subsequent error fix that Mandrake did?

Grogan
08-10-2003, 09:09 PM
Heheh, it appears that you are missing the less program itself. The man program uses that to display the text. It does that... actually initiates a bunch of shell commands and the end result is a scrollable man page.

Coincidence that it's the very program you're trying to read the man page for :-)

The program less probably comes in an rpm package of it's own. Go to your RPMS directory on the Mandrake CD and find it. Force it to install.

P.S. Yes, I think you lost some data during that episode. You're only now starting to discover what's broken. Probably nothing that can't be fixed, as discovered.

BobGuy
08-10-2003, 09:15 PM
Pull up a /dev/chair and lets see what you have.

ls -la /usr/bin/less
-rwxr-xr-x 1 root root 118 Feb 4 2003 /usr/bin/less*

And

rpm -qa | grep less
less-381-1mdk
lesstif-0.93.36-2mdk

Do this as a user, if you get nothing then try it as su -, as the permissions may be all thats messed up.

Thats what I have and 'less' works here, so yep sounds like yours is b0rked.


Any man command request returns this.
Sounds like you just don't have permission to open - use anything, but root would have if the packages are still there.

Grogan
08-10-2003, 09:22 PM
Bob... top of the list. "sh: line1: /usr/bin/less: No such file or directory"

I'm not just guessing here, that's a real clue.

Yes, if he queries the rpm database the rpm will still show as being installed, because it indeed was. Useless... because files are missing.

mlangdn
08-10-2003, 09:25 PM
Grogan and Bob,

The packages are still there, but it does not work. After this episode, my Euphoria screensaver did not work and it was there. I fixed it by removing the packages for the screensavers, then re-installing the packages. I will do the same for the man pages and the less package, and any others that I find corrupted. Can't be too many as I have not noticed much wrong. Other than this, everything has been pretty smooth.

Thanks Guys,

Mike

Grogan
08-10-2003, 09:27 PM
Mike, just start with the less package. No need to do Man, because the man program is indeed there.

You may find other supporting files missing too, but cross that bridge when you come to it.

mlangdn
08-10-2003, 09:38 PM
Ok, Thanks

BobGuy
08-10-2003, 09:59 PM
Just curious Mike, what filesystem are you using?

ext3, reisersfs etc?

Yeah, Grogan I see what you mean now, I just did:

$ cat /etc/shadow
cat: /etc/shadow: Permission denied

$ cat /usr/bin/less
#!/bin/sh

#export LESSCHARSET="${LESSCHARSET:-utf-8}"
export LESSCHARSET="${LESSCHARSET:-koi8-r}"
exec less.bin "$@"
$

Learn something new everyday, thanks for clarifying. :D

Grogan
08-10-2003, 10:05 PM
Huh... learn something new every day indeed. Your "less" isn't even a program. It's a shell script that sets variables and runs less.bin (the real program)

Fucking Mandrake, I tell ya :-)

If less.bin is present, mlangdn could probably just paste the contents of your /usr/bin/less script, save it as /usr/bin/less and chmod +x it.

NightShade737
08-11-2003, 04:05 AM
Er..... shouldn't it be

more filename | less

?

NS

Grogan
08-11-2003, 10:52 AM
Originally posted by NightShade737
Er..... shouldn't it be

more filename | less

?

NS

less is a replacement for more, that allows scrolling in both directions.

You can simply type less filename or whatevercommand | less to control output.

There is no need to use both more and less in the same command.

NightShade737
08-11-2003, 12:54 PM
Eh? Oh, I phrased that really badly, and used the wrong command.

What I meant was.....

ls -a | less

that makes more sence. But anyway, the actual point of my post was, doesn't he need a " | " in there?

NS

Grogan
08-11-2003, 01:57 PM
Originally posted by NightShade737
Eh? Oh, I phrased that really badly, and used the wrong command.

What I meant was.....

ls -a | less

that makes more sence. But anyway, the actual point of my post was, doesn't he need a " | " in there?

NS

Not in this case, because he was trying to get a long listing for the less program itself (to check for it's presence, and permissions)

bash-2.05b$ ls -l /usr/bin/less
-rwxr-xr-x 1 root bin 104324 Feb 14 02:40 /usr/bin/less

But yes, if using less to manage the output of a directory listing, it would of course need a pipe.

mlangdn
08-11-2003, 07:52 PM
Bob, file system is ext3.

No man command has worked as of yet. It returns the same as for less in a previous post. I have tried less, more, whatis...etc... Nothing anywhere. If I type "man catshit", it just returns "no manual entry for catshit".

Gonna backup some downloaded stuff and format, then re-install.

Takin' the easy way out.

Mike

:rollout: