This paper considers a discrete-time GI$^X$/Geo/1/N-G queue with randomized working vacations, where upon arrival, a negative customer removes one positive (ordinary) customer in service if any is present and disappears immediately; otherwise, it has no effect on the system if the system is empty. As soon as the system becomes empty, the server immediately takes a working vacation. If there are no customers in the system at the end of the working vacation, the server takes another working vacation with probability $p$ or remains dormant in the system with probability $1-p$. Otherwise, the server starts to serve the customers with the normal service rate immediately if there are some customers at the end of a working vacation. This pattern does not terminate until the server has taken $J$ successive working vacations. Steady-state system length distributions at various epochs such as, pre-arrival, arbitrary and outside observer's observation epochs have been obtained. Based on the various system length distributions, we also give some important performance measures including blocking probabilities, mean queue length, probability mass function of waiting time and other performance measures along with some numerical examples. Then, we use the parabolic method to search the optimum value of the normal service rate under a established cost function.