As businesses operating in the production sector often need to deal with defective products and machine breakdowns, they may experience challenges in their production planning and control processes. This study addresses random machine breakdown to derive an optimal production time for defective products under an abort/resume inventory control policy. Machine time-to-breakdown involves two scenarios: namely, the occurrence of machine breakdown during production and its occurrence after production. Total expected cost functions are derived for each scenario. The average cost is then assessed in terms of expense over time. This study explores assumptions such as the performance of the inspection both during and after production, defective products being discarded, and others being sold at discount prices, and the time-to-breakdown being exponentially distributed. Numerical examples are given to explain the model which has been developed, and the convex formation of the expected function of total cost is illustrated in a graph. Optimal values are investigated for production time and total cost based on two different values of the number of machine breakdowns per unit time. Sensitivity analyses are used to show how a number of system parameters affect the optimal solution. These analyses demonstrate that the demand rate and the number of machine breakdowns have a significant effect on the optimal solutions.