Skip to content

benchmark on docker on mac: could not find integer "NUMA node(s)" #3386

Open

Description

@pdeyhim

I'm trying to run a benchmark and use docker on Mac as the target VM. This is my static VM config:

static_vms:
  - &vm1 
    ip_address: sshserver ## docker on mac
    user_name: root
    ssh_private_key: /tmp/key

some_benchmark:
  vm_groups:
    default:
     static_vms:
     - *vm1

After executing the benchmark, i get the following error (omitted earlier logs). The benchmark progress until the point where lscpu command is trying to parse out "numa nodes(s)". Im no an expert in this area but I do not think Numa applies to Mac which I think is the reason why the numa nodes output is missing from lscpu on docker. Any potential workarounds? And why is numa_node_count is collected in linux_virtual_machine? The reason I ask is that the only benchmarks taking advantage of it are linux_benchmarks/hpcc_benchmark.py and redit_enterprise I believe? Any reason to collect this for all linux benchmarks?

2022-02-01 20:57:34,500 f2de76f0 MainThread fast(1/1) ERROR    Exception running benchmark
Traceback (most recent call last):
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/pkb.py", line 1250, in RunBenchmarkTask
    RunBenchmark(spec_for_run, collector)
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/pkb.py", line 1036, in RunBenchmark
    DoProvisionPhase(spec, detailed_timer)
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/pkb.py", line 751, in DoProvisionPhase
    spec.Provision()
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/benchmark_spec.py", line 715, in Provision
    vm_util.RunThreaded(self.PrepareVmAfterBoot, self.vms)
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/background_tasks.py", line 647, in RunThreaded
    return RunParallelThreads(target_arg_tuples,
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/background_tasks.py", line 582, in RunParallelThreads
    return _RunParallelTasks(
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/background_tasks.py", line 556, in _RunParallelTasks
    raise parallel_exception_class(
perfkitbenchmarker.errors.VmUtil.ThreadException: The following exceptions occurred during parallel execution:
Exception occurred while calling PrepareVmAfterBoot(sshserver):
Traceback (most recent call last):
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/background_tasks.py", line 252, in Run
    self.return_value = self.target(*self.args, **self.kwargs)
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/benchmark_spec.py", line 972, in PrepareVmAfterBoot
    vm.PrepareVMEnvironment()
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/linux_virtual_machine.py", line 471, in PrepareVMEnvironment
    self.RecordAdditionalMetadata()
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/linux_virtual_machine.py", line 778, in RecordAdditionalMetadata
    lscpu_results = self.CheckLsCpu()
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/linux_virtual_machine.py", line 697, in CheckLsCpu
    self._lscpu_cache = LsCpuResults(lscpu)
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/linux_virtual_machine.py", line 2316, in __init__
    self.numa_node_count = GetInt('NUMA node(s)')
  File "/home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/linux_virtual_machine.py", line 2313, in GetInt
    raise ValueError('Could not find integer "{}" in {}'.format(
ValueError: Could not find integer "NUMA node(s)" in ['Architecture', 'BogoMIPS', 'Byte Order', 'CPU MHz', 'CPU family', 'CPU op-mode(s)', 'CPU(s)', 'Core(s) per socket', 'Flags', 'L1d cache', 'L1i cache', 'L2 cache', 'L3 cache', 'Model', 'Model name', 'On-line CPU(s) list', 'Socket(s)', 'Stepping', 'Thread(s) per core', 'Vendor ID']

my lscpu output:

Architecture:        x86_64
CPU op-mode(s):      32-bit, 64-bit
Byte Order:          Little Endian
CPU(s):              4
On-line CPU(s) list: 0-3
Thread(s) per core:  1
Core(s) per socket:  1
Socket(s):           4
Vendor ID:           GenuineIntel
CPU family:          6
Model:               142
Model name:          Intel(R) Core(TM) i7-8569U CPU @ 2.80GHz
Stepping:            10
CPU MHz:             2800.000
BogoMIPS:            5616.00
L1d cache:           32K
L1i cache:           32K
L2 cache:            256K
L3 cache:            8192K
Flags:               fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss ht pbe syscall nx pdpe1gb lm constant_tsc rep_good nopl xtopology nonstop_tsc cpuid tsc_known_freq pni pclmulqdq dtes64 ds_cpl ssse3 sdbg fma cx16 xtpr pcid sse4_1 sse4_2 movbe popcnt aes xsave avx f16c rdrand hypervisor lahf_lm abm 3dnowprefetch pti fsgsbase bmi1 avx2 bmi2 erms xsaveopt arat

Activity

  1. yuyantingzero commented on Feb 2, 2022

    @yuyantingzero
    Contributor

    As far as I know, most benchmarks are not tested on containers at the moment, not too surprised if you run into issues like this.
    In terms of workaround, you can patch the line 2316 in /home/perfkit/PerfKitBenchmarker/perfkitbenchmarker/linux_virtual_machine.py with something like self.numa_node_count = 1

    Added Patrick, who is expert on containers, may provide a better alternative.

  2. pdeyhim commented on Feb 2, 2022

    @pdeyhim
    Author

    understood. Yes I was expecting some challenges with running on docker. I'll play around with your suggestion and see how it goes. Patrick, would love to hear your thoughts on this as well. thank you both!

  3. pmkc commented on Feb 4, 2022

    @pmkc
    Collaborator

    We probably should fail gracefully if we miss some data from lspcu

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions