遍历目录下所有文件的最后一行进行判断若错误及时邮件报警-案例: #-*- encoding: utf-8 -*- __author__ = 'liudong' import linecache,sys,time,datetime,os import urllib,sys,urllib,json,smtplib from email.mime.text import MIMEText mailto_list=['liudong@philisense.com'] mail_host="smtp.ph…