When I do grep on a large local file, it took long time. But when I do it again, now it is much faster. Is this behaviour because of some type of internal cache maintained by Linux systems?
Yes. All free ram is be used to cache data read from your harddisk.
The virtual memory page cache will keep copies of pages from the disk in your RAM which means the access time is faster and the corresponding read/pread calls will be serviced from memory instead of having to go to disk.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With