I want to launch a tool but bind it to half the number of vCPUs only.
So I'll need a Shell script to
a) check how many vCPUs a VM has (we can have 1 to 16)
b) if it's one vCPU, then run the command in nice mode ie nice /path/scriptname
c) if more than one, then pbind to half the number of processors/vCPU &
run the command (ie the command will take up at most 50% of total CPU
I can't recall in Solaris 10 x86, it's cpu0, cpu1 or processor1, processor2 or ...
in a virtual environment