This paper examines an M[x]/G/1 queueing system with a randomized vacation policy and at most J vacations. Whenever the system is empty, the server immediately takes a vacation. If there is at least one customer found waiting in the queue upon returning from a vacation, the server will be immediately activated for service. Otherwise, if no customers are waiting for service at the end of a vacation, the server either remains idle with probability p or leaves for another vacation with probability 1‐ p. This pattern continues until the number of vacations taken reaches J. If the system is empty by the end of the Jth vacation, the server becomes idle in the system. Whenever one or more customers arrive at server idle state, the server immediately starts providing service for the arrivals. Assume that the server may meet an unpredictable breakdown according to a Poisson process and the repair time has a general distribution. For such a system, we derive the distributions of important system characteristics, such as system size distribution at a random epoch and at a departure epoch, system size distribution at busy period initiation epoch, the distributions of idle period, busy period, etc. Finally, a cost model is developed to determine the joint suitable parameters (p
*, J
*) at a minimum cost, and some numerical examples are presented for illustrative purpose.