First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 97541
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Gentoo's Team for Core System packages <base-system@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Mario Hein <MHein03@web.de>
Add CC:
CC:
Remove selected CCs
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
man.userdel.ltrace ltrace of man userdel text/plain Martin von Gagern 2005-07-01 07:32 0000 1.27 MB Details
man-1.6-message-order.patch man-1.6-message-order.patch patch Martin von Gagern 2005-07-01 08:49 0000 769 bytes Details | Diff
man-1.6.patch patch to man-1.6.ebuild patch Martin von Gagern 2005-07-01 08:53 0000 885 bytes Details | Diff
man-1.6a.ebuild man-1.6a.ebuild text/plain Martin von Gagern 2005-08-23 07:06 0000 2.63 KB Details
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 97541 depends on: Show dependency tree
Bug 97541 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2005-06-30 13:41 0000
When opening some man pages (userdel, rm,...), an error is reportet.
No man page appears.
I switched back to man-1.5p. Now everything is fine again...
This error occurs only to some (let me guess... 30%? of all man pages)

Reproducible: Always
Steps to Reproduce:
1.update to man-1.6
2.enter: man userdel
3.



Expected Results:  
*huh* bring me a beer?
mh... or at least show me the man page i requested

------- Comment #1 From Jakub Moc (RETIRED) 2005-06-30 13:51:51 0000 -------
`man userdel` and `man rm` both work for me; emerge --info, please. Also please
port the error you encounter.

------- Comment #2 From Carsten Lohrke 2005-07-01 05:57:19 0000 -------
There's more than one person in the german partof forums.g.o mentioning this
problem and while I don't face such issues, man pages do not get cached for me
(anymore?). The relevant category directories stay empty, even though man.conf
isn't modified not to cache and permissions are fine.

------- Comment #3 From Jakub Moc (RETIRED) 2005-07-01 06:10:24 0000 -------
Adding the forums URL.

@carlo: Speicherzugriffsfehler = error accessing memory or something like that?

------- Comment #4 From SpanKY 2005-07-01 06:36:41 0000 -------
so man-1.5p works fine ?  what do you have your language settings to ? (i dont
know because you neglected to provide `emerge info`)

------- Comment #5 From Jakub Moc (RETIRED) 2005-07-01 06:51:12 0000 -------
*** Bug 97614 has been marked as a duplicate of this bug. ***

------- Comment #6 From Lars Wendler (Polynomial-C) 2005-07-01 06:57:43 0000 -------
Hi,

Speicherzugriffsfehler = segmentation fault (imho)

Poly

------- Comment #7 From Alexander Stoll 2005-07-01 06:58:56 0000 -------
I can confirm this issue, it is triggered from locale setting, uncached man
pages with locale set to "de_DE@euro" cause a segfault of /usr/bin/man, cached
man pages and uncached man pages with locale set to "en_EN" show up properly...

Please mask version 1.6 and test this package further, version 1.5p lacks no
vital features and having no functional man pages is really annoying...

