This paper presents a log analysis methodology based on a three-tier architecture to ensure system stability and reliability for DevOps teams. The first tier, Log Investigation, performs automatic log labeling and anomaly classification. It proposes a method for labeling log data and a classification system that categorizes anomalies into three categories, enabling supervised learning without manual intervention. The second tier, Anomaly Detection, detects abnormal behavior and proposes a flexible anomaly detection method applicable to supervised, semi-supervised, and unsupervised learning. Evaluation results on public and industrial datasets demonstrate high accuracy, with an F1-score of 0.98 to 1.0. The third tier, Root Cause Analysis, identifies the minimal set of logs that explain system failures, the cause of the failure, and the sequence of events. By balancing the training data and identifying key services, the method consistently detects 90-98% of root cause log lines within the top 10 candidates, providing actionable insights for problem resolution. By integrating these three layers, DevOps teams have a powerful way to improve the reliability of their IT systems.