The manufacturing industry must reduce energy consumption during the machining process to comply with energy demand and usage restrictions. Previous research has employed various methods to take a optimization plan in machining process. However, these studies mostly rely on static machining conditions, without paying much attention for the condition variation, which may lead to a coarse energy efficiency optimization in machining process. Hence, this study introduces a real time condition based sustainable maintenance method for machining process. Firstly, a real-time data acquisition system is employed to collect and send data to the developed tool condition prediction model using deep learning. Then, the physical energy prediction model is employed to reflect the real time energy consumption behaviors based on the real time tool condition. Subsequently, a similarity analysis is employed to decide whether a new optimization is required. And, once it is required, an optimization using NSGA-II and TOPSIS is conducted. Experiments were conducted on a milling machine and compared with traditional methods, and verified using triple bottom line. Results indicated that the proposed method can reduce the energy consumption by 2.51% and 7.01%, and it can maintain a qualified product during the machining process.