新的 kqemu 1.3 比 VMware 快

作者正文
huangjiahua
1楼





年龄: 22
加入时间: 2005/03/30
文章: 197

专家分:4725

文章时间: 2006-4-15 周六, 下午8:23 标题: 新的 kqemu 1.3 比 VMware 快 引用回复

http://fabrice.bellard.free.fr/qemu/
新的 kqemu 1.3 支持 full virtualization , 几乎是 100% 的速度

在 Win200,WinXP , Linux 上可以用

本文是 Ubuntu 上安装的笔记

0.
安装 qemu 编译环境
代码:
sudo apt-get build-dep qemu



1.
安装 CVS 的 qemu

这个 kqemu 加速模块要求 CVS 的 qemu

如果嫌 CVS 慢,也可以从 http://qemu.dad-answers.com/download/qemu/ 这儿下载 qemu-snapshot
解压,编译安装

我用的编译参数是
代码:
./configure --target-list=i386-user,i386-softmmu --enable-alsa --cc=gcc-3.4 --host-cc=gcc-3.4


( qemu 在 gcc-4 下可能有问题,所以让她用 gcc-3.4 了 )

2.
安装 kqemu-1.3
可以到 http://fabrice.bellard.free.fr/qemu/download.html 下载 kqemu-1.3 的 .tar.gz
解压
代码:
./configure ; make ; sudo make install


3.
写一个 kqemu 加载工具 ~/bin/dokqemu.sh
代码:
#!/bin/sh -v

mknod /dev/kqemu c 250 0
chmod 666 /dev/kqemu

/sbin/modprobe kqemu

lsmod | grep qemu

使用 qemu 前执行下
代码:
sudo dokqemu.sh


4.
qemu 加参数 -kernel-kqemu

比如我用的启动 Win2000 的命令是
代码:
time nice -n 10 qemu -localtime -hda 2k.img -boot c -m 64 -smb /data/date/VMshare/ -kernel-kqemu



http://free.oszoo.org/download.html 有一些 qemu 的图形外壳的链接

_________________
Hiweed-Debian http://linux.hiweed.com/

点燃一支蜡烛,而不是诅咒黑暗


上一次由huangjiahua于2006-4-15 周六, 下午11:03修改,总共修改了1次
返回顶端
阅读会员资料 huangjiahua离线发送站内短信 浏览发表者的主页 MSN <!-- if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 ) document.write(' '); else document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute"></div><div style="position:absolute;left:3px;top:-1px"></div></div>'); //-->
<noscript></noscript>
huangjiahua
2楼





年龄: 22
加入时间: 2005/03/30
文章: 197

专家分:4725

文章时间: 2006-4-15 周六, 下午10:39 标题: Windows 下使用 qemu 引用回复

Win200、XP 下也可以用 kqemu

1.
安装 qemu
可以到这儿下载 安装包
http://free.oszoo.org/ftp/qemu/win32/daily/

点击安装啦


2.
安装 kqemu
可以到 http://fabrice.bellard.free.fr/qemu/download.html 下载 kqemu-1.3 的 .tar.gz
解压, 点击里面的 kqemu.inf , 选 安装

每次使用 qmeu 前用命令
代码:
net start kqemu

来起用 kqemu

3.
使用 qemu 一样加参
代码:
数 -kernel-kqemu


4.
windows 下也有一些 qemu 的外壳可以用, 比如 Qemu Manager

这个 QGui 也不错
http://perso.wanadoo.es/comike/
<!-- <img οnlοad="setImageDimensions(this)" οnmοuseοver="changeImageDimensions(this, 'over')" οnmοuseοut="changeImageDimensions(this, 'out')" src="http://perso.wanadoo.es/comike/images/qgui01.png" border="0" /> -->

<!-- <img οnlοad="setImageDimensions(this)" οnmοuseοver="changeImageDimensions(this, 'over')" οnmοuseοut="changeImageDimensions(this, 'out')" src="http://perso.wanadoo.es/comike/images/qgui02.png" border="0" /> -->

_________________
Hiweed-Debian http://linux.hiweed.com/

点燃一支蜡烛,而不是诅咒黑暗


上一次由huangjiahua于2006-4-15 周六, 下午11:17修改,总共修改了1次
返回顶端
阅读会员资料 huangjiahua离线发送站内短信 浏览发表者的主页 MSN <!-- if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 ) document.write(' '); else document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute"></div><div style="position:absolute;left:3px;top:-1px"></div></div>'); //-->
<noscript></noscript>
yang119345
3楼




性别: 性别:男

加入时间: 2005/06/19
文章: 542
来自: 上海
专家分:14240

文章时间: 2006-4-15 周六, 下午10:50 标题: 引用回复

WINDOWS下qemu速度不敢恭维啊。不知道这个如何?
_________________
| blog | 豆瓣 | 南方linux联盟论坛 |
返回顶端
阅读会员资料 yang119345离线发送站内短信 Blog 浏览发表者的主页 QQ号码150272988 MSN <!-- if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 ) document.write(' '); else document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute"></div><div style="position:absolute;left:3px;top:-1px"></div></div>'); //-->
<noscript></noscript>
huangjiahua
4楼





年龄: 22
加入时间: 2005/03/30
文章: 197

专家分:4725

文章时间: 2006-4-15 周六, 下午11:18 标题: 引用回复

没加 kqemu 的当然慢

去试试这个新的 kqemu 1.3 加速模块吧

_________________
Hiweed-Debian http://linux.hiweed.com/

