How to install DiskSim 4.0 + SSDSim(MS) in Ubuntu

转载自:http://blog.sina.com.cn/s/blog_6464a7210100ghsy.html

DiskSim is alow-level storage simulation tool, which can generatetiming-accurate simulation result. It is developed by Greg Ganger.Current version is 4.0 and it is out in June2008.

SSDextension for DiskSim is an extensional module of DiskSim whichimplments SSD I/O Models. It is implemented by MicrosoftResearch.

Compiling DiskSim and SSD extension is very simple, but when Itried, there was some problem.
This article addresses those problems.
DiskSim does not compile in 64bit environment. Nevertry it. Even if you succeded compilation, it will not run -- justproduces segmentation fault.

DiskSim requires bison and flex, which are parser generators forparameter file parsing codes.

Step 0. Install bison and flex, if you have not installedalready.
$ sudo apt-get install bison flex

Step 1. Download and unzip.
Sources can be downloadedfrom the links above. I downloaded DiskSim 4.0 with dixtrac.
$ tar xfz disksim-4.0-with-dixtrac.tar.gz
$ cd disksim-4.0
$ unzip ../ssd-add-on.zip

Step 2. Apply SSD add on patch.
$ patch -p1 < ssdmodel/ssd-patch

Step 3. Append SSD model library path to dixtrac.
add these lines to dixtrac/.paths
# path tossdmodel
exportSSDMODEL_PREFIX=../ssdmodel
exportSSDMODEL_INCL=$(SSDMODEL_PREFIX)/include
exportSSDMODEL_CFLAGS=-I$(SSDMODEL_INCL)
exportSSDMODEL_LDPATH=$(SSDMODEL_PREFIX)/lib
exportSSDMODEL_LDFLAGS=-L$(SSDMODEL_LDPATH)-lssdmodel
modify dixtrac/Makefile like this :
$(LIBDISKSIM_LDFLAGS) \
$(MEMSMODEL_LDFLAGS) \
$(DISKMODEL_LDFLAGS) \
$(SSDMODEL_LDFLAGS) \
$(LIBPARAM_LDFLAGS) \
$(LIBDDBG_LDFLAGS) \
$(ST_LDFLAGS)

CFLAGS = -Wall -g -MD -I. $(DEFINES) -I$(STHREADS) $(DMINCLUDES)\
$(LIBDISKSIM_CFLAGS) \
$(DISKMODEL_CFLAGS) $(LIBPARAM_CFLAGS) $(LIBDDBG_CFLAGS) \
$(SSDMODEL_CFLAGS)

Step 4. Compile~~~!
$ make

Step 5. Check if it works well.
$ cd valid;./runvalid
$ chmod a+x ../ssdmodel/valid/runvalid
$ cd ../ssdmodel/valid; ./runvalid

Ok. It is all.
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值