This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

Check SD card errors
#1
Here you have script for checking SD card current errors:

Code:
function checkSDCardErrors()
    f = assert (io.popen('dmesg | grep mmcblk'))
    errorsCounter = 0
    for line in f:lines() do
     isThereSDError = line:match("mmcblk*..*: (.*error*..*)")
   if isThereSDError then errorsCounter = errorsCounter + 1 end
    end
    f:close()
 return errorsCounter
end

log(checkSDCardErrors())

It can be helpful in monitoring SD card and knowing about start of problems and that it must replacedWink
Reply


Messages In This Thread
Check SD card errors - by buuuudzik - 23.02.2018, 21:21
RE: Check SD card errors - by baggins - 21.09.2018, 21:30
RE: Check SD card errors - by buuuudzik - 21.09.2018, 21:51
RE: Check SD card errors - by Daniel - 24.09.2018, 07:34
RE: Check SD card errors - by baggins - 24.09.2018, 11:28
RE: Check SD card errors - by buuuudzik - 24.09.2018, 07:50
RE: Check SD card errors - by Daniel - 24.09.2018, 08:15
RE: Check SD card errors - by buuuudzik - 24.09.2018, 08:29
RE: Check SD card errors - by Daniel - 24.09.2018, 08:32
RE: Check SD card errors - by buuuudzik - 24.09.2018, 11:49
RE: Check SD card errors - by FatMax - 28.10.2018, 15:07
RE: Check SD card errors - by buuuudzik - 28.10.2018, 15:22
RE: Check SD card errors - by FatMax - 28.10.2018, 15:24
RE: Check SD card errors - by admin - 29.10.2018, 07:01
RE: Check SD card errors - by buuuudzik - 29.10.2018, 07:14

Forum Jump: