Sign in to follow this  
Followers 0
layer

Memory CheckUp

8 posts in this topic

#1 ·  Posted (edited)

just made a little memory logger to see how your memory is: unhealthy or healthy... it checks every 15 minutes... it is very simple script but who cares...

While 1
$getmem= MemGetStats ()
Sleep (60*15*1000)
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "Date= " & @MON & "/" & @MDAY & "/" & @YEAR & " -- " & "Time= " & @Hour & ":" & @Min & ":" & @Sec & ": " & "Memory percentage being used: " & $getmem[0] & "%")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "Date= " & @MON & "/" & @MDAY & "/" & @YEAR & " -- " & "Time= " & @Hour & ":" & @Min & ":" & @Sec & ": " & "Total amount of RAM: " & $getmem[1] & " Kilobytes")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "Date= " & @MON & "/" & @MDAY & "/" & @YEAR & " -- " & "Time= " & @Hour & ":" & @Min & ":" & @Sec & ": " & "Unused RAM: " & $getmem[2] & " Kilobytes")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "Date= " & @MON & "/" & @MDAY & "/" & @YEAR & " -- " & "Time= " & @Hour & ":" & @Min & ":" & @Sec & ": " & "Total amount of PageFile: " & $getmem[3] & " Kilobytes")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "Date= " & @MON & "/" & @MDAY & "/" & @YEAR & " -- " & "Time= " & @Hour & ":" & @Min & ":" & @Sec & ": " & "Unused PageFile: " & $getmem[4] & " Kilobytes")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "Date= " & @MON & "/" & @MDAY & "/" & @YEAR & " -- " & "Time= " & @Hour & ":" & @Min & ":" & @Sec & ": " & "Total amount of Virtual Memory: " & $getmem[5] & " Kilobytes")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "Date= " & @MON & "/" & @MDAY & "/" & @YEAR & " -- " & "Time= " & @Hour & ":" & @Min & ":" & @Sec & ": " & "Unused virtual memory: " & $getmem[6] & " Kilobytes")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "")
WEnd

enjoy :D:idiot:

EDIT: fixed the sleep to 15 minutes :lol:

EDIT: added some more line breaks in log so you can see when 15 minutes passed...

Edited by layer

FootbaG

Share this post


Link to post
Share on other sites

15000 = 15 seconds.

15 minutes = 60*15*1000.

Share this post


Link to post
Share on other sites

thanks Valik :idiot:


FootbaG

Share this post


Link to post
Share on other sites

thanks Valik :lol:

<{POST_SNAPBACK}>

:idiot: H layer great script thx to share it :D

Share this post


Link to post
Share on other sites

no problem


FootbaG

Share this post


Link to post
Share on other sites

FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "")
FileWriteLine ("MemUsageLog.txt", "")

What's that about? Do you want 5 blank lines?

FileWriteLine ("MemUsageLog.txt", @LF & @LF & @LF & @LF & @LF)

"I thoroughly disapprove of duels. If a man should challenge me, I would take him kindly and forgivingly by the hand and lead him to a quiet place and kill him." - Mark TwainPatient: "It hurts when I do $var_"Doctor: "Don't do $var_" - Lar.

Share this post


Link to post
Share on other sites

thats what you see right, because @LF doesnt work... :idiot: it returns little rectangles...


FootbaG

Share this post


Link to post
Share on other sites

So use @CRLF instead.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0