From: Nuno S. <nun...@se...> - 2002-11-24 08:44:07
|
Hello list! I was doing some benchmarks, in skas3 mode, and I have one question, if you don't mind :) When, inside UML, I do a "seq 1 1000000 > /dev/null" the system (as opposed to user or total) load in the host goes up 1 or 2%, but when I do a "ping -c 10000 -f 127.0.0.1" the system load, on the host, goes up 40-50%. Also, ping is very slow in the UML compared to the host: puma:~# time ping -f -c 10000 127.0.0.1 > /dev/null real 0m1.383s user 0m0.060s sys 0m0.910s usermode:~# time ping -f -c 10000 127.0.0.1 > /dev/null real 0m7.478s user 0m0.135s sys 0m3.865s (puma is usermodes' host) With seq the diference is tiny: puma:~# time seq 1 1000000 > /dev/null real 0m6.575s user 0m6.200s sys 0m0.030s usermode:~# time seq 1 1000000 > /dev/null real 0m7.624s user 0m6.731s sys 0m0.077s ----------------------------------------------- UML is in user-land, and pinging the loopback shouldn't need to do anything in the host. Please correct me if I'm wrong :) Of course, ubd (uml's host disk access) needs to mess with host's files, but that is another subject. (finally) My question is: Is this the way it must be or it's just something that isn't optimized yet? My config: Host: P3@500MHz 2.4.19 with skas3 UML: 2.4.19-31um running in skas mode. Thanks in advance, Nuno Silva |
From: Cameron K. <cam...@pa...> - 2002-11-24 09:35:02
|
On Sun, Nov 24, 2002 at 08:42:55AM +0000, Nuno Silva wrote: > When, inside UML, I do a "seq 1 1000000 > /dev/null" the system (as > opposed to user or total) load in the host goes up 1 or 2%, but when I > do a "ping -c 10000 -f 127.0.0.1" the system load, on the host, goes up > 40-50%. Firstly, the seq command output above is going straight to the bit bucket, while your ping is creating IO that is actually going places. It should be deal easy to tell which ought to have more work involved. Basically, you're comparing apples and oranges. Hint: What has fewer system calls, your seq command, or your ping command? > UML is in user-land, and pinging the loopback shouldn't need to do > anything in the host. Please correct me if I'm wrong :) There's still the virtual host's kernel work work through. That's still a system call. Whether of not that system goes through the host is another matter. -- Cameron Kerr Email: cam...@pa... Website: http://homepages.paradise.net.nz/~cameronk/ |
From: Adam H. <ad...@la...> - 2002-11-24 09:46:09
|
On Sun, 24 Nov 2002, Nuno Silva wrote: > When, inside UML, I do a "seq 1 1000000 > /dev/null" the system (as > opposed to user or total) load in the host goes up 1 or 2%, but when I > do a "ping -c 10000 -f 127.0.0.1" the system load, on the host, goes up > 40-50%. seq doesn't do much in kernel space. just the occasional output on stdout, after being fed thru a buffer. ping does a lot of network calls. This requires more round trips into the host, and therefor increase it much more. Any app that does heavy network i/o will suffer under uml, as they have high overhead. |