Jump to content
UBot Underground

Extremely Elegant Solution To Rising Browser.exe Memory


Recommended Posts

Ok guys,

 

I wish I could say that I'm a rocket scientist in regards to the solution I've come up with but I'm not. I was wanting to clear the browser window if a user kills automation sequence, so I just did a simple 'load html()', with no contents to clear the visible browser window.

 

I kept running into the browser.exe climbing in memory as time tickers on if the user doesn't do a kill, so I thought, hmmm what happens if I just do the command before every new sequence.

 

Guess what! I completely clears the memory on the active browser.exe command each and every time. Literally down to 0 and it comes back to about 10mb of used memory!

 

Give it a try and report back!!

 

Frank

  • Like 4
Link to post
Share on other sites
  • 2 weeks later...

Ok guys, here is my test results.

 

1. Laptop with .Net framework 4.0.0 Windows 8

Load blank html seems to do the trick. Memory level is stable and stays low not to crash the browser.

 

2. Desktop with .Net framework 4.5.2 Windows 7 Ultimate

Load blank html command crashes the browser. (Actually asset://asset window loads correctly on the first run of the loop but you get the "oh no your browser crashed") message every time after that. Currently trying to roll back to 4.0.0 for desktop to work.

 

I think Frank is on to something because it seems the navigation command is causing the memory leak, and as long as you have few navigation commands in a loop, you are essentially screwed. I have tried "close page" command also crashes the browser on 4.5.2. 

 

So far the only reliable solution across all different .net framework versions is to change agent, however that will break your session which will require you to log in again.  

 

Clearing memory is only a temporary solution as browser windows will eventually crash anyways, just takes a longer time. Not a good way to solve this issue.

 

So in conclusion I regret upgrading to Ubot 5.7, I should go back to 4.0 where I never imagined I had to deal with all these problems with just a 25 loop simple bot. If this issue is not solved soon, I don't see Ubot lasting in this environment. 

Edited by RickBot0906
Link to post
Share on other sites

Ok guys, an update to the issue I was having.

 

Frank's solution does work very well indeed. All you need to do is to add navigate to www.google.com or something, then load blank html command. If the order was reversed it will crash on certain version of .Net but not others.

 

So make sure you add navigate to page first before using load html

 

: )

  • Like 2
Link to post
Share on other sites

Will try this right away

 

THANKS FRANK!

 

 

 

edited:

 

hOW THE HECK DID YOU COME UP WITH THIS ONE LOL!

So simple!

 

Now i'm trying to figure out when to trigger this on multithreaded bots.

Probably in the begining of each loop i guess ?

Link to post
Share on other sites
  • 4 weeks later...

I'm also trying this:

ui drop down("Headless","On,Off",#headless)
set headless browser(#headless)
allow javascript("Yes")
allow css("Yes")
allow images("Yes")
allow flash("Yes")

Seems to be doing great too!

Well at least it's not crashing all of the time...

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...