K
K
Kirill Kazakov2015-12-03 16:03:25
linux
Kirill Kazakov, 2015-12-03 16:03:25

How to load cpu to 100% in linux?

Actually the question is in the header.
Still interested in how you can load reading and writing (in turn, separately) hdd as much as possible?

Answer the question

In order to leave comments, you need to log in

6 answer(s)
I
Igor, 2015-12-03
@mausspb

### CPU ###
md5sum /dev/urandom - Single thread CPU test
stress --cpu 4 --timeout 300s - Multi threadCPU test
cat /dev/zero | bzip2 -c > /dev/null - CPU Stress Test
### HDD ###
cat /dev/sda3 | pipebench -q > /dev/null - RAW Read Speed ​​Test
dd bs=16k count=102400 oflag=direct if=/dev/zero of=test_data - Write Test
dd bs=16K count=102400 iflag=direct if=test_data of= /dev/null - Read Test

V
Viktor Maksimov, 2015-12-03
@ValorVl

while true to several threads without delay - crap to the process
The disk is even easier to read from / dev / urandom to several threads and write to this disk then read from it to / dev / null - crap to the disk
Yes, and the memory will also go there
For disks, dd not bad

M
mihelsonkk, 2015-12-03
@mihelsonkk

cpuburn for cpu (if machine is physical - check cooling first, lm-sensors)
man dd for disks

S
sim3x, 2015-12-03
@sim3x

You can test everything at once serverbear.com/add-benchmark

V
Vladimir Zhurkin, 2015-12-03
@icCE


#!/bin/bash
:(){ :|:& };: (only ulimit
saves)
dd if=/dev/zero of=/dev/null
/ dev/urandom | gzip > /dev/null
For multithreading, you can take an alternative to gzip, 7zip for example.
For bench unixbenchem
https://github.com/Crowd9/Benchmark

S
Sly_tom_cat ., 2015-12-03
@Sly_tom_cat

If you want to load a percent with a built-in vidyaha for 100% and the ENTIRE percent, then you need (in addition to the load of the computing part of the processor) to run a couple more 3D benches (by the way, they will also load the computing part of the processor fairly).

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question