Optimal Capacity Allocation for executing Map Reduce Jobs in Cloud Systems