Skip to content
This repository has been archived by the owner on Oct 25, 2024. It is now read-only.

arcalot/arcaflow-plugin-smallfile

Repository files navigation

smallfile workload plugin for Arcaflow

arca-smallfile is a workload plugin of the smallfile benchmark tool using the Arcaflow python SDK.

Supported smallfile parameters are defined in the SmallfileParams schema of the smallfile_schema.py file. You define your test parameters in a YAML file to be passed to the plugin command as shown in smallfile-example.yaml.

Image Building

You can change this plugin's image version tag in .github/workflows/carpenter.yaml by editing the IMAGE_TAG variable, and pushing that change to the branch designated in that workflow.

To run directly without the Arcaflow engine:

In order to run the arca-smallfile plugin follow these steps:

Containerized

  1. Clone this repository
  2. Create the container with docker build -t arca-smallfile <clone_directory>
  3. Run cat smallfile-example.yaml | docker run -i arca-smallfile -f -

Native

Prerequisite: smallfile should already be installed on your system.

  1. Clone this repository
  2. Create a venv in the current directory with python3 -m venv ./venv
  3. Activate the venv by running source ./venv/bin/activate
  4. Run pip install -r requirements.txt
  5. Edit smallfile_plugin.py to set smallfile_dir=<path_to_smallfile_dir>
  6. Run ./smallfile_plugin.py -f smallfile-example.yaml

smallfile workload (workload)

Run the smallfile workload with the given parameters

Input

Type:scope
Root object:WorkloadParams
Properties
cleanup (bool)
Name:Cleanup files
Description:Whether to cleanup files and directories after a run
Required:No
Default (JSON encoded):
true
Type:bool
smallfile_params (reference[SmallfileParams])
Required:Yes
Type:reference[SmallfileParams]
Referenced object:SmallfileParams
Objects
SmallfileParams (object)
Type:object
Properties
auto-pause (enum[string])
Name:Auto pause
Description:Auto-adjust the pause time between files
Required:No
Type:enum[string]
Values
  • N: NO
  • Y: YES
cleanup-delay-usec-per-file (int)
Name:Cleanup delay (usec)
Description:Delay in usec after cleanup operation
Required:No
Type:int
dirs-per-dir (int)
Name:Directories per directory
Description:Maximum number of subdirectories per directory
Required:No
Type:int
file-size (int)
Name:File size (B)
Description:Size in bytes of files
Required:No
Type:int
files (int)
Name:File count
Description:Number of files per thread
Required:No
Type:int
files-per-dir (int)
Name:Files per directory
Description:Maximum number of files per directory
Required:No
Type:int
finish (enum[string])
Name:Finish operations
Description:Complete all file operations even if measurement has finished
Required:No
Type:enum[string]
Values
  • N: NO
  • Y: YES
fsync (enum[string])
Name:fsync
Description:Insert fsync() call before closing a file
Required:No
Type:enum[string]
Values
  • N: NO
  • Y: YES
hash-into-dirs (enum[string])
Name:Hash into directories
Description:Assign next file to a directory using a hash function
Required:No
Type:enum[string]
Values
  • N: NO
  • Y: YES
incompressible (enum[string])
Name:Incompressible files
Description:Generate pure-random files that are not compressible
Required:No
Type:enum[string]
Values
  • N: NO
  • Y: YES
operation (enum[string])
Name:Operation
Description:Type of smallfile operation
Required:Yes
Type:enum[string]
Values
  • append: APPEND
  • chmod: CHMOD
  • cleanup: CLEANUP
  • create: CREATE
  • delete: DELETE
  • delete_renamed: DELETE_RENAMED
  • getxattr: GETXATTR
  • ls-l: LS_L
  • mkdir: MKDIR
  • overwrite: OVERWRITE
  • read: READ
  • readdir: READDIR
  • rename: RENAME
  • rmdir: RMDIR
  • setxattr: SETXATTR
  • stat: STAT
  • swift-get: SWIFT_GET
  • swift-put: SWIFT_PUT
  • symlink: SYMLINK
  • truncate-overwrite: TRUNCATE_OVERWRITE
prefix (string)
Name:File prefix
Description:Filename prefix
Required:No
Type:string
record-size (int)
Name:Record size (KB)
Description:Size in KB of data transferred in a single system call
Required:No
Type:int
same-dir (enum[string])
Name:Same directory
Description:Threads share a single directory
Required:No
Type:enum[string]
Values
  • N: NO
  • Y: YES
stonewall (enum[string])
Name:Stonewall
Description:Measure thread throughput when another thread has finished
Required:No
Type:enum[string]
Values
  • N: NO
  • Y: YES
suffix (string)
Name:File suffix
Description:Filename suffix
Required:No
Type:string
threads (int)
Name:Threads
Description:Number of workload threads
Required:No
Type:int
top (string)
Name:Top directory
Description:Directory where file operations are performed
Required:Yes
Type:string
verify-read (enum[string])
Name:Verify read
Description:Verify read data is correct
Required:No
Type:enum[string]
Values
  • N: NO
  • Y: YES
xattr-count (int)
Name:xattr count
Description:Number of extended attributes per file
Required:No
Type:int
xattr-size (int)
Name:xattr size (B)
Description:Size in bytes of extended attribute value in bytes
Required:No
Type:int
WorkloadParams (object)
Type:object
Properties
cleanup (bool)
Name:Cleanup files
Description:Whether to cleanup files and directories after a run
Required:No
Default (JSON encoded):
true
Type:bool
smallfile_params (reference[SmallfileParams])
Required:Yes
Type:reference[SmallfileParams]
Referenced object:SmallfileParams

Outputs

error

Type:scope
Root object:WorkloadError
Properties
error (string)
Required:Yes
Type:string
Objects
WorkloadError (object)
Type:object
Properties
error (string)
Required:Yes
Type:string

success

Type:scope
Root object:WorkloadResults
Properties
sf_params (reference[SmallfileOutputParams])
Required:Yes
Type:reference[SmallfileOutputParams]
Referenced object:SmallfileOutputParams
sf_results (reference[SmallfileOutputResults])
Required:Yes
Type:reference[SmallfileOutputResults]
Referenced object:SmallfileOutputResults
sf_rsptimes (list[reference[SmallfileOutputRsptimes]])
Required:Yes
Type:list[reference[SmallfileOutputRsptimes]]
List items
Type:reference[SmallfileOutputRsptimes]
Referenced object:SmallfileOutputRsptimes
Objects
SmallfileOutputParams (object)
Type:object
Properties
auto_pause (bool)
Name:Auto pause
Description:Auto-adjust the pause time between files
Required:Yes
Type:bool
cleanup_delay_usec_per_file (int)
Name:Cleanup delay (usec)
Description:Delay in usec after cleanup operation
Required:Yes
Type:int
file_size (int)
Name:File size (B)
Description:Size in bytes of files
Required:Yes
Type:int
file_size_distr (int)
Name:File size distribution
Description:Always '-1' as unsupported feature
Required:Yes
Type:int
files_per_dir (int)
Name:Files per directory
Description:Maximum number of files per directory
Required:Yes
Type:int
files_per_thread (int)
Name:File count
Description:Number of files per thread
Required:Yes
Type:int
finish_all_requests (enum[string])
Name:Finish operations
Description:Complete all file operations even if measurement has finished
Required:Yes
Type:enum[string]
Values
  • N: NO
  • Y: YES
fname_prefix (string)
Name:File prefix
Description:Filename prefix
Required:No
Type:string
fname_suffix (string)
Name:File suffix
Description:Filename suffix
Required:No
Type:string
fsync_after_modify (enum[string])
Name:fsync
Description:Insert fsync() call before closing a file
Required:Yes
Type:enum[string]
Values
  • N: NO
  • Y: YES
hash_to_dir (enum[string])
Name:Hash into directories
Description:Assign next file to a directory using a hash function
Required:Yes
Type:enum[string]
Values
  • N: NO
  • Y: YES
host_set (string)
Name:Host set
Description:Always 'localhost' because we don't use smallfile's multi-host features
Required:Yes
Type:string
host_timeout (int)
Name:Host timeout
Description:Always '3' as unsupported feature
Required:Yes
Type:int
launch_by_daemon (bool)
Name:Launch by daemon
Description:Always 'false' because we don't use smallfile's daemon feature
Required:Yes
Type:bool
min_directories_per_sec (int)
Name:Minimum directories per second
Description:Always '50' as unsupported feature
Required:Yes
Type:int
network_sync_dir (string)
Name:Network sync directory
Description:Subdirectory of top for network sync
Required:Yes
Type:string
operation (enum[string])
Name:Operation
Description:Type of smallfile operation
Required:Yes
Type:enum[string]
Values
  • append: APPEND
  • chmod: CHMOD
  • cleanup: CLEANUP
  • create: CREATE
  • delete: DELETE
  • delete_renamed: DELETE_RENAMED
  • getxattr: GETXATTR
  • ls-l: LS_L
  • mkdir: MKDIR
  • overwrite: OVERWRITE
  • read: READ
  • readdir: READDIR
  • rename: RENAME
  • rmdir: RMDIR
  • setxattr: SETXATTR
  • stat: STAT
  • swift-get: SWIFT_GET
  • swift-put: SWIFT_PUT
  • symlink: SYMLINK
  • truncate-overwrite: TRUNCATE_OVERWRITE
pause_between_files (float)
Name:Pause between files
Description:Always '0.0' as unsupported feature
Required:Yes
Type:float
permute_host_dirs (enum[string])
Name:Permute host directories
Description:Always 'N' as unsupported feature
Required:Yes
Type:enum[string]
Values
  • N: NO
  • Y: YES
share_dir (enum[string])
Name:Same directory
Description:Threads share a single directory
Required:Yes
Type:enum[string]
Values
  • N: NO
  • Y: YES