Gentoo Base System version 1.6.12
Portage 2.0.51.19 (default-linux/x86/2005.0, gcc-3.3.5-20050130, glibc-2.3.4.200
41102-r1, 2.4.31-grsec i686)
=================================================================
System uname: 2.4.31-grsec i686 Pentium III (Katmai)
Python:              dev-lang/python-2.3.5 [2.3.5 (#1, Apr 30 2005, 16:53:41)]
dev-lang/python:     2.3.5
sys-apps/sandbox:    [Not Present]
sys-devel/autoconf:  2.59-r6, 2.13
sys-devel/automake:  1.7.9-r1, 1.8.5-r3, 1.5, 1.4_p6, 1.6.3, 1.9.5
sys-devel/binutils:  2.15.92.0.2-r10
sys-devel/libtool:   1.5.16
virtual/os-headers:  2.6.8.1-r2
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-O3 -march=pentiumpro -fomit-frame-pointer -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/
config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O3 -march=pentiumpro -fomit-frame-pointer -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms strict"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/Linux/
distributions/gentoo"
LC_ALL="de_DE@euro"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 activefilter bitmap-fonts bzlib crypt ctype dbm emboss erandom ethereal
 flatfile fortran ftp gdbm gnutls hardened icc ifc maildir mbox memlimit mhash m
ime mmap mmx mp3 mysqli ncurses nls pam pcntl pcre perl pic pie posix readline r
ecode sasl shared sharedmem slang sockets socks5 sse ssl sysvipc szip tcpd truet
ype-fonts type1-fonts unicode zlib userland_GNU kernel_linux elibc_glibc"
Unset:  ASFLAGS, CBUILD, CTARGET, LANG, LDFLAGS, LINGUAS, PORTDIR_OVERLAY

------- Comment #8 From Martin von Gagern 2005-07-01 07:32:30 0000 -------
Created an attachment (id=62407) [edit]
ltrace of man userdel

1. LANG=de_DE man userdel => SEGFAULT
2. LANG=      man userdel => works
3. LANG=de_DE man userdel => works
4. rm /var/cache/man/cat8/userdel.8.bz2
5. LANG=de_DE ltrace -s255 man userdel => attached

The segfault occurs in vfprintf, the message translates to:
"File %s could not be opened for output"

------- Comment #9 From Martin von Gagern 2005-07-01 08:49:54 0000 -------
Created an attachment (id=62412) [edit]
man-1.6-message-order.patch

OK, here ist the solution. Those guys added some messages in the english
message file only, and not at the end but somewhere in between, with the
messages identified by position. So man got the wrong message, one containing a
%s where no argument was supplied in the call, resulting in this segmentation
fault.

I'll try to take this upstream as well.

------- Comment #10 From Martin von Gagern 2005-07-01 08:53:52 0000 -------
Created an attachment (id=62413) [edit]
patch to man-1.6.ebuild

Patch ebuild to apply attachment 62412 [edit] and solve bug 97612 as well.

------- Comment #11 From Alessio Cassibba (X-Drum) 2005-07-02 08:27:37 0000 -------
*** Bug 97721 has been marked as a duplicate of this bug. ***

------- Comment #12 From SpanKY 2005-07-02 10:38:55 0000 -------
have you e-mailed upstream yet ?  if not i can do so ...

------- Comment #13 From Jakub Moc (RETIRED) 2005-07-03 03:27:31 0000 -------
*** Bug 97803 has been marked as a duplicate of this bug. ***

------- Comment #14 From Martin von Gagern 2005-07-03 14:59:30 0000 -------
(in reply to comment #12)
July 1 I did send an email to flucifredi at acm. No reply so far. But It's been
weekend, so let's wait a hope for the best.
In the meantime I think you should apply the patch at distribution level, since
those segfaults are rather annoying to ~ARCH users.

------- Comment #15 From Marek Kwasceki 2005-07-05 07:05:48 0000 -------
so now is two days since last post and no sign of amend in emerge?

------- Comment #16 From Martin von Gagern 2005-07-05 07:51:58 0000 -------
Still no news from upstream. SpanKY, perhaps you can give this issue more
weight
by sending an email as well, as you offered in comment #12.
Anyway, I fear this might take some time, so please include the patch in
portage.

------- Comment #17 From Martin von Gagern 2005-07-05 14:20:38 0000 -------
Mail from the upstream maintainer; he'll look into it next week.

------- Comment #18 From Roel Brook 2005-07-05 18:58:18 0000 -------
there's something odd here:

Medusa% man dig
zsh: segmentation fault  man dig
Medusa% strace man dig
<snip>
open("/usr/share/locale/nl_NL@euro/LC_MESSAGES/man", O_RDONLY) = -1 ENOENT (No
such file or directory)
open("/usr/share/locale/nl/man", O_RDONLY) = 4
fstat64(4, {st_mode=S_IFREG|0644, st_size=6000, ...}) = 0
mmap2(NULL, 6000, PROT_READ, MAP_PRIVATE, 4, 0) = 0xa7e32000
close(4)                                = 0
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV +++
Medusa% strace man dig > bla
<snip>
Medusa% cat bla
DIG(1)                                                                  DIG(1)



NAME
       dig - DNS lookup utility
<snip>
BUGS
       There are probably too many query options.



BIND9                            Jun 30, 2000                           DIG(1)

The man page does show up!

LC_ALL = nl_NL@euro

"info dig" also works. Because info can also show man pages, this can be used as
a temporary workaround.

------- Comment #19 From Martin von Gagern 2005-07-06 01:29:12 0000 -------
As far as I could see from gripes.c, the precedence of locale environment
variables is reversed for man; LANG has precedence over LC_MESSAGES has
precedence over LC_ALL. I think I'll report this as a bug upstream as well.

(in reply to comment #18)
Please also state the settings of those other variables. It would be also
interesting which of those operations were executed as root and which as a
normal user. Because man is usually setgid man to access the man page cache, it
should by impossible to strace man as a normal user. And for root you usually
should not have set locale, so probably the page got formatted correctly while
stracing as root? The message when man failed for me was about the man page
being formatted, so for all pages that were already in the cache, man worked
fine. To reproduce the bug, you might have to remove
/var/cache/man/cat8/userdel.8.bz2.

------- Comment #20 From Roel Brook 2005-07-06 15:59:13 0000 -------
you're right:

Medusa% man dig
zsh: segmentation fault  man dig
Medusa% sudo man dig
Formatting page, please wait...
<man page displays correctly>


Medusa% cat /etc/env.d/02locale
LC_ALL=nl_NL@euro
LANG=nl_NL@euro
LANGUAGE=nl_NL@euro
LINGUAS="nl"

All of the commands in #18 were done as a normal user. The enviroment settings
for all users on my system are the same:

Medusa% echo $LANG
nl_NL@euro
Medusa% echo $LC_MESSAGES

Medusa% echo $LC_ALL
nl_NL@euro
Medusa% su
Password:
Medusa# echo $LANG
nl_NL@euro
Medusa# echo $LC_MESSAGES

Medusa# echo $LC_ALL
nl_NL@euro

setting the LC_MESSAGES enviroment variable fixed it for me as normal user:
Medusa% LC_MESSAGES="nl_NL@euro" man dig
<page displays correctly!>
Medusa% LC_MESSAGES="aaaa" man dig
<page displays correctly>

I guess this is the whole problem: LC_MESSAGES should be set (or at least, not
be blank, except for the root user.

After adding LC_MESSAGES="nl_NL@euro" to /etc/env.d/02locale, I can use man
again. (without the patch)

------- Comment #21 From Martin von Gagern 2005-07-06 16:14:25 0000 -------
There is some strange behaviour in the man sources with respect to which
environment variables are used where. Notice that LC_ALL is AFAIK indended as an
override; you set this only if you simply want to switch "everything"
temporarily. Otherwise you set LANG for defaults, and can fine tune different
locale categories by setting different LC_* variables to other settings. So LANG
is default, LC_* is more specific, and LC_ALL is override. All those settings
are neatly printed by locale(1p), which is a lot easier than echoing all those
variables manually.

A simple "su" takes large portions of the user environment with it, the cleaner
approach would be "su -", which might set those settings differently.

I'm still surprised that simply setting LC_MESSAGES seems to solve the problem
for you. I know from the sources that it will still fail if it tries to display
some unlucky message. Somehow setting this variable seems to have deactivated
output of those messages during default operation for you. Strange. But I don't
believe this to be a viable workaround for everybody.

So please include patch in portage soon! I met another bunch of people today who
"solved" the issue by removing the category subdirs of the cache, thus
suppressing the "formatting..." message. But this is not the way it should be.

------- Comment #22 From Kamil Gornik 2005-07-08 00:40:07 0000 -------
nope, 
/home/heimat> locale
LANG=pl_PL
LC_CTYPE="pl_PL"
LC_NUMERIC="pl_PL"
LC_TIME="pl_PL"
LC_COLLATE="pl_PL"
LC_MONETARY="pl_PL"
LC_MESSAGES="pl_PL"
LC_PAPER="pl_PL"
LC_NAME="pl_PL"
LC_ADDRESS="pl_PL"
LC_TELEPHONE="pl_PL"
LC_MEASUREMENT="pl_PL"
LC_IDENTIFICATION="pl_PL"
LC_ALL=pl_PL
 (the same for root) 

and 
>man fdisk segfaults (user)
#man [sth] segfaults (root)

------- Comment #23 From SpanKY 2005-07-09 15:49:07 0000 -------
added to man-1.6-r1

please post any updates you receive from the man author, thanks

------- Comment #24 From Jakub Moc (RETIRED) 2005-07-11 04:28:59 0000 -------
*** Bug 98643 has been marked as a duplicate of this bug. ***

------- Comment #25 From Martin von Gagern 2005-08-23 07:06:15 0000 -------
Created an attachment (id=66650) [edit]
man-1.6a.ebuild

Frederico Lucifredi released a minor fix, man-1.6a, to address this bug as well
as the parallel make issue. The attached ebuild seems to work, although it
perhaps should be tested some more.

Frederico wrote that he is "planning to review the internationalization and
coherence of the environment use in the upcoming minor releases".

------- Comment #26 From SpanKY 2005-08-23 10:44:44 0000 -------
1.6a is already in portage :P

First Last Prev Next    No search results available      Search page      Enter new bug