Dynamic real-time systems such as embedded systems operate in environments in which several parameters vary at run time. These systems must satisfy several performance requirements. Resource allocation on these systems becomes challenging because variations of run-time parameters may cause violations of the performance requirements. Performance violations result in the need for dynamic re-allocation, which is a costly operation. A method for allocating resources such that the allocation can sustain the system in the light of a continuously changing environment is developed. We introduce a novel performance metric called MAIL (maximum allowable increase in load) to capture the effectiveness of a resource allocation. Given a resource allocation, MAIL quantifies the amount of additional load that can be sustained by the system without any performance violations. A mixed-integer-programming-based approach (MIP) is developed to determine a resource allocation that has the highest MAIL value. Using simulations, several sets of experiments are conducted to evaluate our heuristics in various scenarios of machine and task heterogeneities. The performance of MIP is compared with three other heuristics: integer-programming based, greedy, and classic min-min. Our results show that MIP performs significantly better when compared with the other heuristics.