I want to load up a linux server so swap space gets used. Is there any tool that I can run on the server so swap starts getting used ? Also, is there a script or tool that I can run that will increase the kernel memory usage. I am doing some profiling on my linux server (centOS) so need to artifically load the system.
Share
python -c 'a = range(some_huge_number); raw_input()'can chew up lots of memory, and will hold it until you press Enter. Start with smallish numbers (say 1000000 or so) and ramp up, watching memory carefully to make sure you don’t crush your system too badly.