A multiadaptive sampling technique for cost-effective network measurements