Oracle Solaris 11 System Administrator — Question 11
A non-global zone named testzone is currently running.
Which option would you choose to dynamically set the CPU shares for the zone to two shares?
Answer options
- A. While logged in to the global zone, enter: prctl -n zone.cpu-shares -v 2 -r -i zone testzone
- B. While logged in to the global zone, enter: zonecfg -z testzone add rctl set name=zone.cpu-shares set value=(priv=privileged,limit=2,action=none)
- C. While logged in to the global zone, enter: prctl -n 2 zone.cpu-shares -i zone testzone
- D. While logged in to the global zone, enter: zonecfg -z testzone add rctl set name=zone.cpu-shares set value=2
- E. While logged in to testzone, enter: prctl -n zone.cpu-shares -v 2 -r -i zone testzone
Correct answer: D
Explanation
The correct answer is D, as it properly uses the zonecfg command to set the CPU shares for testzone to 2. Option A is incorrect because it does not specify the correct syntax for the prctl command. Option B is also incorrect due to the syntax and context of the rctl setting. Option C has an incorrect order of parameters, and option E attempts to change the settings from within the non-global zone, which is not valid.