点燃一支蜡烛,而不是诅咒黑暗
返回顶端
阅读会员资料 huangjiahua离线发送站内短信 浏览发表者的主页 MSN <!-- if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 ) document.write(' '); else document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute"></div><div style="position:absolute;left:3px;top:-1px"></div></div>'); //-->
<noscript></noscript>
eexpress
5楼




性别: 性别:男
年龄: 35
加入时间: 2005/08/14
文章: 8321
来自: 长沙
专家分:174445

文章时间: 2006-4-15 周六, 下午11:24 标题: 引用回复

模拟器的,似乎没用。反正涉及到硬件的操作,不兼容就都出来了。本质上还慢。
_________________
<!-- <img οnlοad="setImageDimensions(this)" οnmοuseοver="changeImageDimensions(this, 'over')" οnmοuseοut="changeImageDimensions(this, 'out')" src="http://forum.ubuntu.org.cn/weblogs/upload/6/1406416178443e46fd608de.png" border="0" /> -->
返回顶端
阅读会员资料 eexpress离线发送站内短信 发送电子邮件 Blog MSN Google Talk Skype帐号 <!-- if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 ) document.write(' '); else document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute"></div><div style="position:absolute;left:3px;top:-1px"></div></div>'); //-->
<noscript></noscript>
huangjiahua
6楼





年龄: 22
加入时间: 2005/03/30
文章: 197

专家分:4725

文章时间: 2006-4-16 周日, 下午3:06 标题: 引用回复

不要想当然哦
_________________
Hiweed-Debian http://linux.hiweed.com/

点燃一支蜡烛,而不是诅咒黑暗
返回顶端
阅读会员资料 huangjiahua离线发送站内短信 浏览发表者的主页 MSN <!-- if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 ) document.write(' '); else document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute"></div><div style="position:absolute;left:3px;top:-1px"></div></div>'); //-->
<noscript></noscript>
eexpress
7楼




性别: 性别:男
年龄: 35
加入时间: 2005/08/14
文章: 8321
来自: 长沙
专家分:174445

文章时间: 2006-4-16 周日, 下午3:47 标题: 引用回复

倒是听说intel mac运行了xp sp2,Hua试试。
_________________
<!-- <img οnlοad="setImageDimensions(this)" οnmοuseοver="changeImageDimensions(this, 'over')" οnmοuseοut="changeImageDimensions(this, 'out')" src="http://forum.ubuntu.org.cn/weblogs/upload/6/1406416178443e46fd608de.png" border="0" /> -->
返回顶端
阅读会员资料 eexpress离线发送站内短信 发送电子邮件 Blog MSN Google Talk Skype帐号 <!-- if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 ) document.write(' '); else document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute"></div><div style="position:absolute;left:3px;top:-1px"></div></div>'); //-->
<noscript></noscript>
baidongyi
8楼






加入时间: 2005/07/12
文章: 57

专家分:1562

文章时间: 2006-4-16 周日, 下午6:21 标题: 引用回复

1 感谢 huahua
2 请问除了感觉快之外,有没有什么数值来说明问题?
返回顶端
阅读会员资料 baidongyi离线发送站内短信 <!-- if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 ) document.write(' '); else document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute"></div><div style="position:absolute;left:3px;top:-1px"></div></div>'); //-->
<noscript></noscript>
Mephisto
9楼






加入时间: 2005/12/13
文章: 15

专家分:427

文章时间: 2006-4-16 周日, 下午6:50 标题: 引用回复

新的 kqemu 1.3 支持 full virtualization , 几乎是 100% 的速度
不知道100%速度指的是什么,但是如果说是在相同机器上的100%的速度,我相信是不可能的。
返回顶端
阅读会员资料 Mephisto离线发送站内短信 <!-- if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 ) document.write(' '); else document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute"></div><div style="position:absolute;left:3px;top:-1px"></div></div>'); //-->
<noscript></noscript>
huangjiahua
10楼





年龄: 22
加入时间: 2005/03/30
文章: 197

专家分:4725

文章时间: 2006-4-18 周二, 上午2:57 标题: 引用回复

测试用的程序
代码:

hua@vgh:c$ cat count.c
#include <stdio.h>
int main(void)
{
double counter;
double result;
double temp;
for (counter = 0; counter < 4000.0 * 4000.0 * 4000.0 / 20.0 + 2030;
counter += (5 -3 + 2 +1 ) / 4)
{
temp = counter / 1239;
result = counter;
}
printf("Result is %lf\n", result);
return 0;
}


在真实机器上的情况:
代码:

hua@vgh:c$ time ./count-o2
Result is 3200002029.000000

real 0m37.181s
user 0m35.254s
sys 0m0.028s
hua@vgh:c$




在 qemu 的 Debian Sid 里的情况:
代码:

hiweed@Hiweedlinux:~/tmp/c$ time ./count-o2
Result is 3200002029.000000

real 0m39.358s
user 0m35.340s
sys 0m0.095s
hua@vgh:c$




基本没有什么 CPU 性能损失嘛

_________________
Hiweed-Debian http://linux.hiweed.com/

点燃一支蜡烛,而不是诅咒黑暗
返回顶端
阅读会员资料 huangjiahua离线发送站内短信 浏览发表者的主页 MSN <!-- if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 ) document.write(' '); else document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute"></div><div style="position:absolute;left:3px;top:-1px"></div></div>'); //-->
<noscript></noscript>
pointer
11楼




性别: 性别:男

加入时间: 2006/04/17
文章: 5

专家分:135

文章时间: 2006-4-19 周三, 下午5:01 标题:
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值