# HG changeset patch # User taiki # Date 1420427769 -32400 # Node ID 2916d99777c0f30764f0a4476164229ed914e3cf # Parent 1e188fa30a5a230bfd61b8b9554ec42987ca4596 add benchmark file for filebench. diff -r 1e188fa30a5a -r 2916d99777c0 fileserver.f --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/fileserver.f Mon Jan 05 12:16:09 2015 +0900 @@ -0,0 +1,66 @@ +# +# CDDL HEADER START +# +# The contents of this file are subject to the terms of the +# Common Development and Distribution License (the "License"). +# You may not use this file except in compliance with the License. +# +# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE +# or http://www.opensolaris.org/os/licensing. +# See the License for the specific language governing permissions +# and limitations under the License. +# +# When distributing Covered Code, include this CDDL HEADER in each +# file and include the License file at usr/src/OPENSOLARIS.LICENSE. +# If applicable, add the following below this CDDL HEADER, with the +# fields enclosed by brackets "[]" replaced with your own identifying +# information: Portions Copyright [yyyy] [name of copyright owner] +# +# CDDL HEADER END +# +# +# Copyright 2008 Sun Microsystems, Inc. All rights reserved. +# Use is subject to license terms. +# + +set $dir=/tmp +set $nfiles=10000 +set $meandirwidth=20 +set $meanfilesize=128k +set $nthreads=50 +set $iosize=1m +set $meanappendsize=16k + +define fileset name=bigfileset,path=$dir,size=$meanfilesize,entries=$nfiles,dirwidth=$meandirwidth,prealloc=80 + +run 60 + +define process name=filereader,instances=1 +{ + thread name=filereaderthread,memsize=10m,instances=$nthreads + { + flowop createfile name=createfile1,filesetname=bigfileset,fd=1 + flowop writewholefile name=wrtfile1,srcfd=1,fd=1,iosize=$iosize + flowop closefile name=closefile1,fd=1 + flowop openfile name=openfile1,filesetname=bigfileset,fd=1 + flowop appendfilerand name=appendfilerand1,iosize=$meanappendsize,fd=1 + flowop closefile name=closefile2,fd=1 + flowop openfile name=openfile2,filesetname=bigfileset,fd=1 + flowop readwholefile name=readfile1,fd=1,iosize=$iosize + flowop closefile name=closefile3,fd=1 + flowop deletefile name=deletefile1,filesetname=bigfileset + flowop statfile name=statfile1,filesetname=bigfileset + } +} + +echo "File-server Version 3.0 personality successfully loaded" +usage "Usage: set \$dir=" +usage " set \$meanfilesize= defaults to $meanfilesize" +usage " set \$nfiles= defaults to $nfiles" +usage " set \$nthreads= defaults to $nthreads" +usage " set \$meanappendsize= defaults to $meanappendsize" +usage " set \$iosize= defaults to $iosize" +usage " set \$meandirwidth= defaults to $meandirwidth" +usage " run runtime (e.g. run 60)" + +