public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug localedata/5033] locarchive does not provide fallback for mmap()
       [not found] <bug-5033-131@http.sourceware.org/bugzilla/>
@ 2012-02-21 14:44 ` junkmailnotread at yahoo dot com
  2012-02-21 16:51 ` bugdal at aerifal dot cx
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 7+ messages in thread
From: junkmailnotread at yahoo dot com @ 2012-02-21 14:44 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=5033

junkmailnotread at yahoo dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |junkmailnotread at yahoo
                   |                            |dot com

--- Comment #1 from junkmailnotread at yahoo dot com 2012-02-21 14:42:33 UTC ---
This is a serious bug and still present in glibc-2.13. Why no progress?

To clarify, localedef *fails* if /usr/lib/locale/locale-archive is located on a
file system - such as JFFS2 - which does not support the mmap(2) MAP_SHARED
flag.

As far as I can tell, any Linux kernel file system whose mmap handler is:
generic_file_readonly_mmap()
does not support MAP_SHARED. Currently, as of linux-3.3, these include:

9p
afs
jffs2
logfs

The bug is easy to demonstrate. Here, the root file system is a JFFS2 file
system, and /var/tmp is a tmpfs file system:

# ls -l /usr/lib/locale
total 0
# df /usr/lib/locale
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/root                78592     27816     50776  36% /
# localedef -f ISO-8859-1 -i en_GB en_GB.ISO-8859-1
cannot map archive header: Invalid argument
# rmdir /usr/lib/locale
# ln -s /var/tmp /usr/lib/locale
# df /usr/lib/locale
Filesystem           1K-blocks      Used Available Use% Mounted on
none                     30664        24     30640   1% /var
# localedef -f ISO-8859-1 -i en_GB en_GB.ISO-8859-1
# localedef --list
en_GB.iso88591
# 

I've just spent a day tracking this bug down, only to discover it was reported
over 4 years ago.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug localedata/5033] locarchive does not provide fallback for mmap()
       [not found] <bug-5033-131@http.sourceware.org/bugzilla/>
  2012-02-21 14:44 ` [Bug localedata/5033] locarchive does not provide fallback for mmap() junkmailnotread at yahoo dot com
@ 2012-02-21 16:51 ` bugdal at aerifal dot cx
  2012-02-21 20:57 ` dwmw2 at infradead dot org
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 7+ messages in thread
From: bugdal at aerifal dot cx @ 2012-02-21 16:51 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=5033

Rich Felker <bugdal at aerifal dot cx> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bugdal at aerifal dot cx

--- Comment #2 from Rich Felker <bugdal at aerifal dot cx> 2012-02-21 16:49:24 UTC ---
I would say it's a serious kernel bug for MAP_SHARED to fail on any ordinary
file. The type of filesystem it's on should not matter. Unfortunately the
kernel has lots of bugs like this and they seem to be treated somewhere between
lowest-priority and WONTFIX...

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug localedata/5033] locarchive does not provide fallback for mmap()
       [not found] <bug-5033-131@http.sourceware.org/bugzilla/>
  2012-02-21 14:44 ` [Bug localedata/5033] locarchive does not provide fallback for mmap() junkmailnotread at yahoo dot com
  2012-02-21 16:51 ` bugdal at aerifal dot cx
@ 2012-02-21 20:57 ` dwmw2 at infradead dot org
  2012-02-21 22:52 ` bugdal at aerifal dot cx
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 7+ messages in thread
From: dwmw2 at infradead dot org @ 2012-02-21 20:57 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=5033

--- Comment #3 from David Woodhouse <dwmw2 at infradead dot org> 2012-02-21 20:54:39 UTC ---
No, it's quite expected that some file systems don't support shared writable
mmap.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug localedata/5033] locarchive does not provide fallback for mmap()
       [not found] <bug-5033-131@http.sourceware.org/bugzilla/>
                   ` (2 preceding siblings ...)
  2012-02-21 20:57 ` dwmw2 at infradead dot org
@ 2012-02-21 22:52 ` bugdal at aerifal dot cx
  2012-02-22  9:47 ` dwmw2 at infradead dot org
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 7+ messages in thread
From: bugdal at aerifal dot cx @ 2012-02-21 22:52 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=5033

--- Comment #4 from Rich Felker <bugdal at aerifal dot cx> 2012-02-21 22:51:54 UTC ---
Per POSIX:

The mmap() function shall be supported for the following memory objects:

  Regular files

  [SHM][X>  Shared memory objects <X]

  [TYM][X>  Typed memory objects <X]

No exception is made that says MAP_SHARED need not work for certain regular
files, so I interpret this as meaning that a system on which some filesystems
do not support MAP_SHARED is non-conformant.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug localedata/5033] locarchive does not provide fallback for mmap()
       [not found] <bug-5033-131@http.sourceware.org/bugzilla/>
                   ` (3 preceding siblings ...)
  2012-02-21 22:52 ` bugdal at aerifal dot cx
@ 2012-02-22  9:47 ` dwmw2 at infradead dot org
  2013-10-17 12:09 ` neleai at seznam dot cz
  2015-08-27 21:56 ` [Bug locale/5033] " jsm28 at gcc dot gnu.org
  6 siblings, 0 replies; 7+ messages in thread
