#!/usr/bin/python
import os.path
import re
import json
def status():
i=0
try:
if os.path.exists('/sys/devices/system/edac/mc'):
data = os.popen('ls /sys/devices/system/edac/mc/mc*/*/*ce_count 2>/dev/null').read().strip().split('\n')
for slot in data:
if os.path.exists(slot):
file = open(slot, 'r').read().strip()
if file > '0':
i += 1
if i > 0:
return 1
except:
False