This paper treats two-threshold policies for an M/G/1 queue with two types of generally distributed random vacations: type 1 (long) and type 2 (short) vacations. Upon returning from a vacation, the server observes the queue length. If this is less than the lower threshold, the server takes a type 1 vacation; if it is between the two thresholds, the server takes a type 2 vacation; and if it is at or above the upper threshold, the server resumes serving the queue exhaustively. There is a shutdown cost for starting a series of vacations, a linear customer waiting cost, and type-dependent vacation reward rates. Renewal theory or the PASTA property is used to develop expressions for the average queue length and the average system cost for generally distributed vacations. A search procedure, which is provably finite for exponentially distributed vacations, is developed for determining the optimal threshold values.