From: dwmw2 at infradead dot org @ 2012-02-22  9:47 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=5033

--- Comment #5 from David Woodhouse <dwmw2 at infradead dot org> 2012-02-22 09:47:27 UTC ---
But mmap() *is* supported on this object. It's just that PROT_WRITE isn't
supported, in conjunction with MAP_SHARED. Perhaps we should return ENOTSUP for
a PROT_WRITE shared mapping?

And whatever POSIX says, this is a common behaviour from file systems and it's
easy to work cope with. Why *wouldn't* we?

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug localedata/5033] locarchive does not provide fallback for mmap()
       [not found] <bug-5033-131@http.sourceware.org/bugzilla/>
                   ` (4 preceding siblings ...)
  2012-02-22  9:47 ` dwmw2 at infradead dot org
@ 2013-10-17 12:09 ` neleai at seznam dot cz
  2015-08-27 21:56 ` [Bug locale/5033] " jsm28 at gcc dot gnu.org
  6 siblings, 0 replies; 7+ messages in thread
From: neleai at seznam dot cz @ 2013-10-17 12:09 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=5033

Ondrej Bilka <neleai at seznam dot cz> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |neleai at seznam dot cz

--- Comment #6 from Ondrej Bilka <neleai at seznam dot cz> ---
Main problem here is lack of resources, If you come with patch that adds a
fallback it would be welcome.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug locale/5033] locarchive does not provide fallback for mmap()
       [not found] <bug-5033-131@http.sourceware.org/bugzilla/>
                   ` (5 preceding siblings ...)
  2013-10-17 12:09 ` neleai at seznam dot cz
@ 2015-08-27 21:56 ` jsm28 at gcc dot gnu.org
  6 siblings, 0 replies; 7+ messages in thread
From: jsm28 at gcc dot gnu.org @ 2015-08-27 21:56 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=5033

Joseph Myers <jsm28 at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|localedata                  |locale

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2015-08-27 21:56 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-5033-131@http.sourceware.org/bugzilla/>
2012-02-21 14:44 ` [Bug localedata/5033] locarchive does not provide fallback for mmap() junkmailnotread at yahoo dot com
2012-02-21 16:51 ` bugdal at aerifal dot cx
2012-02-21 20:57 ` dwmw2 at infradead dot org
2012-02-21 22:52 ` bugdal at aerifal dot cx
2012-02-22  9:47 ` dwmw2 at infradead dot org
2013-10-17 12:09 ` neleai at seznam dot cz
2015-08-27 21:56 ` [Bug locale/5033] " jsm28 at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).