Perl脚本解析日志文件

时间:2015-07-22 07:16:37

标签: linux perl

我想解析我的flexlm license.log文件并将以下信息存档到另一个.csv文件中:

  1. 日期
  2. 时间戳
  3. 许可证签出/签入
  4. 功能名称
  5. 用户名
  6. 日志文件格式如下:

    11:30:32 (cdslmd) OUT: "Virtuoso_Multi_mode_Simulation" user1@server1.xyz.local  [APS Base] (2 licenses) 
    11:30:36 (cdslmd) IN: "111" user4@server2.xyz.local  
    11:30:37 (cdslmd) IN: "Virtuoso_Multi_mode_Simulation" user3@server1.xyz.local  [APS Base] (2 licenses) 
    11:30:40 (cdslmd) UNSUPPORTED: "Virtuoso_Acceler_Parallel_sc" (PORT_AT_HOST_PLUS   ) user5@server4.xyz.local  (License server system does not support this feature. (-18,327:104 "Connection reset by peer"))
    11:30:45 (cdslmd) IN: "111" user9@server6.xyz.local  
    11:30:45 (cdslmd) REMOVING user10@server1.xyz.local from Virtuoso_Schematic_Editor_L
    

    如何使用perl脚本执行此操作?

0 个答案:

没有答案