This paper considers an unrelated parallel machine scheduling problem with variable maintenance based on machine reliability to minimize the maximum completion time. To obtain the optimal solution of small-scale problems, we firstly establish a mixed integer programming model. To solve the medium and large-scale problems efficiently and effectively, we develop a hybrid discrete spider monkey optimization algorithm (HDSMO), which combines discrete spider monkey optimization (DSMO) with genetic algorithm (GA). A few additional features are embedded in the HDSMO: a three-phase constructive heuristic is proposed to generate better initial solution, and an individual updating method considering the inertia weight is used to balance the exploration and exploitation capabilities. Moreover, a problem-oriented neighborhood search method is designed to improve the search efficiency. Experiments are conducted on a set of randomly generated instances. The performance of the proposed HDSMO algorithm is investigated and compared with that of other existing algorithms. The detailed results show that the proposed HDSMO algorithm can obtain significantly better solutions than the DSMO and GA algorithms.