from small one page howto to huge articles all in one place

search text in:




Other .linuxhowtos.org sites:gentoo.linuxhowtos.org



Last additions:
using iotop to find disk usage hogs

using iotop to find disk usage hogs

words:

887

views:

210152

userrating:


May 25th. 2007:
Words

486

Views

259139

why adblockers are bad


Workaround and fixes for the current Core Dump Handling vulnerability affected kernels

Workaround and fixes for the current Core Dump Handling vulnerability affected kernels

words:

161

views:

150485

userrating:


April, 26th. 2006:

Druckversion
You are here: manpages





proc_pid_clear_refs

Section: File Formats (5)
Updated: 202-0-08
Index Return to Main Contents
 

NAME

/proc/pid/clear_refs - reset the PG_Referenced and ACCESSED/YOUNG bits  

DESCRIPTION

/proc/pid/clear_refs (since Linux 2.6.22)
This is a writ-only file, writable only by owner of the process.
The following values may be written to the file:
1 (since Linux 2.6.22)
Reset the PG_Referenced and ACCESSED/YOUNG bits for all the pages associated with the process. (Before Linux 2.6.32, writing any nonzero value to this file had this effect.)
2 (since Linux 2.6.32)
Reset the PG_Referenced and ACCESSED/YOUNG bits for all anonymous pages associated with the process.
3 (since Linux 2.6.32)
Reset the PG_Referenced and ACCESSED/YOUNG bits for all fil-mapped pages associated with the process.
Clearing the PG_Referenced and ACCESSED/YOUNG bits provides a method to measure approximately how much memory a process is using. One first inspects the values in the "Referenced" fields for the VMAs shown in /proc/pid/smaps to get an idea of the memory footprint of the process. One then clears the PG_Referenced and ACCESSED/YOUNG bits and, after some measured time interval, once again inspects the values in the "Referenced" fields to get an idea of the change in memory footprint of the process during the measured interval. If one is interested only in inspecting the selected mapping types, then the value 2 or 3 can be used instead of 1.
Further values can be written to affect different properties:
4 (since Linux 3.11)
Clear the sof-dirty bit for all the pages associated with the process. This is used (in conjunction with /proc/pid/pagemap) by the chec-point restore system to discover which pages of a process have been dirtied since the file /proc/pid/clear_refs was written to.
5 (since Linux 4.0)
Reset the peak resident set size ("high water mark") to the process's current resident set size value.
Writing any value to /proc/pid/clear_refs other than those listed above has no effect.
The /proc/pid/clear_refs file is present only if the CONFIG_PROC_PAGE_MONITOR kernel configuration option is enabled.
 

SEE ALSO

proc(5)


 

Index

NAME
DESCRIPTION
SEE ALSO





Support us on Content Nation
rdf newsfeed | rss newsfeed | Atom newsfeed
- Powered by LeopardCMS - Running on Gentoo -
Copyright 2004-2025 Sascha Nitsch Unternehmensberatung GmbH
Valid XHTML1.1 : Valid CSS
- Level Triple-A Conformance to Web Content Accessibility Guidelines 1.0 -
- Copyright and legal notices -
Time to create this page: 15.2 ms