falsear_datos_de_la_memoria_ram_en_linux
Falsear datos sobre el uso de memoria RAM en GNU/Linux (free)
Uso real de la memoria RAM.
free -m total used free shared buffers cached Mem: 128 67 60 0 0 58 -/+ buffers/cache: 8 119 Swap: 128 0 128
cat /proc/meminfo MemTotal: 131072 kB MemFree: 44184 kB Cached: 77764 kB Buffers: 0 kB Active: 70960 kB Inactive: 7152 kB Active(anon): 34904 kB Inactive(anon): 4940 kB Active(file): 36056 kB Inactive(file): 2212 kB Unevictable: 1928 kB Mlocked: 1948 kB SwapTotal: 131072 kB SwapFree: 131072 kB Dirty: 176 kB Writeback: 0 kB AnonPages: 39844 kB Shmem: 39496 kB Slab: 6832 kB SReclaimable: 3816 kB SUnreclaim: 3016 kB
Falsear los datos de la memoria RAM
vim /etc/fake_meminfo MemTotal: 1310720 kB MemFree: 985964 kB Cached: 32892 kB Buffers: 0 kB Active: 35268 kB Inactive: 3348 kB Active(anon): 24612 kB Inactive(anon): 136 kB Active(file): 10656 kB Inactive(file): 3212 kB Unevictable: 1928 kB Mlocked: 1948 kB SwapTotal: 5131072 kB SwapFree: 4931072 kB Dirty: 496 kB Writeback: 0 kB AnonPages: 24748 kB Shmem: 19024 kB Slab: 4552 kB SReclaimable: 1760 kB SUnreclaim: 2792 kB
umount /proc/meminfo 2> /dev/null mount --bind /etc/fake_meminfo /proc/meminfo
Comprobación de los nuevos valores de uso de la memoria RAM.
free total used free shared buffers cached Mem: 1310720 324756 985964 0 0 32892 -/+ buffers/cache: 291864 1018856 Swap: 5131072 200000 4931072
falsear_datos_de_la_memoria_ram_en_linux.txt · Last modified: 2020/12/25 22:57 by 127.0.0.1