def METHOD_NAME(benchmark_spec: bm_spec.BenchmarkSpec) -> None:
  """Prepare both benchmarks on the target vm.
  Args:
    benchmark_spec: The benchmark specification.
  """
  min_test_length = min(
      FLAGS.netperf_test_length * len(FLAGS.netperf_num_streams),
      FLAGS.fio_runtime * len(FLAGS.fio_generate_scenarios),
  )
  max_test_length = max(
      FLAGS.netperf_test_length * len(FLAGS.netperf_num_streams),
      FLAGS.fio_runtime * len(FLAGS.fio_generate_scenarios),
  )
  if min_test_length < MIN_RUN_STAGE_DURATION:
    raise errors.Setup.InvalidFlagConfigurationError(
        'Combo benchmark run stages must run for at least'
        f' {MIN_RUN_STAGE_DURATION} seconds.'
    )
  elif float(max_test_length) / min_test_length - 1 > RUN_STAGE_DELAY_THRESHOLD:
    raise errors.Setup.InvalidFlagConfigurationError(
        'Combo benchmark run stages must have similar runtimes.'
    )
  vms = benchmark_spec.vms[:2]
  # Prepare Netperf benchmark
  client_vm, server_vm = vms
  background_tasks.RunThreaded(
      netperf_benchmark.PrepareNetperf, [client_vm, server_vm]
  )
  background_tasks.RunParallelThreads(
      [
          (netperf_benchmark.PrepareClientVM, [client_vm], {}),
          (
              netperf_benchmark.PrepareServerVM,
              [server_vm, client_vm.internal_ip, client_vm.ip_address],
              {},
          ),
      ],
      2,
  )
  # Prepare FIO benchmark
  exec_path = fio.GetFioExec()
  background_tasks.RunThreaded(
      lambda vm: fio_benchmark.PrepareWithExec(vm, exec_path), vms
  )