The equipment degradation and various maintenance decision processes with unreliable machines have been studied extensively. The traditional degradation modeling using Markov process only focuses on single machine system and ignores maintenance or repair duration. This paper is devoted to analytical and numerical study of production lines within the Markov process framework considering repair time and periodic inspection. Nonexponential holding time distributions in Markov chain are approximated by inserting multiple intermediate states based on a phase-type distribution. Overall system availability is calculated by recursively solving the balance equations of the Markov process. The results show that the optimal inspection intervals for two repairable-machine systems can be achieved by means of the proposed method. By having an adequate model representing both deterioration and maintenance processes, it is also possible to obtain different optimal maintenance policies to maximize the availability or productivity for different configurations of components.