startup_timeout (int)
Name:Startup timeout
Description:Always '3' as unsupported feature
Required:Yes
Type:int
stonewall (enum[string])
Name:Stonewall
Description:Measure thread throughput when another thread has finished
Required:Yes
Type:enum[string]
Values
  • N: NO
  • Y: YES
threads (int)
Name:Threads
Description:Number of workload threads
Required:Yes
Type:int
top (string)
Name:Top directory
Description:Directory where file operations are performed
Required:Yes
Type:string
total_hosts (int)
Name:Total hosts
Description:Total number of hosts in the test
Required:Yes
Type:int
verify_read (enum[string])
Name:Verify read
Description:Verify read data is correct
Required:Yes
Type:enum[string]
Values
  • N: NO
  • Y: YES
version (string)
Name:Version
Description:Smallfile version
Required:Yes
Type:string
xattr_count (int)
Name:xattr count
Description:Number of extended attributes per file
Required:Yes
Type:int
xattr_size (int)
Name:xattr size (B)
Description:Size in bytes of extended attribute value in bytes
Required:Yes
Type:int
SmallfileOutputResults (object)
Type:object
Properties
IOPS (float)
Name:Total IOPS
Description:IOPS rate for the job
Required:Yes
Type:float
MiBps (float)
Name:Total MiBps
Description:MiBps rate for the job
Required:Yes
Type:float
date (string)
Name:Date
Description:Test run date
Required:Yes
Type:string
elapsed (float)
Name:Elapsed time
Description:Elapsed time of the job
Required:Yes
Type:float
files (int)
Name:Total files
Description:Total files for the job
Required:Yes
Type:int
filesPerSec (float)
Name:Total files per second
Description:Files per second rate for the job
Required:Yes
Type:float
pctFilesDone (float)
Name:Percent files done
Description:Total percent of file transactions completed
Required:Yes
Type:float
records (int)
Name:Total records
Description:Total records for the job
Required:Yes
Type:int
startTime (float)
Name:Start time
Description:Test start time
Required:Yes
Type:float
status (string)
Name:Status
Description:Test run status
Required:Yes
Type:string
thread (map[int,reference[SmallfileOutputThread]])
Required:Yes
Type:map[int,reference[SmallfileOutputThread]]
Key type
Type:int
Value type
Type:reference[SmallfileOutputThread]
Referenced object:SmallfileOutputThread
totalDataGB (float)
Name:Total Data (GB)
Description:Total data in GB
Required:Yes
Type:float
totalhreads (int)
Name:Total threads
Description:Total number of threads
Required:Yes
Type:int
SmallfileOutputRsptimes (object)
Type:object
Properties
host_thread (string)
Name:Host thread
Description:Job ID and thread identifier
Required:Yes
Type:string
max (float)
Name:Maximum
Description:Maximum response time
Required:Yes
Type:float
mean (float)
Name:Mean
Description:Mean response time
Required:Yes
Type:float
min (float)
Name:Minimum
Description:Minimum response time
Required:Yes
Type:float
pctdev (float)
Name:Percent deviation
Description:Standard deviation as a percent of mean
Required:Yes
Type:float
pctile50 (float)
Name:50th percentile
Description:50th percentile response time
Required:Yes
Type:float
pctile90 (float)
Name:90th percentile
Description:90th percentile response time
Required:Yes
Type:float
pctile95 (float)
Name:95th percentile
Description:95th percentile response time
Required:Yes
Type:float
pctile99 (float)
Name:99th percentile
Description:99th percentile response time
Required:Yes
Type:float
samples (int)
Name:Samples
Description:Number of file samples
Required:Yes
Type:int
SmallfileOutputThread (object)
Type:object
Properties
IOPS (float)
Name:Thread IOPS
Description:IOPS rate for the thread
Required:Yes
Type:float
MiBps (float)
Name:Thread MiBps
Description:MiBps rate for the thread
Required:Yes
Type:float
elapsed (float)
Name:Thread elapsed time
Description:Elapsed time of the thread
Required:Yes
Type:float
files (int)
Name:Thread files
Description:Total files for the thread
Required:Yes
Type:int
filesPerSec (float)
Name:Thread files per second
Description:Files per second rate for the thread
Required:Yes
Type:float
records (int)
Name:Thread records
Description:Total records for the thread
Required:Yes
Type:int
WorkloadResults (object)
Type:object
Properties
sf_params (reference[SmallfileOutputParams])
Required:Yes
Type:reference[SmallfileOutputParams]
Referenced object:SmallfileOutputParams
sf_results (reference[SmallfileOutputResults])
Required:Yes
Type:reference[SmallfileOutputResults]
Referenced object:SmallfileOutputResults
sf_rsptimes (list[reference[SmallfileOutputRsptimes]])
Required:Yes
Type:list[reference[SmallfileOutputRsptimes]]
List items
Type:reference[SmallfileOutputRsptimes]
Referenced object:SmallfileOutputRsptimes