#define VERR_INVALID_CPU_ID (-1018)
This means that invalid CPU ID is specified. On IBM kernels, CPU ID's are calculated as local APIC ID's. Unfortunately, this method
is unreliable, because sometimes CPU core's LAPIC ID's are not from 0..NCpuIDs interval. I think, this is your case. In my case,
my CPU has contiguous interval of LAPIC ID's, so you're unlucky. I'd suspect that you're using IBM's kernel? Unfortunately, IBM
kernels lack a reliable method of getting current CPU ID. OS/4 kernels have a specific KEE API for that. Also, OS/4 kernels have
API for CPU rendez-vous. This is required for enabling hardware virtualization (VT-x/AMD-V). IBM kernels also have no such
feature. So, in your case I'd suggest using OS/4 kernel.
PS: your error occurs when VBox switches to a CPU with a spectfic LAPIC ID. VBox assumes that CPU ID's are consecutive,
but in your case it's not (most probably).
PPS: You also can try pinning VBox executable to a 0 CPU, so it will not hit a hole in CPU ID's range.