Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Fedora Development (http://www.linux-archive.org/fedora-development/)
-   -   Anyone have any idea why apps are starting to search /proc/sys/vm? (http://www.linux-archive.org/fedora-development/710055-anyone-have-any-idea-why-apps-starting-search-proc-sys-vm.html)

Daniel J Walsh 10-06-2012 11:44 AM

Anyone have any idea why apps are starting to search /proc/sys/vm?
 
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

https://bugzilla.redhat.com/show_bug.cgi?id=863258
https://bugzilla.redhat.com/show_bug.cgi?id=863257
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/

iEYEARECAAYFAlBwGYAACgkQrlYvE4MpobNXbgCeIK9DN+1wU3 bO6cRneC4O7U9q
rIYAoOX+qkNDvkaZD2xPFBgVyBeCfXeD
=CRP0
-----END PGP SIGNATURE-----
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Jerry James 10-06-2012 03:27 PM

Anyone have any idea why apps are starting to search /proc/sys/vm?
 
On Sat, Oct 6, 2012 at 5:44 AM, Daniel J Walsh <dwalsh@redhat.com> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> https://bugzilla.redhat.com/show_bug.cgi?id=863258
> https://bugzilla.redhat.com/show_bug.cgi?id=863257
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.12 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://www.enigmail.net/
>
> iEYEARECAAYFAlBwGYAACgkQrlYvE4MpobNXbgCeIK9DN+1wU3 bO6cRneC4O7U9q
> rIYAoOX+qkNDvkaZD2xPFBgVyBeCfXeD
> =CRP0
> -----END PGP SIGNATURE-----

Perhaps this glibc code (in sysdeps/unix/sysv/linux/malloc-sysdep.h)?

static inline bool
check_may_shrink_heap (void)
{
static int may_shrink_heap = -1;

if (__builtin_expect (may_shrink_heap >= 0, 1))
return may_shrink_heap;

may_shrink_heap = __libc_enable_secure;

if (__builtin_expect (may_shrink_heap == 0, 1))
{
int fd = open_not_cancel_2 ("/proc/sys/vm/overcommit_memory",
O_RDONLY | O_CLOEXEC);
if (fd >= 0)
{
char val;
ssize_t n = read_not_cancel (fd, &val, 1);
may_shrink_heap = n > 0 && val == '2';
close_not_cancel_no_status (fd);
}
}

return may_shrink_heap;
}

--
Jerry James
http://www.jamezone.org/
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

10-07-2012 06:18 PM

Anyone have any idea why apps are starting to search /proc/sys/vm?
 
dwalsh writes:

> [only the $subject]

# stap -e 'probe syscall.open {
if(substr(filename,0,5) == "/proc") {
println(pid(), " ", execname(), " ", filename)
print_ubacktrace()
} }' -d /usr/lib*/libc-*.so

(Repeat with more -d /usr/bin/foo as stap advises.)

- FChE
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel


All times are GMT. The time now is 04:41 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.