lkml.org 
[lkml]   [2000]   [Dec]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Purging the Page Table (was: Purging the Buffer Cache)
Al Peat wrote:
> > > Is there any way to completely purge the buffer
> > > cache -- not just the write requests (ala 'sync'
> > or
> > > 'update'), but the whole thing? Can I just call
> > > invalidate_buffers() or destroy_buffers()?

Try this script:

case "`id -u`" in
0) ;;
*) echo Only root can run this script. 1>&2; exit 1 ;;
esac

mount | sort -k3 -r | \
while read dev ON dir TYPE type etc; do
echo mount $dir -o remount
mount $dir -o remount
done

mount | sort -k1 | \
while read dev ON dir TYPE type etc; do
case "$dev" in
/dev/*) echo hdparm -f $dev
hdparm -f $dev >/dev/null ;;
esac
done

-- Jamie
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:52    [W:0.035 / U:1.140 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site