Skip to content

Instantly share code, notes, and snippets.

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@MrHamel
MrHamel / health.py
Last active March 6, 2023 11:17
Server Monitor
import requests, json
import os, psutil, re, time
def parse_syslog():
syslog = "/var/log/messages"
if os.path.isfile("/var/log/syslog"):
syslog = "/var/log/syslog"
f = open(syslog, 'r')