CrushMFT Documentation

This page in: Docker

How it works#

What CrushTest does from the moment you click Start until the results are on screen, and how it measures, so you know what its numbers mean and how far to trust them.

A run in progress

The parts#

Part Where it runs What it does
Controller the machine you open CrushTest on the UI, your servers and profiles, the runs and their results. It plans each run, tells the load machines what to do, collects what they measure, samples the servers, and writes the results. It needs the license.
This machine inside the controller a load machine built in: by default every run also makes load from the controller's machine (Use this machine as a load agent on the Run page)
Load agent other machines, crushtest agent makes load when the controller says so, measures it, and sends its numbers every interval. It listens on port 47920; the controller connects to it.
Monitor the server's own machine, crushtest monitor samples the CrushFTP process (CPU time, memory) and the free space of the server's data disk. It listens on port 47921.

The controller and an agent talk over a link encrypted with a key made from the agent's pairing code. An agent accepts a controller only if it shows the code, and only if the controller's license checks out. When the controller goes quiet, the agent stops its load by itself.

A run, step by step#

  1. Waiting. With Not before, the run waits for that time.
  2. Preflight and preparation, for each server of the run (one, or two for a comparison):
    • the preflight checks the addresses, the users, the server's limits, the caps and the load machines, and changes nothing;
    • with test users CrushTest makes (CrushMFT 27), it checks that none of their names exists, writes each one to the ledger and then makes it, and records the SFTP host key;
    • a listing test's folder of N files is made.
  3. Rounds. A comparison alternates the two servers: A B, then B A, then A B again, and so on (the second server of a round starts 5 seconds after the first finished), so that time of day and warm caches fall on both sides equally. One server runs its rounds one after another.
  4. Each run:
    • The profile's sessions and rate are split over the load machines (20 sessions on two machines: 10 each).
    • Ramp-up: the sessions start spread over this time.
    • Warm-up: the load runs, and is not counted.
    • Measured: the window every result comes from.
    • Every interval (10 seconds) each load machine sends its measurements and its own health; the controller merges them, samples each server once through its admin API, writes a line of every chart, and checks the guards.
    • At the end each load machine sweeps away anything of its own still on the server (every file and folder it makes starts with the run's prefix and its number), logging in as each user it used.
  5. The verdict. With two servers, CrushTest compares all the runs of A with all the runs of B (Compare) and lists the server settings that differ between them.
  6. Clean-up. The test users and the listing folder are removed, as the ledger says. Then the job is done (or failed, or aborted).

What it measures#

On the load machines#

  • Each operation is timed where it is made: a login, an upload, a download, a listing and so on, separately for each protocol.
  • Latency percentiles are exact across machines. Times go into a histogram with fixed buckets (32 per power of two, about 3% apart). Fixed buckets add up, so the controller adds the histograms of all load machines and reads p50, p90, p99 and p99.9 from the sum, as exactly as from one machine. Averages of percentiles are never used.
  • No coordinated omission. In the ops, arrivals and capacity models work falls due at the profile's rate whether or not the server keeps up. Each operation's time counts from when it was due, not from when a session got round to it, so a server that falls behind shows its queue in the latency instead of hiding it. How late work started is measured too.
  • Every byte is checked. The test data comes from memory: one random 4 MB block per run (the same on every load machine), read from a point that depends on the file's name. Files do not share blocks, so compression or deduplication on the server gains nothing, and each download is compared byte for byte with what was sent without storing anything. Test files are never staged on the load machine's disks.
  • Errors are sorted by kind (Troubleshooting): a login refused, a ban, a TLS or host key problem, a timeout, a reset, a byte that came back wrong, a load balancer that moved a session, and so on. The first error of each kind is kept with its message.

On the servers#

Through the server's admin API, once per interval:

  • CPU, memory, threads and sessions from the server's dashboard: CPU % of the server machine, heap, busy threads, sessions, open files;
  • what the server counted: logins, uploaded and downloaded files and bytes, so CrushTest's numbers can be held against the server's own;
  • CPU time per operation. CrushMFT 27 reports its own process CPU time and garbage collection time, so CrushTest divides the server's CPU time in the measured window by the operations: milliseconds of server CPU per upload, for example. For CrushFTP 11, a monitor on the server's machine gives the same exact number; without either, only the CPU % is shown.
  • Behind a load balancer, each back end the same way, and which of the run's users have sessions on which back end (Load balancers).

CrushTest counts its own admin calls and shows them with the results, so you can see what it added to the server's work (one call per server per interval).

On the load machines themselves: client-bound#

A load machine that is the limit makes the server look slower than it is. Every interval each load machine checks itself:

Sign Limit
its CPU above 75% of all its cores
work started late its p99 more than 50 ms or a tenth of the interval late, whichever is larger
garbage collection more than 5% of the time
TCP sockets more than 80% of the ephemeral port range in use
open files more than 80% of the limit
network link more than 80% of its speed

A load machine that was limited in at least a fifth of its measured intervals makes the run client-bound. Its results say so, with the reason, and Compare and Trend leave it out: its numbers are the load machines', not the server's. Add load machines (Load machines and monitors).

How runs are compared#

  • The same work. Every run keeps a fingerprint of the profile fields that shape the load: the protocols and weights, the model, sessions and rate, the three times, the steps or mix, the file sizes and their order, the pauses, the byte check, the listing fixture, the capacity search, the caps and the number of test users. The name, description, targets and guards are not in it. Compare warns when the two sides were not made with the same work, and Trend only puts runs of one fingerprint side by side.

  • The verdict compares the medians of the two sides with an exact Mann-Whitney test, and needs a change of at least 5%:

    Verdict When
    improvement, regression p ≤ 0.05 and a change of 5% or more
    likely improvement, likely regression every run of one side is beyond every run of the other, but there are too few runs for the test
    no change the medians are less than 5% apart
    inconclusive the runs overlap

    Two runs against two can never reach p ≤ 0.05, and three against three cannot either: four rounds (four runs a side) are the fewest that can give a plain improvement or regression.

  • The Trend holds each server build against the band of up to five builds before it: their median plus or minus three median absolute deviations, at least 5% of the median, once there are three runs before it. The first builds are the baseline. A build outside the band is watch; it becomes regression (or improvement) only when the build before it was outside too, so one noisy run raises no alarm.

What CrushTest changes on your server#

  • Files, in the test users' upload folder: what the steps upload, removed by the steps, at the end of the iteration, or by the sweep.
  • Test users (CrushMFT 27, only when you let CrushTest make them): the names are written to the ledger in CrushTest's folder before each change, and only ledger names that still carry CrushTest's marker are ever removed. Each test user expires a day after the run, even if nothing removes it.
  • Nothing else. The admin API is otherwise only read.

A ledger with anything still on the server blocks the next run against that server until it is cleaned up (Clean up what CrushTest made in the server's editor). See Safety on production.

Where things are kept#

Everything stays in CrushTest's folder on the controller (Files): each run's results, its measurements over time, the load machines' health, its errors and its preflight. Nothing about a test leaves the controller: the only call CrushTest makes elsewhere is the daily license check-in (Licensing).