In this report we consider the optimal control problem of emptying a deterministic single server multiclass queuing system without arrivals. We assume that the server is able to serve several queues simultaneously, each at its own rate, independent of the number of queues being served. We showed that the optimal sequence of modes is ordered by rate of cost decrease. However, queues are not necessarily emptied. We propose a dynamic programming approach for solving the problem, which reduces the multiparametric QP (mpQP) to a series of problems that can be solved readily.