Author Topic: Memory leak  (Read 12192 times)

0 Members and 1 Guest are viewing this topic.

Offline gruntmanTopic starter

  • Full Member
  • ***
  • Posts: 168
  • Activity:
    0%
  • Reputation Power: 2
  • gruntman has no influence.
  • Gender: Male
  • Respect: +33
  • Referrals: 0
    • View Profile
Memory leak
« on: May 27, 2016, 08:06:52 AM »
+1
I am curious if anybody else has this issue. When i run a certain lumberjacking script it always causes a memory error about five hours into it. I recently watched the task manager as the script ran and every single time the script recalled the memory for uo.exe usage went up a bit. Is there a way to avoid this slow drainage of memory through the script itself? I paused the script and just let character sit still and well the usage never dropped at all. Does this happen to anyone else and has anyone ever been able to find a way to slow this down?
If this has been posted about before I do apologize...I couldnt seem to find anyone else really having the same issue.

Offline TrailMyx

  • Officially retired from UO
  • Administrator
  • *
  • *
  • Posts: 13301
  • Activity:
    0%
  • Reputation Power: 154
  • TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!
  • Gender: Male
  • Viper!
  • Respect: +1349
  • Referrals: 33
    • View Profile
    • ScriptUO
Re: Memory leak
« Reply #1 on: May 27, 2016, 09:22:26 AM »
+1
Which script are you using?
Please read the ScriptUO site RULES
Come play RIFT with me!

Offline gruntmanTopic starter

  • Full Member
  • ***
  • Posts: 168
  • Activity:
    0%
  • Reputation Power: 2
  • gruntman has no influence.
  • Gender: Male
  • Respect: +33
  • Referrals: 0
    • View Profile
Re: Memory leak
« Reply #2 on: May 27, 2016, 07:16:57 PM »
+1
mwinc lumberjack

Offline TrailMyx

  • Officially retired from UO
  • Administrator
  • *
  • *
  • Posts: 13301
  • Activity:
    0%
  • Reputation Power: 154
  • TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!
  • Gender: Male
  • Viper!
  • Respect: +1349
  • Referrals: 33
    • View Profile
    • ScriptUO
Re: Memory leak
« Reply #3 on: May 27, 2016, 07:35:33 PM »
+1
Right before you start, do a dump of the memory (Tools/VarDump).  Then let it run for a while and check how large the variable list gets.
Please read the ScriptUO site RULES
Come play RIFT with me!

Offline gruntmanTopic starter

  • Full Member
  • ***
  • Posts: 168
  • Activity:
    0%
  • Reputation Power: 2
  • gruntman has no influence.
  • Gender: Male
  • Respect: +33
  • Referrals: 0
    • View Profile
Re: Memory leak
« Reply #4 on: May 27, 2016, 07:56:42 PM »
+1
ok will do...Thanks TM

Offline gruntmanTopic starter

  • Full Member
  • ***
  • Posts: 168
  • Activity:
    0%
  • Reputation Power: 2
  • gruntman has no influence.
  • Gender: Male
  • Respect: +33
  • Referrals: 0
    • View Profile
Re: Memory leak
« Reply #5 on: May 27, 2016, 08:25:35 PM »
+1
Should I post it after? So that you can look at it and maybe tip me off as to what i need to look at? I have some basic abilities and would love to add more...... I want to be a Jedi!

Offline TrailMyx

  • Officially retired from UO
  • Administrator
  • *
  • *
  • Posts: 13301
  • Activity:
    0%
  • Reputation Power: 154
  • TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!
  • Gender: Male
  • Viper!
  • Respect: +1349
  • Referrals: 33
    • View Profile
    • ScriptUO
Re: Memory leak
« Reply #6 on: May 27, 2016, 08:28:06 PM »
+1
Should I post it after? So that you can look at it and maybe tip me off as to what i need to look at? I have some basic abilities and would love to add more...... I want to be a Jedi!

Na, just see if it grows a bunch.  If so, then the leak is due to the script itself.  If it doesn't grow, then the problem is deeper in EUO somewhere.
Please read the ScriptUO site RULES
Come play RIFT with me!

Offline gruntmanTopic starter

  • Full Member
  • ***
  • Posts: 168
  • Activity:
    0%
  • Reputation Power: 2
  • gruntman has no influence.
  • Gender: Male
  • Respect: +33
  • Referrals: 0
    • View Profile
Re: Memory leak
« Reply #7 on: May 27, 2016, 08:57:50 PM »
+1
I assume by grow you mean gets longer?(scroll and scroll and scroll) I never used this feature before...lol

Offline gruntmanTopic starter

  • Full Member
  • ***
  • Posts: 168
  • Activity:
    0%
  • Reputation Power: 2
  • gruntman has no influence.
  • Gender: Male
  • Respect: +33
  • Referrals: 0
    • View Profile
Re: Memory leak
« Reply #8 on: May 27, 2016, 09:56:20 PM »
+1
Well by removing the menu aspect of the script I seemed to have decreased the time it takes to run me out of memory....hardcore run is in order...I did leave the timer part of the menu active just for ease of seeing how long it runs before....DOOM OOM error

Offline Crome969

  • Elite
  • *
  • *
  • Posts: 2098
  • Activity:
    0%
  • Reputation Power: 25
  • Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.
  • Gender: Male
  • UO Enthusiast
  • Respect: +211
  • Referrals: 10
    • View Profile
    • ScriptSDK
Re: Memory leak
« Reply #9 on: May 28, 2016, 01:30:21 AM »
+1
EasyUO is written in Delphi and delphi has no support of a Garbagecollector. Depending how the datamanagement is solved it can be, that most script data is kept on memory until you restart easyuo.
That ofc means that you can go out of memory the more you script, because the non required data is not flushed.

Offline gruntmanTopic starter

  • Full Member
  • ***
  • Posts: 168
  • Activity:
    0%
  • Reputation Power: 2
  • gruntman has no influence.
  • Gender: Male
  • Respect: +33
  • Referrals: 0
    • View Profile
Re: Memory leak
« Reply #10 on: May 28, 2016, 10:21:59 AM »
+1
EasyUO is written in Delphi and delphi has no support of a Garbagecollector. Depending how the datamanagement is solved it can be, that most script data is kept on memory until you restart easyuo.
That ofc means that you can go out of memory the more you script, because the non required data is not flushed.

Thanks Crome!!  I think I kind of get it.

Offline Gemviper

  • Sr. Member
  • *
  • Posts: 481
  • Activity:
    0%
  • Reputation Power: 0
  • Gemviper hides in shadows.
  • Respect: +57
  • Referrals: 2
    • View Profile
Re: Memory leak
« Reply #11 on: January 20, 2017, 07:38:50 AM »
+1
Is there an easy way to do the same var check with Stealth? I've got a similar memory leak issue after a few hours too.

Offline Crome969

  • Elite
  • *
  • *
  • Posts: 2098
  • Activity:
    0%
  • Reputation Power: 25
  • Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.
  • Gender: Male
  • UO Enthusiast
  • Respect: +211
  • Referrals: 10
    • View Profile
    • ScriptSDK
Re: Memory leak
« Reply #12 on: January 20, 2017, 08:24:37 AM »
+1
Is there an easy way to do the same var check with Stealth? I've got a similar memory leak issue after a few hours too.
Sorry that i did not replied to you before, in Stealth there is no real way to check memoryleaks. But you can avoid leakages on Objects, if you clear the ignorepathlist and the ignoreItem stuff.

Whenever you store data to stealth internals, stealth not frequently delete it. So you can reduce the amount of data by removing those lists yourself. In ScriptSDK i kinda did that automaticly on scanner content. You can define the garbage collector and it will clear some stuff every 15 minutes by default.

Offline manwinc

  • Elite
  • *
  • *
  • Posts: 2556
  • Activity:
    0%
  • Reputation Power: 32
  • manwinc is a rising star!manwinc is a rising star!manwinc is a rising star!manwinc is a rising star!manwinc is a rising star!manwinc is a rising star!
  • Gender: Male
  • "The Devs Hard at Work"
  • Respect: +123
  • Referrals: 1
    • View Profile
Re: Memory leak
« Reply #13 on: January 23, 2017, 12:57:55 AM »
+1
If your memory leak is in the Client.exe then it shouldn't be an issue with the script itself. In the final generation of the script I had to code in for it to close the client and open a new one every 8 hours. I've seen it last as long as 216 hours straight without crashing. The core of the script is still the same though beyond that modification. Definitely something wonky with scripts that recall at that rate when crossing multiple server lines.
Monkeys and Typewriters!

" Oh I know, We'll make a Boss Encounter that requires 3 keys per player to enter, Then we'll make it not a closed instance so you never know if you are going to pop into a fresh room or a boss that has 1% Health left with 20 dudes smashing its face in, wasting your time and effort"

Tags: