This paper studies a manufacturer with a system prone to failure. The manufacturer performs two types of maintenance activities: preventive maintenance (PM), performed periodically, resets the system, and Minimal Repair (MR), performed after breakdowns, restores the system to working condition. It is assumed that two different types of learning take place: (i) repetition learning: due to the repetitive nature of PM, the manufacturer gains experience and learns to perform the PM activities faster and at a lower cost and (ii) failure learning: each failure gives the manufacturer the opportunity to find the root causes, to learn from mistakes and to improve the system. This paper, the first one to quantify failure learning in maintenance literature, assumes that such learning can then be applied during the next PM activity, which brings down the failure rate for the next PM cycle. For the increasing failure rate case, repetition learning increases the PM frequency, whereas failure learning causes the manufacturer to reduce the optimal number of PM activities. However, for the constant failure rate, repetition learning has no effect on the PM frequency, whereas failure learning may actually increase it.