As modern server systems increase in volume and density, more and more hardware failures are generated, resulting in system breakdown. The conventional mechanisms for monitoring and checking the behavior of hardware parts, such as the hard disk drive (HDD), the RAM and the CPU, are not considered a dynamic approach for hardware failure prediction. On the other hand, machine learning (ML) and deep learning (DL) methods can assist to effectively predict hardware errors at a sufficient amount of time before they actually occur. In this work, a survey is presented on hardware failure prediction techniques for servers using ML and DL methods, with a focus on HDD, RAM and CPU issues. These techniques are categorized based on the ML or DL algorithm they use for the prediction process. The basic features of each work (used dataset, system type, HDD/RAM/CPU focus, error types etc.) are demonstrated. Additionally, certain statistic results from the various prediction methods are displayed, concluding in some crucial discussion on the existing literature.