On 05/05/2011 05:36 PM, manuel songokuh wrote:
>
> how i can clean memory cache?
leave it alone!
the linux kernel keeps stuff in cache just in case it needs it soon, and
it automatically dumps out the oldest held when something else needs
the memory space…
[unlike windows which always dumps it out, even if it then has to RELOAD
it again one second later—the linux way is MUCH better use of
memory–keep it full, or almost full as much as possible!!]
i did try on terminal:
tv:~> echo 3 > /proc/sys/vm/drop_caches
bash: /proc/sys/vm/drop_caches: Permission denied
tv:~> sudo echo 3 > /proc/sys/vm/drop_caches
bash: /proc/sys/vm/drop_caches: Permission denied
how i can clean cache memory?
[QUOTE=DenverD;2335445]On 05/05/2011 05:36 PM, manuel songokuh wrote:
>
> how i can clean memory cache?
leave it alone!
the linux kernel keeps stuff in cache just in case it needs it soon, and
it automatically dumps out the oldest held when something else needs
the memory space…
[unlike windows which always dumps it out, even if it then has to RELOAD
it again one second later—the linux way is MUCH better use of
memory–keep it full, or almost full as much as possible!!]
On 05/05/2011 11:36 AM, caf4926 wrote:
>
> manuel_songokuh;2335456 Wrote:
>> ah ok linux s best of windows? i’m wonderfull…but it will be problem
>> when cache is full and linux go will tilt or crash or stress?
> You have much to learn friend
It will not go tilt. You have to remember that the Windows philosophy is “memory
is not to be wasted”. Linux reworks that to “unused memory is a wasted
resource”. This also the reason is that Windows can happily run with defective
memory in the higher regions, but Linux will not.
If you want to see the benefits of cache, start in the base of some relatively
deep tree and run the command:
time grep -r XXXXXXXXX *
After this returns, immediately rerun the command. The difference in times are
the result of using the cache. As long as the total size of the files included
do not exceed the size of your cache, the reduction will be dramatic.
Searching the network drivers part of the Linux Source tree, my system gets the
following:
First Run Second
real 0m10.865s 0m0.707s
user 0m0.452s 0m0.172s
sys 0m4.032s 0m0.508s
ok
now i’m understand, i dont use that code on terminal for clean cache but now my opensuse is full cache when i turn on pc opensuse, booting, starting kde and arrive kde but cache is ready full???
see screenshot fresh start opensuse: http://dl.dropbox.com/u/5440392/forum/schermata3.png
Hahaha, I remember back in the early days of Linux, when it was at 1.x, he came around and gave a talk. At question time somebody asked him: Does it do XYZ properly? (I don’t remember what XYZ was, perhaps it was some problem with multitasking, remember this was days of W98.)
Linus Torvalds’s answer was: Yes, Linux is not Windows.
The audience cheered.
So, if your cache fills up and your computer goes tilt or crash or stress, please go to Linus and ask for your money back.
On 05/11/2011 09:36 AM, manuel songokuh wrote:
>
> ok
> now i’m understand, i dont use that code on terminal for clean cache
> but now my opensuse is full cache when i turn on pc opensuse, booting,
> starting kde and arrive kde but cache is ready full???
> see screenshot fresh start opensuse:
> [image: http://dl.dropbox.com/u/5440392/forum/schermata3.png]
Why do you think that a full cache is bad? The main usage of cache in Linux is
to save the contents of disk files and directories in fast memory so they can be
reused whenever necessary. Whenever you access a new file and cache is full, the
oldest cache contents are replaced. If a running program needs more memory,
again the oldest contents of the cache are dropped and that chunk of RAM is
given to the program.
The result is that your system is faster with a full cache than it would be with
an empty one.
ok but maybe it’s strange when start kde and opensuse but cache is ready to full for what?
see video clip i did record from phone for to show you to see it ok?
please to download link video and open with VLC: http://dl.dropbox.com/u/5440392/forum/forum-opensuse-cache.3GP
why cache goes grow up to full cache??
but before never same that cache-full ready when begin kde or opensuse…now it’s diverse… it’s strange???
On 05/11/2011 01:06 PM, caf4926 wrote:
>
> Run top in a terminal
> Show us what is running from there.
>
> Could you try uninstalling ‘preload’, see if that makes any difference
That probably won’t make any difference. By the time the system finishes
booting, many hundreds of MB have been read from the disk - all of which have
been cached. Cache should be nearly full by then.
I just wish that there was a way to turn off the disk cache so that the OP could
see how beneficial the Linux way is.
If you didn’t change the default colors, the green memory bar represent IO cache, i.e. disk cache. In my system right after boot there is very little IO cache, but it grows up as you have intensive or prolonged disk access - for example when using a torrent client or playing/streaming video or such. It is NOT normal - at least I’ve never seen - a system boot with all memory already taken for IO cache, unless you have very little memory - say, 512 MB or less - and a memory-hungry desktop - say, KDE 4.