您的位置:首页 > 其它

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

2012-11-12 13:10 1011 查看
转载自: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.
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: