- 博客(9)
- 资源 (7)
- 收藏
- 关注
原创 在ubuntu上用kvmtool起虚拟机
kvmtool是一款精简的虚拟化工具,堪称精简版的qemu只不过只能起跟host架构一致的虚拟机,本文介绍怎么从用kvmtool起虚拟机。1首先从github上下载kvmtool的源码,git clone https://github.com/kvmtool/kvmtool.gitcd kvmtool && make 这样就会得到lkvm这个kvmtool的用户态工具。2用lkvm...
2018-04-27 17:26:27 1652
原创 leetcode gas station 问题
leetcode 问题:There are N gas stations along a circular route, where the amount of gas at station i isgas[i].You have a car with an unlimited gas tank and it costscost[i]of gas to travel from station i ...
2018-04-19 22:36:49 117
原创 c程序的执行顺序
在c语言的课堂里老师都告诉我们程序的执行入口函数是main函数,但是实际上程序在运行之初最先开始执行的却不是main,至少还有一些程序员可控的函数可以在main函数之前执行,也可以有一些函数在main结束之后执行。__attribute__((constructor)) 标记的函数实在main执行之前执行的,可以做一些初始化的工作。__attribute__((destructor)) 标记的函数...
2018-04-18 17:35:06 9555
转载 single number 问题
问题描述:Given an array of integers, every element appears three times except for one. Find that single one.给定一个整数数组,只有一个元素没有出现三次,找出这个元素。链接:https://www.nowcoder.com/questionTerminal/1097ca585245418ea2efd...
2018-04-17 21:21:22 115
原创 用diod安装9p文件系统
diod是谷歌开发的9p文件系统工具。安装diod直接apt安装,$:apt install diod启动9pserver$: diod -f -d 1 -n -e /tmp/9mount 9p client$: mouny -t diod -n localhost:/tmp/9 /mnt进入/mnt 新建文件就可以在/tmp/9中看到刚才所建的文件。在/mnt还可以利用dd测试9p文件系统的读写...
2018-04-13 18:38:05 887
转载 文件系统及其性能
Filesystems & Their Performance1 Introduction to File Systems1.1 IntroductionFor most users, the file system is the most visible aspect of an operating system, apart from the user interface. Fil...
2018-04-13 15:34:16 694
原创 在Linux中进行io和文件系统性能测试
io性能的测试最简单的方法是用dd命令,dd if=/dev/zero of=./zero.img bs=10M count=100 oflag=dsync上面的命令是从0设备读入数据并写入zero.img 文件,最后一个参数是为了排除cache的问题。测试文件系统性能最全面的工具是iozone,可以从http://www.iozone.org/src/current/iozone3_471.ta...
2018-04-11 18:08:01 1281
原创 Ubuntu上用qemu起虚拟机
在x86上用qemu起虚拟机是比较容易的。qemu是一款可以从ISA(instructure system arch)开始模拟硬件架构的工具。比如在x86上可以模拟arm架构的机器,它可以不断将guest虚拟机需要的机器指令转换成host指令来模拟不同架构。因此它的性能相当差。因此一般通过联合kvm这种半虚拟化工具达到提高性能的目的,一般有kvm加持的虚拟机速度堪比host。1 安装qemu kv...
2018-04-09 18:25:18 4861
转载 linux file system info
本文转载自http://blog.chinaunix.net/uid-11320152-id-2883103.html有哪些文件系统,至少通过本文您能了解得到;++++++++++++++++++++++++++++++++++++++++++++++++++++++++正文++++++++++++++++++++++++++++++++++++++++++++++++++++++++操作系统基于...
2018-04-02 14:59:27 278
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人