I'm using AIX 6.1 and for testing.
I want to clear the file system cache.
Something similar a this on linux : echo 2 > /proc/sys/vm/drop_caches
Is this possible?
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It only takes a minute to sign up.
Sign up to join this communityFailing an actual method to flush the cache you might be able to get away with tuning some VMM parameters to effectively flush your cache.
vmo -L
Look at setting minperm%
and maxperm%
very low and strict_maxperm
to 1. I don't have an AIX box handy to test what values it will let you set but I'm assuming 0 would fail, maybe:
vmo -o minperm%=1 -o maxperm%=1 -o strict_maxperm=1 -o minclient%=1 -o maxclient%=1
Monitor with vmstat -v
to see when/if it applies. You might need to do something memory intensive to trigger the page replacement daemon into action and take care of that 1%.
cat "somefile_sized_1%_of_memory" > /dev/null
Then reset them back to your normal values.
maxclient%
to a value equal of minperm% and strict_maxclient=1
, in less of 2 minutes 16GB of memory was freed. Now I will back the original values. Thanks!
The only thing I could find was this command :
mount -o rbrw
Other option will be unmonting the file-system wich will dump the cache.