信息安全研究 ›› 2025, Vol. 11 ›› Issue (12): 1156-.

• 技术应用 • 上一篇    

一种检测Docker容器异常的DiForest算法

异常检测;孤立森林算法;Docker容器;特征加权选择;日志异常检测
  

  1. 1(西安外事学院工学院西安710077)
    2(曲阜师范大学网络空间安全学院山东曲阜273165)
  • 出版日期:2025-12-12 发布日期:2025-12-04
  • 通讯作者: 孔德泓 硕士.主要研究方向为云计算、大数据. 1989779440@qq.com
  • 作者简介:谢兆贤 博士,教授.主要研究方向为云计算、软件工程、智能制造. george_hsieh@qq.com 孔德泓 硕士.主要研究方向为云计算、大数据. 1989779440@qq.com 徐凤雅 硕士.主要研究方向为计算机视觉、大数据. 822215180@qq.com 杨晴晴 硕士.主要研究方向为云计算、大数据. 2849228136@qq.com
  • 基金资助:
    西安外事学院高层次人才启动基金项目(XAIU202411);2024年度国际商务交流与外语研究课题资助项目(CUC2024LXYK0025)

A DiForest Algorithm for Detecting Abnormal Docker Container

anomaly detection; isolation forest algorithm; Docker container; featureweighted selection; log anomaly detection
  

  1. 1(College of Engineering, Xi’an International University, Xi’an 710077)
    2(School of Cyber Science and Engineering, Qufu Normal University, Qufu, Shandong 273165)
  • Online:2025-12-12 Published:2025-12-04

摘要: 针对孤立森林(isolation forest, iForest)算法存在异常检测的准确性差、资源消耗量大、时间和空间复杂度高等问题,在既有的基础上采用特征加权选择,通过建立孤立树路径长度标准差的方式,提出一种新型的孤立森林(deviationenhanced isolation forest, DiForest)算法,应用于Docker容器异常检测.实验通过模拟CPU、内存、磁盘IO和URL访问超限4类异常情况,对iForest和DiForest这2个异常检测算法进行比较和分析.实验结果表明,DiForest算法在进行异常检测时,容器内部的平均运行内存为30.6MB,小于iForest算法检测指标值的6.67%.网络吞吐量为110Mbps,大于iForest算法异常检测指标值的13.3%.与此同时,日志异常检测实验模拟URL访问超限的结果显示,DiForest算法访问请求的成功率为82.9%,比iForest算法访问请求的成功率高31.8%.因此DiForest算法不仅能够减少容器异常时的资源消耗,还能够提高异常日志检测的准确性.

关键词: 异常检测, 孤立森林算法, Docker容器, 特征加权选择, 日志异常检测

Abstract: With the problems of anomaly detection for poor accuracy, high resource consumption, and high time complexity of the isolation forest (iForest) algorithm, this paper proposed a novel DiForest algorithm which applies the featureweighted selection and the standard deviation of the isolation tree path lengths for anomaly detection of Docker container. The experiment simulates four types, CPU, memory, disk IO, and URL access overruns. The experimental results show that DiForest algorithm performs anomaly detection. The average running memory in the container is 30.6 MB, which is about 6.67% smaller than the average running memory of iForest algorithm for anomaly detection. The network throughput for DiForest algorithm is 110Mbps, which is about 13.3% higher than the network throughput for iForest algorithm. Meanwhile, the log anomaly detection experiments for URL access overruns show that the DiForest algorithm accesses requests with a success rate of 82.9%. It is 31.8% higher than the success rate of the iForest algorithm in the state of handling URL access overruns. Therefore, DiForest algorithm not only reduces the resource consumption when the container is abnormal, but also improves the accuracy of abnormality log detection.

Key words: anomaly detection, isolation forest algorithm, Docker container, featureweighted selection, log anomaly detection

中图分类号: