nDrain: A Robust Log Template Mining Algorithm
Jinhui Yuan, Hongwei Zhou, Chao Wang, Bin Guan · 2024
Log template mining is an important step in analyzing logs. Drain is an important log template mining algorithm that performs well in handling various types of logs. However, Drain assumes that the first word of log entries belonging to the same log template is the same. However, not all logs meet this condition. Therefore, this paper proposes a robust log template mining algorithm based on the Drain algorithm, which we call nDrain. nDrain uses TFIDF to collect keywords from log templates and classifies log messages based on these keywords. We completed experimental verification using the public logs provided by Loghub. The experiment shows that compared to Drain, the accuracy of nDrain is improved on 5 types of logs.