I want to pre-load some Files / Programs into the memory, ram, cache to open / access them faster.
I already tried creating a tmpfs, ramfs System https://wiki.ubuntuusers.de/RAM-Disk_erstellen (Sorry its in German) by calling those commands for Example
sudo mount -t ramfs ramfs /media/ramdisk
sudo mount -t tmpfs -o size=20% none /media/ramdisk
and put some data (arround 1GiB) in it.
I also tried pre-loading the Files directly Mount /usr in RAM (loading from HDD when starting, and saving to when shutting down) (top answer)
cat /bin/* /lib/* /usr/bin/* /usr/lib/* >/dev/null
or
ionice -c 3 find /bin /usr/bin /usr/lib* -type f -exec ionice -c 3 cat '{}' ';' > /dev/null &
but regardless what I’m doing I see no Ram Change via System Monitor / htop
Its always around 1,7GiB / 3,8GiB I’m running Lubuntu 14.10
Do you know of any limitations for doing so running a Ubuntu System or is there something else to do to archive what I want or am I missing some other important Point?
free -h
for detailed data about RAM usage. Notice the "cached" collumn – leorize Jul 22 '15 at 10:17But why is "free" showing other values than htop?
– hypnomaki Jul 22 '15 at 10:51